XML Catalogs on Linux

  • Thread starter Steve Whitlatch
  • Start date
S

Steve Whitlatch

It may be me, or it may be the Linux implementation of XML Catalogs on
slackware. Whichever, please shed some light on this XML Catalog problem.

When using the --catalogs option, xmllint resolves all system entities
to local copies. No problem, for example:

**********
%:~/docbook-testdocs-1.1/tests> xmllint --noout --nonet --valid --catalogs book.001.xml
**********

Produces no output, indicating that the referenced dtd was found and the
document is valid (using the SGML_CATALOG_FILES environment variable).
Additionally, if I am reading the output of xmlcatalog correctly, it
indicates that the /etc/xml/catalog file maps the docbook 4.1.2
dtd to a local copy:

**********
%:/etc/xml> xmlcatalog --shell -v /etc/xml/catalog
Resolve sysID http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd
16384 Parsing catalog /etc/xml/catalog
/etc/xml/catalog added to file hash
Using rewriting rule http://www.oasis-open.org/docbook/xml/4.1.2/
/usr/share/xml/docbook/xml-dtd-4.1.2/docbookx.dtd
Catalogs cleanup
Free catalog entry http://www.oasis-open.org/docbook/xml/4.2/
Free catalog entry http://www.oasis-open.org/docbook/xml/4.1.2/
Free catalog entry http://docbook.sourceforge.net/release/xsl/current/
Free catalog entry /etc/xml/catalog
Free catalog entry
********** (what does all this "Free catalog . . ." mean?)

But xmllint, when using just XML Catalogs (no --catalogs option),
complains it cannot find the local docbook 4.1.2 dtd.

**********
%:~/docbook-testdocs-1.1/tests> xmllint --noout --nonet --valid book.001.xml
Attempt to load network entity http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd
book.001.xml:7: validity error: No declaration for attribute id of element book
<book id="book"> . . . [snip]
..
..
..

[more validity errors related to the same document]
**********

xmllint can find the local copies for the docbook 4.2 dtd, but not the
local docbook 4.1.2 dtd. However, I see no difference in their entries
in the catalog file. For reference if necessary, exact /etc/xml/catalog
file contents:

**********
<?xml version="1.0"?>
<!DOCTYPE catalog PUBLIC "-//OASIS//DTD Entity Resolution XML Catalog V1.0//EN" "/etc/xml/xml-catalog-dtds/1.0/catalog.dtd">
<catalog xmlns="urn:eek:asis:names:tc:entity:xmlns:xml:catalog">

<rewriteSystem systemIdStartString="http://www.oasis-open.org/docbook/xml/4.2/" rewritePrefix="/usr/share/xml/docbook/xml-dtd-4.2/"/>

<rewriteSystem systemIdStartString="http://www.oasis-open.org/docbook/xml/4.1.2/"
rewritePrefix="/usr/share/xml/docbook/xml-dtd-4.1.2/"/>

<rewriteSystem systemIdStartString="http://docbook.sourceforge.net/release/xsl/current/"
rewritePrefix="/usr/share/xml/docbook/xsl-stylesheets-1.64-1"/>
</catalog>
**********


XML Catalogs is taking way too much time to set up. Help please.


Thanks,

Steve Whitlatch
(e-mail address removed)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,537
Members
45,020
Latest member
GenesisGai

Latest Threads

Top