GNOME Bugzilla – Bug 59841
possible error interpreting xsl
Last modified: 2009-08-15 18:40:50 UTC
I get a non conforming FO-file with current version of xsltproc from a docbook-file. Older versions do the job like fop does it too. The following document gives e more detailed report. <!DOCTYPE chapter PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" "http://139.18.38.48/~jeanm/docbook/4.1.2/docbookx.dtd"> <chapter> <title>Problem with current xsltproc</title> <section> <title>Introduction</title> <para>I encountered a problem with the current version of xsltproc together with docbook XML version 4.1.2 and docbook xslt package version 1.44 from sourceforge. (Tried todays cvs too.)</para> <para>If I use <section> recursive I ran into problems with the created FO-file when processing with fop. </para> <section> <title>worked realy fine</title> <para>If I use an earlier version of xsltproc, fop runs without error. <example> <title>This is the working example</title> <programlisting> [jeanm@alk tmp]$ xsltproc -V Using libxml 20400 and libxslt 10000 xsltproc was compiled against libxml 20400 and libxslt 10000 libxslt 10000 was compiled against libxml 20400 [jeanm@alk tmp]$ xsltproc http://139.18.38.48/~jeanm/docbook/db-xsl/fo/docbook.xsl test.xml >alk.fo Making portrait pages on A4 paper (210mmx297mm) [jeanm@alk tmp]$ java -jar /export/staff/jeanm/bin/java/fop/fop.jar alk.fo -pdf alk.pdf FOP 0.20.1 using SAX parser org.apache.xerces.parsers.SAXParser building formatting object tree setting up fonts [1] Parsing of document complete, stopping renderer Initial heap size: 581Kb Current heap size: 999Kb Total memory used: 417Kb Memory use is indicative; no GC was performed These figures should not be used comparatively Total time used: 970ms Pages rendererd: 1 Avg render time: 970ms/page </programlisting> </example> </para> </section> <section> <title>worked realy fine</title> <para>Running xsltproc compiled from libxml2-2.4.3-1 and libxslt-1.0.3-1 produces a bad FO-file. <example> <title>the worse example ;-|</title> <programlisting> [jeanm@grisly tmp]$ xsltproc -V Using libxml 20403, libxslt 10003 and libexslt 301 xsltproc was compiled against libxml 20403, libxslt 10003 and libexslt 301 libxslt 10003 was compiled against libxml 20403 libexslt 301 was compiled against libxml 20403 [jeanm@grisly tmp]$ xsltproc http://139.18.38.48/~jeanm/docbook/db-xsl/fo/docbook.xsl test.xml >grisly.fo Making portrait pages on A4 paper (210mmx297mm) [jeanm@grisly tmp]$ java -jar /home/jeanm/dada/jeanm/bin/java/fop/fop.jar grisly.fo -pdf grisly.pdf FOP 0.20.1 using SAX parser org.apache.xerces.parsers.SAXParser building formatting object tree setting up fonts ERROR: page-sequence must be child of root, not fo:flow </programlisting> </example> </para> </section> </section> </chapter>
Hum, Can you provide test.xml ? Also are the stylesheet pristine, i.e. should I be able to reproduce this with version 1.40 of the styleheets (that's what I have in the CVS base of libxslt for the regression tests) ? Unfortunately debugging this I really need to make 2 runs with the old and new binary and check the difference in the verbose output to then find where this broke in the XSLt processor and then fix the problem (yep, debugging the engine is hard ...). thanks Daniel
Created attachment 5047 [details] test.xml, use to test xml2fo with xsltproc using docbook xsl 1.40 or 1.44
Okay, it is fixed in CVS, I think as a side effect of fixing bug #60143 , I just checked and the CVS version produces the same output for this file as the 1.0.0/2.4.0 combo (except for the ID generated), fixed, thanks for the report ! Daniel
Should be closed by release 1.0.4, thanks, Daniel