[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Docbook, MathML and Debian



>>>>> "Joost" == Joost Kooij <joost@topaz.mdcc.cx> writes:

    Joost> You are using openjade, perhaps?  Try jade, it does work.
    Joost> I got it to work once with the plex86 docs, which are xml
    Joost> docbook.

I am using stuff like:

ii  jade           1.2.1-18       James Clark's DSSSL Engine
ii  sgml-data      1.5.2          common SGML DTDs and entities
ii  docbook-styles 1.64-1         Modular DocBook stylesheets, for print and H
ii  xalan          1.0-3          XSLT processor.
ii  docbook-xsl-st 1.40-1         Stylesheets for processing DocBook XML files


My file has the following DOCTYPE (from some example, maybe this was wrong?)

<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"
               "docbook/dtd/xml/4.1.2/docbookx.dtd">


jade says:

[857] [scrooge:bam] ~/source/job/guard/doc >jade -t xml -d /usr/lib/sgml/stylesheet/dsssl/docbook/nwalsh/html/docbook.dsl guard.xml
jade:/usr/share/sgml/docbook/dtd/xml/4.1/docbookx.dtd:74:17:E: "X20AC" is not a function name
jade:/usr/share/sgml/entities/xml-iso-entities-8879.1986/ISOamsa.ent:6:19:E: "X21B6" is not a function name
jade:/usr/share/sgml/entities/xml-iso-entities-8879.1986/ISOamsa.ent:7:19:E: "X21B7" is not a function name

[...]

jade:/usr/share/sgml/entities/xml-iso-entities-8879.1986/ISOamsr.ent:20:18:E: "X22A3" is not a function name
jade:/usr/share/sgml/entities/xml-iso-entities-8879.1986/ISOamsr.ent:21:17:E: "X2256" is not a function name
jade:I: maximum number of errors (200) reached; change with -E option


so I comment out the DOCTYPE declaration, and now get these errors
instead:

[859] [scrooge:bam] ~/source/job/guard/doc >jade -t xml -d /usr/lib/sgml/stylesheet/dsssl/docbook/nwalsh/html/docbook.dsl guard.xml
jade:guard.xml:4:0:E: no document type declaration; will parse without validation
jade:guard.xml:279:8:E: general entity "gt" not defined and no default entity
jade:guard.xml:1726:38:E: general entity "lt" not defined and no default entity


isn't &gt; how you specify '>'? and isn't &lt; how you specify '<' in
XML? I can never seem to find these documented when I need them. Is
'&' specified &amp;???

Jade also gets confused and prints <arg choice="req">stuff</arg>
exactly the same way as <arg choice="opt">stuff</arg>.

However, this produces the best results so far.



I tried with xalan, too, but it couldn't even find the DTD.  (note: I
have deliberately refrained from specifying the XSL file).

[867] [scrooge:bam] ~/source/job/guard/doc >xalan -in guard.xml
========= Parsing guard.xml ==========

Fatal Error at (file guard.xml, line 5, char53): An exception occured! Type:RuntimeException, Message:Could not open DTD file 'docbook/dtd/xml/4.1.2/docbookx.dtd'
XSL Error: Could not parse guard.xml document!
XSL Warning: Unknown Exception

XSLException Type is : XSLTProcessorException
Message is : Could not parse guard.xml document!


So I specified the full pathname to the DTD in the XML file, but then
it couldn't find files that are indirectly loaded via that DTD.

[867] [scrooge:bam] ~/source/job/guard/doc >xalan -in guard.xml
========= Parsing guard.xml ==========

Fatal Error at (file /usr/share/sgml/docbook/dtd/xml/4.1.2/dbcentx.mod, line 56, char10): An exception occured! Type:RuntimeException, Message:Could not open external entity '/usr/share/sgml/docbook/dtd/xml/4.1.2/entities/xml-iso-entities-8879.1986/ISOamsa.ent'
XSL Error: Could not parse guard.xml document!
XSL Warning: Unknown Exception

XSLException Type is : XSLTProcessorException
Message is : Could not parse guard.xml document!



So I remove the DOCTYPE and replace & with &amp; (surprisingly jade
didn't complain about this real error), and now I get:

[876] [scrooge:bam] ~/source/job/guard/doc >xalan -in guard.xml -xsl /usr/share/sgml/docbook/stylesheet/xsl/nwalsh/html/docbook.xsl 
========= Parsing /usr/share/sgml/docbook/stylesheet/xsl/nwalsh/html/docbook.xsl ==========
xalan: XSLT/NamespacesHandler.cpp:125: NamespacesHandler::NamespacesHandler(const NamespacesHandler &, const vector<vector<NameSpace,allocator<NameSpace> >,allocator<vector<NameSpace,allocator<NameSpace> > > > &, const XalanDOMString &): Assertion `length(theURI) > 0' failed.
zsh: abort      xalan -in guard.xml -xsl 

nasty... I haven't yet filed a bug report on this, it is possible my
versions of everything are approx 1 week old.


I have filed bug reports on *some* of these issues, but haven't got
any response yet.
-- 
Brian May <bam@debian.org>



Reply to: