Converting LinuxDoc to DocBook

LinuxDoc was a popular SGML DTD for technical documentation that was superseded by DocBook. This package contains a DocBook stylesheet that converts LinuxDoc to DocBook (3.0 or 4.2), and a shell script to drive it. It requires Jade or OpenJade.

1 Download ld2db.zip (Zip 62.2kb), which contains all the other files you need. 2 Run ld2db.sh from.sgml to.sgml on each file to be converted. 3 Check the file and sort out any remaining problems manually. See below for likely sources of problems.

It's important that each LinuxDoc file starts with <!DOCTYPE linuxdoc system>, or it won't be processed properly. This might happen when processing included files one by one.

The ld2db.sh script first calls sgmlnorm to add in all the missing optional tags (LinuxDoc allows them to be omitted, whereas DocBook doesn't), then calls jade to perform the conversion.

Some problems that the script doesn't help with are:

  • Entities are expanded. The NetBSD documentation project had to get around this; their Perl scripts might help (if they're available).
  • Comments are removed.

Last updated 2017/05/11