Hi Brad, I'm leaving all of the text of your email here as it looks like you forgot to post to the list; my comments follow. On 22/08/2007, at 12:47, Brad Miller wrote:
Thanks for your help:
Here's what I get when I run xmlto -vvv
xmlto -vvv pdf article.xml ~/tmp Format script: /opt/local/share/xmlto/format/docbook/pdf Convert to XSL-FO xmllint >/dev/null --xinclude --postvalid /Users/bmiller/tmp/ article.xml Stylesheet: http://docbook.sourceforge.net/release/xsl/current/fo/ docbook.xsl xsltproc --nonet --xinclude -v \ -o /tmp/xmlto.cHziSS/article.proc \ http://docbook.sourceforge.net/release/xsl/current/fo/docbook.xsl \ /Users/bmiller/tmp/article.xml I/O error : Attempt to load network entity http:// docbook.sourceforge.net/release/xsl/current/fo/docbook.xsl warning: failed to load external entity "http:// docbook.sourceforge.net/release/xsl/current/fo/docbook.xsl" cannot parse http://docbook.sourceforge.net/release/xsl/current/fo/ docbook.xsl No XML Catalogs? Trying again with --catalogs.. Variable $SGML_CATALOG_FILES not set I/O error : Attempt to load network entity http:// docbook.sourceforge.net/release/xsl/current/fo/docbook.xsl warning: failed to load external entity " http:// docbook.sourceforge.net/release/xsl/current/fo/docbook.xsl" cannot parse http://docbook.sourceforge.net/release/xsl/current/fo/ docbook.xsl
As far as I know I got whatever docbook stuff I need from macports. Here is the contents of the catalog:
<?xml version="1.0"?> <!DOCTYPE catalog PUBLIC "-//OASIS//DTD Entity Resolution XML Catalog V1.0//EN" "http://www.oasis-open.org/committees/entity/release/1.0/ catalog.dtd ">
<!-- Created by XML Catalog Manager 2.2 --> <catalog xmlns="urn:oasis:names:tc:entity:xmlns:xml:catalog"> <nextCatalog catalog="/opt/local/share/xml/docbook/4.2/catalog.xml" /> <nextCatalog catalog="/opt/local/share/xsl/docbook-xsl/catalog.xml" /> <nextCatalog catalog="/opt/local/share/xml/docbook/4.1.2/ catalog.xml" /> <nextCatalog catalog="/opt/local/share/xml/docbook/4.3/catalog.xml" /> <nextCatalog catalog="/opt/local/share/xml/docbook/4.4/catalog.xml" /> <nextCatalog catalog="/opt/local/share/xml/docbook/4.5/catalog.xml" /> </catalog>
I do remember seeing some funny messages about uninstallation and catalog management when tried to upgrade to the latest xmlto stuff, but since I was not uninstalling I didn't do anything.
Here is all the docbook stuff that I have installed through port:
port installed |grep docbook
docbook-xml @4.3_0 docbook-xml @4.5_0 (active) docbook-xml-4.1.2 @4.1.2_1 (active) docbook-xml-4.2 @4.2_0 (active) docbook-xml-4.3 @4.3_0 (active) docbook-xml-4.4 @4.4_0 (active) docbook-xml-4.5 @4.5_0 (active) docbook-xsl @1.69.1_0 docbook-xsl @1.72.0_0 (active)
Finally, here is what I get when I tried your a2x suggestion: a2x --format=pdf article.txt ~/tmp readlink: illegal option -- f usage: readlink [-n] [file ...] a2x: failed: enhanced getopt(1) required
Brad
It now looks to me like your libxml2 and asciidoc installations are out of date. I added sysutils/getopt as a runtime dependency of asciidoc when I bumped it to 8.2.1 on 2007/05/28, while libxml2 was patched on 2007/06/11 so that it would locate our default location for XML catalogs. If you upgrade libxml2, asciidoc and libxslt (I'm pretty sure that the latter needs a rebuild to pick up the rebuild to libxml2), ensuring that any missing dependencies are also installed, I'm fairly confident that both problems should be solved. Good luck! Kind regards, Maun Suang -- Boey Maun Suang (Boey is my surname) Email: boeyms at macports dot org
On 8/21/07, Boey Maun Suang <boeyms@macports.org> wrote:
Hi Brad,
...
It now looks to me like your libxml2 and asciidoc installations are out of date. I added sysutils/getopt as a runtime dependency of asciidoc when I bumped it to 8.2.1 on 2007/05/28, while libxml2 was patched on 2007/06/11 so that it would locate our default location for XML catalogs. If you upgrade libxml2, asciidoc and libxslt (I'm pretty sure that the latter needs a rebuild to pick up the rebuild to libxml2), ensuring that any missing dependencies are also installed, I'm fairly confident that both problems should be solved. Good luck!
port upgrade seems to think I already have the latest version of all of those libraries: getopt @1.1.4_0 (active) asciidoc @7.1.2_0 asciidoc @8.2.1_1 (active) libxml2 @2.6.23_0 libxml2 @2.6.28_1 (active) libxslt @1.1.20_0 (active) BUT, I just discovered that it is using /usr/bin/getopt and not /opt/local/bin/getopt so I have a problem with PATH. Fixing that solves it. Sorry to have wasted your time. Brad -- Brad Miller Assistant Professor, Computer Science Luther College
On 8/22/07, Brad Miller <bonelake@gmail.com> wrote:
On 8/21/07, Boey Maun Suang <boeyms@macports.org> wrote:
Hi Brad,
...
It now looks to me like your libxml2 and asciidoc installations are out of date. I added sysutils/getopt as a runtime dependency of asciidoc when I bumped it to 8.2.1 on 2007/05/28, while libxml2 was patched on 2007/06/11 so that it would locate our default location for XML catalogs. If you upgrade libxml2, asciidoc and libxslt (I'm pretty sure that the latter needs a rebuild to pick up the rebuild to libxml2), ensuring that any missing dependencies are also installed, I'm fairly confident that both problems should be solved. Good luck!
port upgrade seems to think I already have the latest version of all of those libraries:
getopt @1.1.4_0 (active) asciidoc @7.1.2_0 asciidoc @8.2.1_1 (active) libxml2 @2.6.23_0 libxml2 @2.6.28_1 (active) libxslt @1.1.20_0 (active)
BUT, I just discovered that it is using /usr/bin/getopt and not /opt/local/bin/getopt so I have a problem with PATH. Fixing that solves it.
I should have said partially solves it. Your a2x solution builds a pdf file nicely. But using xmlto I get latex errors, which I assume may be because I'm using texlive rather than the macports tetex distro? This seems pretty old to me: xmltex version: 2002/06/25 v1.9 (Exp): (/usr/local/texlive/2007/texmf-dist/tex/xmltex/base/xmltex.cfg) ... ! Argument of \XML@getattrib has an extra }. <inserted text> \par l.2 ...efore region-name="xsl-region-before-blank" extent="0.4in" display-al... ? ! Emergency stop. <inserted text> \par l.2 ...efore region-name="xsl-region-before-blank" extent="0.4in" display-al... ! ==> Fatal error occurred, no output PDF file produced!
-- Brad Miller Assistant Professor, Computer Science Luther College
Hi Brad,
BUT, I just discovered that it is using /usr/bin/getopt and not / opt/local/bin/getopt so I have a problem with PATH. Fixing that solves it.
Glad to hear that that's fixed :-)
I should have said partially solves it. Your a2x solution builds a pdf file nicely. But using xmlto I get latex errors, which I assume may be because I'm using texlive rather than the macports tetex distro?
This seems pretty old to me: xmltex version: 2002/06/25 v1.9 (Exp): (/usr/local/texlive/2007/texmf-dist/tex/xmltex/base/xmltex.cfg)
...
! Argument of \XML@getattrib has an extra }. <inserted text> \par l.2 ...efore region-name="xsl-region-before-blank" extent="0.4in" display-al...
? ! Emergency stop. <inserted text> \par l.2 ...efore region-name="xsl-region-before-blank" extent="0.4in" display-al...
! ==> Fatal error occurred, no output PDF file produced!
I'm afraid that I think that this is a problem with xmltex and/or PassiveTeX, which xmlto uses to generate PDFs from XSL-FO. I get the same error, and CTAN shows the version of xmltex displayed above to be the most recent release. Furthermore, _DocBook XSL: The Definitive Guide_ (2005) says that "[PassiveTeX] has fallen behind in its implementation of the XSL-FO specification, and many features of DocBook XSL don't work in PassiveTeX" [1]; the package that I just downloaded from http://www.tei-c.org.uk/Software/passivetex/ was last updated in 2003. Sebastian Rahtz was also the maintainer of teTeX, which he stopped maintaining last year, so I don't think that he will be working on either again in the near future. So, unless you fancy hacking on xmlto to get it to support other FO processors, or on xmltex/PassiveTeX to update its handling of XSL-FO, I don't think you'll have much luck using xmlto on documents that generate more complex XSL-FO. Kind regards, Maun Suang [1] http://www.sagehill.net/docbookxsl/FOprocessors.html -- Boey Maun Suang (Boey is my surname) Email: boeyms at macports dot org
participants (3)
-
Boey Maun Suang
-
Brad Miller
-
Brad Miller