Next: , Previous: , Up: The Library System   [Contents][Index]

1.5 Catalog Vicinities

Each file in the table below is descibed in terms of its file-system independent vicinity (see Vicinity). The entries of a catalog in the table override those of catalogs above it in the table.

implementation-vicinity slibcat

This file contains the associations for the packages comprising SLIB, the implcat and the sitecats. The associations in the other catalogs override those of the standard catalog.

library-vicinity mklibcat.scm

creates slibcat.

library-vicinity sitecat

This file contains the associations specific to an SLIB installation.

implementation-vicinity implcat

This file contains the associations specific to an implementation of Scheme. Different implementations of Scheme should have different implementation-vicinity.

implementation-vicinity mkimpcat.scm

if present, creates implcat.

implementation-vicinity sitecat

This file contains the associations specific to a Scheme implementation installation.

home-vicinity homecat

This file contains the associations specific to an SLIB user.

user-vicinity usercat

This file contains associations affecting only those sessions whose working directory is user-vicinity.

Here is an example of a usercat catalog. A program in this directory can invoke the ‘run’ feature with (require 'run).

;;; "usercat": SLIB catalog additions for SIMSYNCH.     -*-scheme-*-
(
 (simsynch      . "../synch/simsynch.scm")
 (run           . "../synch/run.scm")
 (schlep        . "schlep.scm")
)

Copying usercat to many directories is inconvenient. Application programs which aren’t always run in specially prepared directories can nonetheless register their features during initialization.

Procedure: catalog:read vicinity catalog

Reads file named by string catalog in vicinity, resolving all paths relative to vicinity, and adds those feature associations to *catalog*.

catalog:read would typically be used by an application program having dynamically loadable modules. For instance, to register factoring and other modules in *catalog*, JACAL does:

(catalog:read (program-vicinity) "jacalcat")

For an application program there are three appropriate venues for registering its catalog associations:


Next: , Previous: , Up: The Library System   [Contents][Index]