GNOME Bugzilla – Bug 618566
Support --loaddtd and --dtdattr on xsltproc
Last modified: 2012-09-04 12:33:57 UTC
Created attachment 160998 [details] [review] Support --loaddtd and --dtdattr on xsltproc Processing DITA correctly requires loading the DTD and applying the default attributes. It's not enough to just do it with xmllint and pipe the result through xsltproc, because DITA's conref feature requires loading extra files using the XPath document function. Attaching a patch. I lifted this straight from xmllint.c.
That sounds a bit weird because XPath data model explicitely requires loading the DTD and expanding default attributes... in xsltproc.c static int options = XSLT_PARSE_OPTIONS; and in libxslt/xslt.h /** * XSLT_PARSE_OPTIONS: * * The set of options to pass to an xmlReadxxx when loading files for * XSLT consumption. */ #define XSLT_PARSE_OPTIONS \ XML_PARSE_NOENT | XML_PARSE_DTDLOAD | XML_PARSE_DTDATTR | XML_PARSE_NOCDATA So basically enabling those options should be a no-op, so i'm not tempted to pick that patch which may induce confusion rather than help. Or did I misunderstood something ? Please reopen if I did :-) Daniel
err ... *not* pick that patch, sorry Daniel