Behind the Scenes

The ISS distribution tree contains programs which require a Zebra installation to build and run, plus it requires some of its own configuration information. It inherits most of the imake tools and configuration from the Zebra installation, adding ISS extensions or changes to the ISS project file Project.tmpl.

The issmkmf script creates a link in the current directory called Zebra.tmpl, which links to the Project.tmpl file in the Zebra installation, usually /zebra/lib/config/project/Project.tmpl. The script then runs Zebra's imake (usually /zebra/bin/imake) to generate the toplevel Makefile, but the current directory is inserted into the include path of cpp. In effect, the ISS Project.tmpl is read in place of Zebra's. This allows the ISS Project.tmpl to first include Zebra.tmpl and then override and extend any definitions and settings according to the needs of ISS.

For example, the LIBDIR and BINDIR settings are changed to point to the bin and lib directories under the ISS top directory. Likewise, some of the rules and make variables must be changed, especially to ensure that the ISS top directory is always first on the imake include path, so that the ISS Project.tmpl will take precedence when generating Makefiles in ISS subdirectories. Project.tmpl also contains the subtle trick of defining the make variable names BINDIR, LIBDIR, and INCDIR as cpp macros for Zebra-specific names so that the conventional variable names can be redefined for ISS.

The ISS Project.tmpl contains the specific mechanisms which allow the Zebra imake setup to be inherited transparently by the rest of the ISS Imakefiles. All of the ISS Imakefiles look like regular Zebra Imakefiles and work similarly. Though not an obvious and straightforward setup, at least the ISS distribution no longer needs the overhead of its own imake setup and configuration, and it can easily take advantage of updates and expansions to the Zebra rule set.