1.4. R003--Open Catalog usage for SGML

Open Catalog files include:

The centralized catalog file names must end in .cat and reside in /etc/sgml. They contain only comments and CATALOG directives pointing to the "real" catalogs, like:


     -- sample contents of /etc/sgml/foo-1.05.cat --
     CATALOG /usr/share/sgml/foo/xml-dtd-1.05/catalog
     CATALOG /usr/share/sgml/foo/xsl-stylesheets-0.1/catalog
One can use DELEGATE instead of CATALOG if this directive is known to be supported.

The centralized catalogs are DTD-specific and can be version-numbered.

Here are examples of such centralized catalogs:

/etc/sgml/

sgml-docbook.cat
sgml-docbook-3.1.cat
sgml-docbook-4.0.cat
xml-docbook-4.0.cat

Version-less centralized catalogs could be only symbolic links to the latest version (or to any other older version).

/etc/sgml/catalog is the "super catalog". It contains CATALOG pointers to all the centralized catalogs:


     -- sample contents of /etc/sgml/catalog --
     CATALOG /etc/sgml/sgml-docbook.cat
     CATALOG /etc/sgml/xhtml.cat
     CATALOG /etc/sgml/mathml.cat
One can use DELEGATE instead of CATALOG if this directive is known to be supported.

It should not point to centralized catalogs that are merely symbolic links and therefore are already mentioned.

Users should be able to define their own centralized catalogs and their own super catalog in their home directories:

$HOME/.sgml-docbook.cat
$HOME/.catalog

The SGML/XML computer programs are not supposed to use centralized catalogs, although their use is strongly encouraged: if other mechanisms allow one to locate the real catalogs, they can be used as well. However distribution packagers should always take care of feeding the right entries into the super catalog and the centralized catalogs. The interface for a script named install-catalog that does these maintenance tasks is described here:

install-catalog [--add | --remove] [centralized_catalog] [ordinary_catalog]

Example:


bash# install-catalog --add \
  /etc/sgml/sgml-docbook-3.1 \
  /usr/share/sgml/docbook/dsssl-stylesheets-1.54/catalog

The other catalogs should be placed in subdirectories of /usr/share/sgml. They should all be named catalog. They are the ones who do the real work of mapping the FPIs to file names (among other tasks).