XML technologies / DocBook / XML catalogs / Distinguishing system and user catalogs

(Excerpt from "DocBook-XML: Media-neutral and platform-independent publishing" by Thomas Schraitle)

The system catalog is the central entry point for XML tools. Schemas, stylesheets and other resources register identifiers and URIs there so that URIs can be resolved through it.

On Linux, the Linux Standard Base places the system catalog at /etc/xml/catalog. For easier administration, entries are stored in separate files included through nextCatalog or delegate*. This organization depends on the distribution.

Windows defines no system catalog location. Users may place it anywhere and set the environment variable XML_CATALOG_FILES to the catalog. It is recommended to add this variable in System Properties (menu Start > Control Panel > System).

The environment variable XML_CATALOG_FILES specifies one or more user catalogs, with paths separated by spaces:

Linux:

export XML_CATALOG_FILES="~/.xml/catalog /etc/xml/catalog catalog.xml" 

Windows:

set XML_CATALOG_FILES="C:/Programme/DocBook/catalog.xml catalog.xml"

Catalogs are processed in the specified order. The last entry names a catalog in the current directory.

Note: Separators in XML_CATALOG_FILES
You may be accustomed to separating values with colons. The environment variable XML_CATALOG_FILES expects one or more space-separated URLs. URLs can contain colons, so spaces avoid ambiguity. Encode spaces within URLs as %20.

  

back to top