Next: The SLIB script, Previous: About SLIB, Up: About SLIB [Contents][Index]
There are five parts to installation:
slib
script.
If the SLIB distribution is a GNU/Linux RPM, it will create the SLIB directory /usr/share/slib.
If the SLIB distribution is a ZIP file, unzip the distribution to create the SLIB directory. Locate this slib directory either in your home directory (if only you will use this SLIB installation); or put it in a location where libraries reside on your system. On unix systems this might be /usr/share/slib, /usr/local/lib/slib, or /usr/lib/slib. If you know where SLIB should go on other platforms, please inform agj@alum.mit.edu.
make infoz make install
If the Scheme implementation supports getenv
, then the value of
the shell environment variable SCHEME_LIBRARY_PATH will be used
for (library-vicinity)
if it is defined. Currently, Bigloo,
Chez, Elk, Gambit, Gauche, Guile, Jscheme, Larceny, MITScheme,
MzScheme, RScheme, S7, STk, VSCM, and SCM support getenv
.
Scheme48 supports getenv
but does not use it for determining
library-vicinity
. (That is done from the Makefile.)
The (library-vicinity)
can also be set from the SLIB
initialization file or by implementation-specific means.
Support for locating an implementation’s auxiliary directory is uneven
among implementations. Also, the person installing SLIB may not have
write permission to some of these directories (necessary for writing
slibcat). Therefore, those implementations supporting getenv
(except SCM and Scheme48) provide a means for specifying the
implementation-vicinity
through environment variables. Define
the indicated environment variable to the pathname (with trailing
slash or backslash) of the desired directory. Do not use slib/
as an implementation-vicinity!
Bigloo | BIGLOO_IMPLEMENTATION_PATH |
Chez | CHEZ_IMPLEMENTATION_PATH |
ELK | ELK_IMPLEMENTATION_PATH |
Gambit | GAMBIT_IMPLEMENTATION_PATH |
Guile | GUILE_IMPLEMENTATION_PATH |
Jscheme | JSCHEME_IMPLEMENTATION_PATH |
MIT-Scheme | MITSCHEME_IMPLEMENTATION_PATH |
MzScheme | MZSCHEME_IMPLEMENTATION_PATH |
RScheme | RSCHEME_IMPLEMENTATION_PATH |
S7 | S7_IMPLEMENTATION_PATH |
STk | STK_IMPLEMENTATION_PATH |
Vscm | VSCM_IMPLEMENTATION_PATH |
If you use the slib
script to start your SLIB session, then
this step is unnecessary.
Check the manifest in README to find a configuration file for your Scheme implementation. Initialization files for most IEEE P1178 compliant Scheme Implementations are included with this distribution.
You should check the definitions of software-type
,
scheme-implementation-version
,
implementation-vicinity
,
and library-vicinity
in the initialization file. There are
comments in the file for how to configure it.
Once this is done, modify the startup file for your Scheme
implementation to load
this initialization file.
When SLIB is first used from an implementation, a file named
slibcat is written to the implementation-vicinity
for that
implementation. Because users may lack permission to write in
implementation-vicinity
, it is good practice to build the new
catalog when installing SLIB.
To build (or rebuild) the catalog, start the Scheme implementation (with SLIB), then:
(require 'new-catalog)
The catalog also supports color-name dictionaries. With an SLIB-installed scheme implementation, type:
(require 'color-names) (make-slib-color-name-db) (require 'new-catalog) (slib:exit)
Multiple implementations of Scheme can all use the same SLIB directory. Simply configure each implementation’s initialization file as outlined above.
The SCM implementation does not require any initialization file as SLIB support is already built into SCM. See the documentation with SCM for installation instructions.
Starting with version 0.96, Larceny contains its own SLIB
initialization file, loaded by (require 'srfi-96)
. If
SCHEME_LIBRARY_PATH is not set, then Larceny looks for an slib
subdirectory of a directory in the list returned by
(current-require-path)
larceny -- -e "(require 'srfi-96)"
Gauche also supports SLIB. It finds SLIB at installation time;
(use slib)
to enable.
gosh -u slib
elk -i -l ${SCHEME_LIBRARY_PATH}elk.init
The init.ss file in the _slibinit_ collection is an SLIB initialization file. To run SLIB in MzScheme:
mzscheme -f ${SCHEME_LIBRARY_PATH}mzscheme.init
scheme -load ${SCHEME_LIBRARY_PATH}mitscheme.init
gsi -:s ${SCHEME_LIBRARY_PATH}gambit.init -
sisc -e "(load \"${SCHEME_LIBRARY_PATH}sisc.init\")" --
kawa -f ${SCHEME_LIBRARY_PATH}kawa.init --
Guile versions 1.6 and earlier link to an archaic SLIB version. In RedHat or Fedora installations:
rm /usr/share/guile/slib ln -s ${SCHEME_LIBRARY_PATH} /usr/share/guile/slib
In Debian installations:
rm /usr/share/guile/1.6/slib ln -s ${SCHEME_LIBRARY_PATH} /usr/share/guile/1.6/slib
${SCHEME_LIBRARY_PATH}
is where SLIB gets installed.
Guile before version 1.8 with SLIB can then be started thus:
guile -l ${SCHEME_LIBRARY_PATH}guile.init
Guile version 1.8 and after with SLIB can then be started thus:
guile -l ${SCHEME_LIBRARY_PATH}guile.init \ -l ${SCHEME_LIBRARY_PATH}guile.use
The Guile manual has a different way of installing SLIB:
http://www.gnu.org/software/guile/manual/html_node/SLIB-installation.html
To make a Scheme48 image for an installation under <prefix>
,
cd
to the SLIB directory
make prefix=<prefix> slib48
.
make prefix=<prefix> install48
. This
will also create a shell script with the name slib48
which will
invoke the saved image.
From: Matthias Blume <blume @ cs.Princeton.EDU> Date: Tue, 1 Mar 1994 11:42:31 -0500
Disclaimer: The code below is only a quick hack. If I find some time to spare I might get around to make some more things work.
You have to provide vscm.init as an explicit command line argument. Since this is not very nice I would recommend the following installation procedure:
(load "vscm.init")
(slib:dump "dumpfile")
mv dumpfile /usr/local/vscm/lib/scheme-boot
In this case vscm should have been compiled with flag:
-DDEFAULT_BOOTFILE=’"/usr/local/vscm/lib/scheme-boot"’
See Makefile (definition of DDP) for details.
S7 is not a standalone implementation, but runs as the extension language for the Snd sound editor. ${SCHEME_LIBRARY_PATH}s7.init can be loaded from the Snd init file or on the Snd command line thus:
snd -l ${SCHEME_LIBRARY_PATH}s7.init
Next: The SLIB script, Previous: About SLIB, Up: About SLIB [Contents][Index]