This is the mail archive of the docbook-apps@lists.oasis-open.org mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: What are the steps to convert to DocBook XML?


Richard Sharpe writes:

> Assuming I was interested in converting to DocBook XML, what are the steps?
>
> 1. How do I get my current SGML source converted?

In addition to the answer "sx" you need to convert the element names to
lower case and insert a declaration to pick up some general entities.
This works for me:

DECL := <!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.1//EN"
"http://www.oasis-open.org/docbook/xml/4.1/docbookx.dtd";>

%.xml: %.sgml
        osx -x lower $< > $@.tmp
        (sed 1q $@.tmp; echo '$(DECL)'; sed 1d $@.tmp) > $@
        rm $@.tmp

You may get tons of warnings about sdata not allowed in XML -- ignore
them.

> 2. If and when I have DocBook SML source, how to I convert it to PDF?

A couple of options:

* Use DSSSL -> pdfjadetex (no need for XML here).  Works okay if you don't
  have too complicated tables.

* Use DSSSL -> rtf -> word processor.  YMMV, but at least you'll always
  get there.

* Use FOP (xml.apache.org).  Dubious maturity.

* Use PassiveTeX.  Dubious usability.

-- 
Peter Eisentraut      peter_e@gmx.net       http://yi.org/peter-e/


------------------------------------------------------------------
To unsubscribe from this elist send a message with the single word
"unsubscribe" in the body to: docbook-apps-request@lists.oasis-open.org


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]