Nokia nmake Product Builder
Release Notes -- Nokia nmake 3.0
[Table of Contents]
- Engine Variable MAKEBUFFERSIZE Has Been Deleted.
now dynamically allocates buffer space.
- Change in Default Value of RMFLAGS.
The default value of RMFLAGS has been changed from
-rf to -f.
- The Variable Expansion Time Changed in :IDENTIFIER:
The variables used in the target and prerequisite positions of the
:IDENTIFIER: assertion operator will be expanded at compile
time instead of at execution time. For example:
Tmps = $$(!$(TSPEC):N=*.tbl:B:S=.tmp)
$(GENHDRS) $(Tmps) :JOINT: $(TSPEC)
To have this 2.2 makefile work in 3.0, $(Tmps) has to
be changed to $$(Tmps).
Another example of this is:
$$(LBINDIR) :INSTALLDIR: pgm
LBINDIR = $(INSTALLROOT)/lbin
has to be changed to:
LBINDIR = $(INSTALLROOT)/lbin
$(LBINDIR) :INSTALLDIR: pgm
so that $(LBINDIR) will have the desired value at the
makefile compile time.
- :INSTALLDIR: Now Makes Directories to Any Depth
:INSTALLDIR: now makes the directory specified on the
lhs of the operator to the depth as specified. For example,
$(INCLUDEDIR)/subA/suba :INSTALLDIR: myfile
Here, make the directories of $(INCLUDEDIR),
$(INCLUDEDIR/subA, and $(INCLUDEDIR)/subA/suba, if those
directories don't exist at installation time.
- Changes file permissions in :INSTALLDIR:
The syntax of change file permissions at installation by
using :INSTALLDIR: is changed. The new syntax is
$(BINDIR) :INSTALLDIR: user=root group=adm mode=4755 file1
where user= is for changing user ID, group= is for,
changing group ID, and mode= is for changing permissions of the
- :LIBRARY: Only Makes .a by Default
:LIBRARY: makes .a only by default, even if
CCFLAGS+=$$(CC.PIC) is on. To make a shared library, one has
to have :ALL: in the beginning of the makefile, or give the
all or the install common action on the command line.
- Output Format of :COMMAND:
changes the blank space
to a new-line ("\n") character after each shell output to
the lhs variable of :COMMAND:. For example,
The content of LIST was "A B" in 2.2, but now is
"A\nB". If one wants to change the new-line character
to be a space, one has to edit the variable by using edit operator
:C. For example:
- -H (headerstate)
The Command line Option headerstate (-H)
has been deleted.
- -x (expandview)
A new option expandview (-x) has been added.
The expandview command line option should be used when using
the 3DFS(tm) on the main machine and using
coshell to access non-3D machines.
The expandview option forces to generate full
path names for viewpathing.
- -M (mam)
The -M used with -k (keepgoing) and -x
(expandview) causes to generate different output. This may be necessary
under certain circumstances. See Section 4.4.3 for details.
- User-defined Options
The definition and usage of a user-defined option, option,
have been changed. The definition of the option is now
The flag is the option flag that can be used on the command line
associated with - or +. (e.g. -u); the
name is the option name that can be used with -o
(e.g. -o unconditional); the type is the type of the
option, which must be one of b (boolean), s (string),
or n (numeric); function is the function name in the
Makefile which acts on the value assigned to the option name, given:
the usage is either
nmake -o unconditional
In this example, the flag of the user-defined option is u;
the name is unconditional; and the type is boolean; the function
name is .set.opt. When the option is used, the function
.set.opt will be invoked. In this example, the function sets
force or noforce option, depending on whether the
user-defined option is used or not.
nmake now also passes the user-defined options to $(-)
- The special atoms .UNTOUCH, .MAKEPPFLAGS,
.MAKEPREREQ, .MAKESCAN, and .PRECIOUS
have been deleted.
- The special atom .TOUCH has been replaced by .REBIND.
The special atom .REBIND supports targets generated in
- The special atom .DEBUG now is aliased to .QUERY.
- The action of special atom .DONE is now saved in the state files.
- :M now uses the egrep pattern matching scheme.
STRING = abcd 1234 efgh 5678
SOMEFILE = $(STRING:M=.*[cf8].*)
$(%) instead of $(.SCAN.) is used in SCAN
syntax M (map).
For example, in the following INFORMIX 4gl scan rules:
.SCAN.4gl : .SCAN
I| globals '%' |A.4GL.INCLUDE|
I| globals "%" |A.4GL.INCLUDE|
I| GLOBALS '%' |A.4GL.INCLUDE|
I| GLOBALS "%" |A.4GL.INCLUDE|
I| # FORMDEF '%' |M$$(.SCAN.:/.*/&.frm/)|
I| # formdef '%' |M$$(.SCAN.:/.*/&.frm/)|
I| # FORMDEF "%" |M$$(.SCAN.:/.*/&.frm/)|
I| # formdef "%" |M$$(.SCAN.:/.*/&.frm/)|
the last four lines must be changed to:
I| # FORMDEF '%' |M$$(%:/.*/&.frm/)|
I| # formdef '%' |M$$(%:/.*/&.frm/)|
I| # FORMDEF "%" |M$$(%:/.*/&.frm/)|
I| # formdef "%" |M$$(%:/.*/&.frm/)|
Scanrules are now documented in detail in Appendix G of nmake
User's Reference Guide.
- Moved $include from .SCAN.F to .SCAN.sql
The file including format, $include, has been moved from
.SCAN.F to .SCAN.sql. If one used .SCAN.F
for searching $include, .SCAN.sql should be used for
- Changes in Option -D
The notation of -D"#define A a" of cpp has changed
to -D"%define A a".
- Change in Option -D-M
By default, 3.0 cpp includes files as they are
seen. The meaning of option -D-M is to include files just one
time. Files with #pragma pp:multiple on the first line will be
included multiple times even if -D-M flag is on.
- Change in Option -D-D
-D-Q replaces -D-D to produce checkpoint dump.
- Change in Option -D-dlevel
-D-dlevel option now is -D-Dlevel
to set debugging trace.
- Deleted Options -D-K and -D-Q
-D-K and -D-Q options have been deleted.
- Change in Pragma pp:map
The directive mapping format, %, has been removed. A
new scheme of mapping has been added. The format is,
#pragma pp:map "matching pattern" "editing expression"
#pragma pp:map "/#c_include>/" "/#c_include(.*)/__C_INCLUDE__(1)/"
#define __C_INCLUDE__(x) #include x
This example maps the #c_include directive to be a
If one used #pragma pp:map in C source code or modified in
probe configuration files, one should change them to the new format.
- Deleted Pragmas
pp:hosted, pp:keyword, pp:passthrough, and
pp:quote pragmas have been deleted.
- Variable CC.PATH has been changed to CC.CC.
- coshell is the network shell coprocess server
It can establish shell coprocesses to machines producing compatible
executables on the local area network and send user jobs to these
shells. If coshell is not present
in <nmake_install_root>/bin, coshell is
not supported for your environment.
- ksh version
The ksh version 11/16/88i (or later) is absolutely required
when using coshell. The command what $(whence ksh)
should return this version as its output.
The SHELL environment variable needs to be set
to the ksh 11/16/88i (or later) version for coshell to work.
- .profile and $ENV
The environment of remote shells is initialized by .profile
and $ENV. Interactive queries within .profile and
$ENV must be disabled for non-interactive shells; otherwise
coshell will fail:
case $- in
The following variables are set up by coshell and can be referenced
in .profile: HOSTNAME, HOSTTYPE, COTEMP.
- Generating the Local Host Attribute File
Local host attribute file contains the names of all the
machines that are available in the local area network along with some
other pertinent information. The file local.ast provided
with the distributed nmake software package (located
in <nmake_install_root>/share/lib/cs) is an example.
Two shell scripts, genlocal and genshare, are provided
with the distributed nmake software package; they are located
in <nmake_install_root>/bin and can be used to
generate the local host attribute file. The local host attribute
file is shared by all the coshell users. It should be manually
updated as hosts are added to or deleted from the local network.
The genshare script is run first to generate information on
servers for the network. By default, this information is stored
in <nmake_install_root>/lib/cs/share. After this
information has been stored, the genlocal script is run to
generate the local host attribute file. By default, this information
is stored in <nmake_install_root>/share/lib/cs/local.
If the share file generated by the genshare script is not
stored in the default path, you must pass its path to the genlocal
script using the -f option. For example,
genlocal -f path_to_share_file
You may modify the generated files to meet your needs.
Please note: coshell requires that the
directory <nmake_install_root>/share be at the
same location on all the hosts specified in the local file.
The <nmake_install_root>/bin/ss command displays host
- Starting coshell
A ksh function cosh is included in the nmake
software package to start/quit coshell. This function resides in the
<nmake_install_root>/fun directory. You may access
it by including this directory in your FPATH environment
variable. cosh starts coshell, cosh -Q kills
the coshell server and appends the output of the date
and the coshell -t -sl -Q commands to $HOME/.cosh.
This function also adds the word 'coshell' to the title bar of the window
which the coshell server is started. The environment variable
NPROC is set to 10. The nmake -j command line
option takes precedence over the NPROC environment variable.
In addition, the environment variable COSHELL is set to
The value of NPROC can be set to a higher number, and
the resulting number of concurrent jobs can be based on the values
of the percpu, peruser, perserver, and
maxload coshell global attributes.
(Please see coshell(1) for details).
coshell uses /tmp to write files.
If /tmp is mounted as a swap
file system, coshell does not work due to a /tmp bug. To
work around this, an environment variable CS_MOUNT_LOCAL needs
to be set to another file system where the user has read and write
permissions. For example:
Files under <nmake_install_root>/share/lib/ss are generated
after coshell starts. Each host entry in
<nmake_install_root>/share/lib/cs/local has a file of the
same name as the host in this directory. For efficiency
the system status of the host is compressed into 8 bytes and stored in
the time stamp field of each file status
and the status is updated every minute.
If the contents of <nmake_install_root>/share/lib/cs/local
gets changed, the deleted host names should be removed from the
- Tips on Taking Advantage of coshell
- A new special atom, .LOCAL has been added to make sure
the $(MAKE) command is executed on the local machine
(see Section 2.4.1).
target: .VIRTUAL .LOCAL
$(MAKE) $(-) $(=)
- If you have :MAKE: in your makefile, you need to set the
base rule variable recurse to an appropriate number n
for coshell to distribute jobs from n directories at
a time. recurse is set to 1 by default.
- The environment variable COATTRIBUTES may be used to
select machines for job distribution. For example,
can be used when one builds the system for the target machines using
a cross-compiler. One may also use this variable in the prerequisite
list so that actions in the assertion may be executed
on specific machine(s). For example:
x.o : COATTRIBUTES="(name=='dodo')"
- The environment variables set or changed after the coshell
server has been started can be passed to shells using the
COEXPORT environment variable. For example, if PS4 and
CHOME are changed to have the following values:
causes these changes to take effect on the other shells.
- Never put 'coshell -r' in makefiles since coshell does not
talk to daemons on other machines.
- If 3d exists in <nmake_install_root>/bin
and COSHELL=coshell, 3DFS(tm)
- Change in Metarule Processing
nmake now supports metarules with multiple rhs patterns:
%.o : %.ch %.sz
- Changes in Output
Two output changes are listed below:
- The message output starting with *** has make:
inserted at the beginning with error level 2. This is consistent
with all the other error message formats from nmake.
- nmake always gives the -I-D option, which points to
the probe configuration file name for the compiler used. This
option replaces the -D-Xcompiler_path option to speed
up cpp preprocessing time.
- nmake Won't Create the .mo File in the Top View
When using viewpathing, nmake now won't drop the .mo file into
the top view if the lower level *.mo is up to date.
- Main Target Needed in Makefiles
If there is no main target in a makefile, the probe
configuration file name was the prerequisite of .MAIN in 2.2.
Now an error message is displayed to notify the user.
[Table of Contents]
Last Update: Friday,12-Aug-2016 12:29:03 EDT