first previous next last contents

Wrapping it all up

We've now got all the code that we need to build a complete package. If this package is to be kept separate from the main Staden Package installation tree then we need to build our own directory tree for the package.

For example, we'll create a separate directory for the composition package named `/home/spackages'. Within this directory we should place the rc file (`compositionrc'), the documentation (`composition.topic', `composition.index' and `composition.html') and the Tcl files `composition.tcl' and `tclIndex'.

Additionally we need to have a dynamic library containing the C command. This should be placed in `/home/spackages/MACHINE-binaries/' where `MACHINE' is the machine type (eg alpha, solaris, sun, sgi, linux or windows). The library will probably be named something like `'.

The actual compilation of the library is complicated due to each machine type having different linker options. The full description of the Makefile system is beyond the scope of this documentation, but in brief, the system works by having a single `Makefile' for the package, a `' file in the `$STADENROOT/src/mk' directory containing general definitions, and a system specific (eg `') file also in `$STADENROOT/src/mk' defining system architecture specific definitions. These combine to allow system independent macros to be used for building dynamic libraries. The complete composition package Makefile is in the appendices.

Once the package has been installed correctly an ls -R on the installation directory should look something like the following.

alpha-binaries/     composition.index   composition.topic   tclIndex
composition.html    composition.tcl     compositionrc

./alpha-binaries:   so_locations

Note that packages for multiple architectures may share the same installation tree as each architecture will need only its own `MACHINE-binaries' directory.

The final requirement is to add the package onto gap4. This is done by adding the following to the users `.gaprc' file (where `/installation/directory/' is the location where containing the list of files).

load_package /installation/directory/composition

first previous next last contents
This page is maintained by staden-package. Last generated on 1 March 2001.