A note on catalogs

The introduction is provided for the benefit of those who may want some explanation of what's going on. Experienced users of SGML may wish to skip it and proceed directly to the list of public identifiers at the end.

The function of a CATALOG file is to manage a number of external entities which are needed for processing a particular file without needing to have them all in the same directory as that file. Essentially the CATALOG file tells the computer where to find the various files it needs. First of all it is necessary to tell the computer where to find the CATALOG file. This is done by adding a line indicating its name and location to your autoexec.bat file, for example

SET SGML_CATALOG_FILES=C:\sgml\CATALOG
(This assumes that you are running MS-DOS; it may be slightly different under other operating systems.) You will probably need to reboot the computer for this to take effect.

The CATALOG file itself is a text file containing a series of entries, each of which consists of a keyword (for our purposes usually PUBLIC), a public identifier and a system identifier, the latter two delimited by quotes, for example

PUBLIC "ISO 8879-1986//ENTITIES Publishing//EN" "ISOpub.ent"
This means that the file to which the public identifier refers is the file called "ISOpub.ent" which is in the same directory as the CATALOG file. It is probably preferable to specify the entire path for the system identifier, which allows you to put the files concerned in whatever directory you want, for example
PUBLIC "ISO 8879-1986//ENTITIES Publishing//EN" "C:\sgml\tei\ISOpub.ent"

It is essential that the public identifier should appear in the document type declaration EXACTLY as it appears in the CATALOG file. The most trivial difference will prevent the parser from generating a system identifier. This can usually be cured by copying and pasting from one file to the other.

The easiest way to create a CATALOG file is to edit an existing one so that the system identifiers point to the files in the location where they are on your system. The fragment below should include the public identifiers necessary to process the edition, and may be used as your CATALOG or added in whole or part to your existing file.

--If you have processed TEI documents before, you will almost certainly already have these in your CATALOG file--

PUBLIC "ISO 8879-1986//ENTITIES Added Latin 1//EN" "c:\sgml\ISO\ISOLat1.ent"
PUBLIC "ISO 8879-1986//ENTITIES Added Latin 2//EN" "c:\sgml\ISO\ISOLat2.ent"
PUBLIC "ISO 8879-1986//ENTITIES Russian Cyrillic//EN" "c:\sgml\ISO\ISOcyr1.ent"
PUBLIC "ISO 8879-1986//ENTITIES Non-Russian Cyrillic //EN" "c:\sgml\ISO\ISOcyr2.ent"
PUBLIC "ISO 8879-1986//ENTITIES Numeric and Special Graphic//EN" "c:\sgml\ISO\ISOnum.ent"
PUBLIC "ISO 8879:1986//ENTITIES Publishing//EN" "c:\sgml\ISO\ISOpub.ent"
PUBLIC "-//TEI//DTD TEI Level 2//EN//2.0"   "c:\sgml\tei\tei2.dtd"
PUBLIC '-//TEI P2: 1993//NOTATION WSD for ISO 8859-2//EN' 'C:\SGML\ISO\ISO88592.wsd'
PUBLIC "-//TEI P2: 1993//NOTATION WSD for ISO 8859-1:1986//EN" 'C:\SGML\ISO\iso88591.wsd'
PUBLIC "-//TEI P2 1994//NOTATION WSD for TLG Classical Greek//EN" "c:\CUCUK\teigk2.wsd"

--These, however, are new--

PUBLIC "-//DR//ENTITIES Greek//EN" "C:\sgml\gk.ent"
PUBLIC "-//R.M.Cleminson 1999//NOTATION WSD for glagolitic//EN" "C:\cucuk\glag.wsd"
PUBLIC "-//R.M.Cleminson 1997//NOTATION WSD for modern cyrillic//EN" "N:\cucuk\mcyr.wsd"
PUBLIC "-//RMC//ENTITIES Glagolitic//EN"    "c:\sgml\glag.ent"
PUBLIC "-//DJB//ENTITIES General Church Slavonic//EN" "N:\cucuk\chsl.ent"
PUBLIC "-//DJB//NOTATION General Church Slavonic WSD//EN" "C:\chsl.wsd"

back