xmlto is a front-end to an XSL toolchain. It chooses an appropriate stylesheet for the conversion you want and applies it using an external XSL-T processor. It also performs any necessary post-processing. Supported conversions from DocBook XML: dvi, fo, html, html-nochunks, htmlhelp, javahelp, man, pdf, ps, txt, xhtml, xhtml-nochunks. Currently the only XSL-T processor supported is xsltproc (textproc/libxslt). For DVI, PDF and PostScript output, PassiveTeX (print/passivetex) is required. Author: Tim Waugh <tim@cyberelk.net> WWW: http://cyberelk.net/tim/xmlto/ This port requires misc/getopt (submitted separately) and is required for update of devel/makeplus port. Tested on 4.8-STABLE and 5.1-CURRENT (i386).
The patch below fixes (finally) xmlto port: - avoid fetching DocBook XSL stylesheets via HTTP by redirecting to the installed docbook-xsl port; add dependency --- Makefile.orig Tue Jun 17 12:50:46 2003 +++ Makefile Fri Jun 20 16:49:55 2003 @@ -19,7 +19,8 @@ BUILD_DEPENDS= ${BASH_CMD}:${PORTSDIR}/shells/bash2 \ ${GETOPT_CMD}:${PORTSDIR}/misc/getopt \ xmllint:${PORTSDIR}/textproc/libxml2 \ - xsltproc:${PORTSDIR}/textproc/libxslt + xsltproc:${PORTSDIR}/textproc/libxslt \ + ${XSL_DIR}:${PORTSDIR}/textproc/docbook-xsl RUN_DEPENDS= ${BUILD_DEPENDS} .if defined(WITH_PASSIVETEX) || exists(${PASSIVETEX}) @@ -39,12 +40,16 @@ GETOPT_CMD= ${LOCALBASE}/bin/getopt PASSIVETEX= ${LOCALBASE}/share/texmf/tex/passivetex +XSL_URL= http://docbook.sourceforge.net/release/xsl/current +XSL_DIR= ${LOCALBASE}/share/xsl/docbook + MAN1= xmlif.1 xmlto.1 DOCS= AUTHORS NEWS do-patch: - ${REINPLACE_CMD} -e 's,/bin/bash,${BASH_CMD},' -e '/--nonet/d' \ - ${WRKSRC}/xmlto.in + ${REINPLACE_CMD} -e 's,/bin/bash,${BASH_CMD},' ${WRKSRC}/xmlto.in + ${REINPLACE_CMD} -e 's,${XSL_URL},${XSL_DIR},' \ + ${WRKSRC}/format/docbook/* .if !defined(WITH_PASSIVETEX) ${REINPLACE_CMD} -e '/format\/fo\//d' ${WRKSRC}/Makefile.in .endif
On 2003-06-20 at 17:30 +0400, Sergey A. Osokin wrote: > Attempt to load network entity http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd > /usr/home/ports/src/xmlto/work/xmlto-0.0.14/./doc/xmlif.xml:4: warning: failed to load external entity "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd" Oops, that escaped my testing since I had XML_CATALOG_FILES defined. Use this patch (in addition to the previous one): --- Makefile.orig2 Fri Jun 20 17:48:11 2003 +++ Makefile Fri Jun 20 17:50:11 2003 @@ -40,6 +40,8 @@ GETOPT_CMD= ${LOCALBASE}/bin/getopt PASSIVETEX= ${LOCALBASE}/share/texmf/tex/passivetex +DOCBOOK_URL= http://www.oasis-open.org/docbook/xml +DOCBOOK_DIR= ${LOCALBASE}/share/xml/docbook XSL_URL= http://docbook.sourceforge.net/release/xsl/current XSL_DIR= ${LOCALBASE}/share/xsl/docbook @@ -48,6 +50,8 @@ do-patch: ${REINPLACE_CMD} -e 's,/bin/bash,${BASH_CMD},' ${WRKSRC}/xmlto.in + ${REINPLACE_CMD} -e 's,${DOCBOOK_URL},${DOCBOOK_DIR},' \ + ${WRKSRC}/doc/xml*.xml ${REINPLACE_CMD} -e 's,${XSL_URL},${XSL_DIR},' \ ${WRKSRC}/format/docbook/* .if !defined(WITH_PASSIVETEX) > file:///usr/local/share/xml/catalog:1: error: Start tag expected, '<' not found > CATALOG "dtd/catalog" > ^ For some reason, it expects an XML catalog at that location, but it isn't. Nonetheless, it should not affect the build. Sergei
State Changed From-To: open->closed Committed, thanks!