m3build contains some built-in support for machine and operating system dependencies. The package structure makes provision for separate build directories for different machine and operating system combinations. The default behaviour of m3build is to generate the compiled object files, libaries and programs in the build directory corresponding to the machine and operating system on which m3build is executing.
The following set of variables exist to allow m3makefiles to be parameterised by machine and operating system.
TARGET
This variable defines the machine type on which the library or
program being built will execute. It is chosen from the standard
set of machine types on which Modula-3 runs. Check the runtime
or m3build packages for the complete set.
OS_TYPE
This variable defines the operating system under which the library
or program being built will execute. Currently, Modula-3 supports
two operating system variants, POSIX and WIN32. The former breaks
down further into specific variants, but this variation is not made
available to clients. [There is a way if you absolutely need it,
see the unix package.]
BUILD_DIR
This names the package sub-directory in which object files,
libraries and programs will be built. It is usually, but not
always, the same as TARGET.
The net effect of the above allows a single package to build a family of architectural variants, in different build sub-directories, where each variant uses the same set of m3makefiles, parameterized by the above variables. If this degree of flexibility is insufficient, then the extra variation must be specified in a separate package, which can use include_pkg to access the shared sources.
PKG_USE
This defines the location of the public package repository, e.g.
/proj/m3/pkg or /usr/local/lib/m3/pkg.
WDROOT
This defines the standard location for a user's private package
repository, typically $HOME/m3/pkg. This is typically used in
override calls.
Last modified on Thu Jan 4 11:07:52 PST 1996 by heydon
modified on Thu Apr 21 17:02:17 PDT 1994 by kalsow
modified on Thu Jan 7 18:40:57 PST 1993 by muller
Copyright (C) 1992, 1996, Digital Equipment Corporation. All rights reserved.