Nokia

Nokia nmake Product Builder

 

Nokia nmake Product Builder
nmake 13 Release Notes

Table of Contents

Released: July 2011

1. Introduction
1.1 Supported Hardware
1.2 Hardware Requirements
1.3 Software Requirements
1.4 Customer Support

2. New Features and Significant Enhancements
2.1 Additional messages for the --explain option
2.2 Improved support for Solaris 10 ksh
2.3 Certification for Solaris Studio 12 update 2
2.4 Fixes in Java build support

3. Bug Fixes and Enhancements
3.1 Baserules
3.2 cpp
3.3 Engine
3.4 Operators
3.5 Probe
3.6 Build Log
3.7 Miscellaneous
3.8 Variables
3.9 Options

4. Changes Impacting nmake 12 Makefiles

5. Known Problems and Remarks
5.1 Known Problems
5.2 Remarks


1. Introduction

This document announces the new release of nmake version 13. nmake is fully supported and is in wide production use throughout Alcatel-Lucent, AT&T, and elsewhere.

These nmake 13 Release Notes discuss in detail the new features, and highlight bug fixes, additional enhancements, and known problems.

1.1 Supported Hardware

The nmake 13 release has been ported to many UNIX-based and UNIX-like systems. For a current list see the Download Chart on the nmake web site, http://www.bell-labs.com/project/nmake/. Or contact the Customer Support helpdesk below.

1.2 Hardware Requirements

1.3 Software Requirements

The nmake 13 release is available for HP-UX, Linux, Solaris, and Windows (under SFU/Interix). See the nmake 13 download page for a listing of available distribution packages. nmake is generally upward compatible with later OS releases in a series (for example, the series Solaris 2.5 through 2.10); contact Technical Support with any compatibility questions or requests for porting to other systems.

The Windows-based version of nmake is based on the Windows Services for UNIX (SFU/Interix) porting/development environment from Microsoft and requires installation of the SFU package in order to run. The SFU package must be obtained from Microsoft and installed following their installation procedure. For more information see the Support for Windows page.

nmake 13 provides dependency-based Java build support. This feature currently requires an external Java source scanner called JavaDeps to extract inter-modules dependencies from Java source. nmake 13 requires JavaDeps release lu2.2.4 or greater. The latest version is downloadable from the nmake JavaDeps page. Installation instructions are also on that page. THIS PACKAGE IS ONLY REQUIRED BY PROJECTS PERFORMING JAVA BUILDS USING THE :JAVA: ASSERTION OPERATOR. JavaDeps release lu2.2.4 is itself written in Java; it requires jdk1.2.1 or higher version on its PATH in order to run. (Note that this does not restrict the project being built to jdk1.2.1 or higher.)

The buildlog2html command requires Java runtime 1.5 or above. It will also use Graphviz dot and neato commands, if available, to generate diagrams showing build log structure. Graphviz versions 2.16 or above are known to work. buildlog2html generates an HTML log from a structured build log.

1.4 Customer Support

We provide patch support, where code changes are required, for the latest 2 point releases of nmake (currently releases nmake 13 and 12). Customers using older releases can still acquire help in using the product, but genuine problems found in older releases will not be fixed. Such problems may require an upgrade to a current release or, when possible, a makefile work-around will be provided.

Fee-based services are also available. These include makefile rewrites, conversion of non-nmake makefiles to nmake, integration with vendor tools, build assessments, and porting nmake to new machines.

Contact Customer Support for any questions regarding nmake.


2. New Features and Significant Enhancements

2.1 Additional "explain" messages

"Explain" messages have been added to several cases where actions were triggered without a corresponding message. Explain messages are printed by nmake when the explain (-e) option is enabled to show why it is taking certain actions, in general explaining why actions are triggered. Explain messages are also captured in state files and structured build logs (see nmake 12 Release Notes).

The following messages have been added.

message description
no file for target target target is made because the generated target file does not exist
target has .FORCE attribute target is triggered because its action is forced with the .FORCE special atom
target force option enabled target is updated because the force (-F) option is enabled
target :cc: sub-make update (see null.ms) target is made by a sub-make process to compile :cc: files, for details run nmake -lef null.ms

2.2 Improved support for Solaris 10 ksh

The Solaris 10 system ksh includes a change in behavior from previous Solaris releases that may impact use with nmake. It now initializes the PWD environment variable to the absolute, physical path of the current directory with no symbolic links. If /bin/ksh is started in a directory under a symbolic link then PWD is set to the path with no links which gives PWD a different value than the parent environment. The change appears to be intentional.

The new behavior can cause a problem with the nmake viewpath since the value of PWD must be under the first node in the VPATH. If your home directory is under a symbolic link then upon logging in PWD will be set to the physical path and may not match HOME, which can cause problems if HOME is used to set VPATH. Another issue is during a recursive build, nmake spawns new ksh and nmake processes to build sub-directories and makefiles. If a build is started under a symbolic link and the system ksh is spawned then PWD will not match the VPATH node.

nmake works around the new Solaris ksh behavior by detecting when PWD is a physical path under the logical node in the VPATH. When this is detected a warning is issued and nmake changes directory to the corresponding VPATH directory before processing the makefile. Spawned shell processes are also initialized with the expected value of PWD so recursive makes inherit the correct environment.

If the warning is encountered it is recommended to fix the environment by either changing the current directory to match the first node of the VPATH before starting the build, or changing VPATH to match PWD. Below is a simple example.

$ echo $PWD
/home/richb/builds/v1/src

$ echo $VPATH
/home/richb/node1

$ ls -ld /home/richb/node1
lrwxrwxrwx 1 richb richb 9 Jun 22  2010 /home/richb/node1 -> builds/v1

$ nmake
make: warning: PWD must be under the first VPATH node - PWD [/home/richb/builds/
v1/src] is physical path under VPATH [/home/richb/node1/src] logical path - chan
ging directory to logical path: /home/richb/node1/src
+ gcc -O -I- -c hello.c
+ gcc -O -o hello hello.o

$ cd /home/richb/node1/src

$ echo $PWD
/home/richb/node1/src

$ nmake clobber
+ ignore rm -f hello Makefile.mo Makefile.ms hello.o

$ nmake
+ gcc -O -I- -c hello.c
+ gcc -O -o hello hello.o

2.3 Certification for Oracle Solaris Studio 12 update 2

Oracle Solaris Studio 12.2 has been certified with nmake 13 with no issues. According to the Solaris Studio documentation as of Studio 12.1 the RogueWave headers and libraries (rw7) are deprecated and by default they are not searched by the C++ compiler. Therefore they do not get included in the default nmake search paths as well (CC.STDINCLUDE and CC.STDLIB probe variables). The RogueWave libraries can be accessed using the -library=rwtools7_std option to the C++ compiler. If the libraries are needed it is best to add this option to the nmake CC variable so the additional search directories will be picked up by nmake probe. For example:

CC = /opt/SUNWspro/bin/CC -library=rwtools7_std

2.4 Fixes in Java build support

Several improvements have been made to the Java build support.


3. Bug Fixes and Enhancements

3.1 Baserules

3.2 cpp

  1. No changes to cpp in this release.

3.3 Engine

  1. 030091 - metarule causes infinite loop
    Adding certain metarules would cause a loop when nmake performs metarule closure, which is the process of determining what all can be generated by chaining metarules together. nmake now detects the loop, issues a warning and breaks out of the loop. Additionally, if metarule closure takes more than 5 seconds a warning is issued so the rules may be addressed.
  2. 060045 - add -e explain output for archive targets
    Some archive targets with custom rules would rebuild with no explain message. The rebuild was in error, nmake no longer needlessly rebuilds these targets.
  3. 070043 - no explain info when target not generated
    A new explain message has been added for the case when a target is triggered because the target file does not exist -- "no file for target target".
    See also New Features and Enhancements: Additional "explain" messages.
  4. 090025 - read statement zeros file
    The nmake command read -o file VAR would open file for writing and zero out the file. The correct option is -i to open an input file for reading. The read and print commands now give errors on invalid options and do not touch the specified file in that case. The -p flag has been documented for both the read and print commands to read/print to/from a process (eg. read -p command VAR).
  5. 100001 - missing explain info
    The following explain messages have been added for targets that are forced to build with the .FORCE special atom or the force (-F) option respectively -- "target has .FORCE attribute", "target force option enabled".
    See also New Features and Enhancements: Additional "explain" messages.
  6. 100015 - solaris 10 ksh pwd avoids symbolic links
    If the current directory does not match the first viewpath node then nmake attempts to detect if it is running in a physical path that corresponds to the first viewpath node and if so nmake changes the current directory to the corresponding viewpath directory, issues a warning and continues processing the makefile. Also the current directory in spawned shell processes is initialized to the correct directory to avoid problems with the shell expanding symbolic links in the default PWD.
    For details see New Features and Enhancements: Improved support for Solaris 10 ksh.
  7. 100020 - no explain message for :cc: target
    A new explain message has been added for targets built for the :cc: operator. The :cc: operator builds its .o targets by running a sub-nmake process which is always triggered to keep the objects up to date. The sub-process has the details for why individual objects are updated. The parent nmake process issues the following explain message for :cc: targets -- "target :cc: sub-make update (see null.ms)".
    See also New Features and Enhancements: Additional "explain" messages.
  8. 100025 - core dump on :M
    A memory corruption which caused a core dump has been fixed. The problem was triggered by certain uses of the :M edit operator.

3.4 Operators

  1. 090029 - install should build :JAVA: targets by default
    The :JAVA: operator is now more consistent with the :: operator. See also New Features and Enhancements: Fixes in Java build support.
  2. 100016 - :cc: causes header scan
    Under certain conditions nmake would scan a :cc: source file for include files for the CC compiler before it is scanned for the cc compiler. In cases where the two compilers pick up different system headers a warning could be generated that the header was replaced by an older version. The extra, unnecessary file scan has been eliminated which also eliminates the bogus warning message.
  3. 100026 - jar file in java package dir causes rebuild
    A jar file inside a Java source package directory as defined with the :JAVA: operator no longer causes unnecessary rebuilds of the Java code.
    See also New Features and Enhancements: Fixes in Java build support.
  4. 110001 - remove and add jar prereq does not update jar target
    Removing a prerequisite of a :JAR: assertion from a makefile, rebuilding the jar target, and then adding the prerequisite back to the makefile correctly updates the jar target again.
    See also New Features and Enhancements: Fixes in Java build support.
  5. 110006 - JAVACLASSDEST change should rebuild class files
    Changing the value of the JAVACLASSDEST variable in a :JAVA: makefile will now update the Java dependencies and rebuild the Java code with the new class directory (110006).
    See also New Features and Enhancements: Fixes in Java build support.

3.5 Probe

  1. 100019 - CC.LD for gcc 4.x
    For some versions of the gcc/g++ compilers probe was setting CC.LD to ld instead of the compiler and CC.SHARED to -G. This could cause problems building and linking with shared libraries when using g++. Probe now correctly detects the CC.SHARED option as -shared and sets CC.LD to the compiler.

3.6 Build Log

  1. 090017 - makelog end tag not written when license check fails
    The structured build log now gets the makelog end tag (</makelog>) when the license check fails and on other unexpected errors.
  2. 100007 - include structured build log dtd in product
    The structured build log document type definition is now included in the nmake package as lib/builddata/buildlog.dtd.
  3. 100024 - capture needed explain map version in structured build log
    The new element emapver is now included in the structured build log to define the version of the explain.map file used for the build. Scripts processing a structured build log can get the required explain.map version from the log and then verify access to the same version or any later version to translate explain codes or issue a warning if only earlier versions are available. Old build logs without emapver use explain.map v1.
  4. 110004 - need special handling for certain control characters
    For structured build logs, invalid control characters which cannot be represented in XML are now mapped to an ASCII sequence representing its code value. The invalid characters are mapped to \xhh where hh is the hexadecimal value of the character.
  5. 110010 - update buildlog document for emapver
    The structured build log documentation and DTD have been updated to include the new emapver element which indicates the version of the explain.map file used in the build.
  6. 110014 - update logo in html build logs
    The Alcatel-Lucent logo used in the generated html build logs has been updated to the 2011 version.

3.7 Miscellaneous

  1. 090021 - problems with formatting of examples in man pages
    The man pages were changed to be more portable across platforms, in particular fixing issues with examples.
  2. 090031 - certify Sun Studio 12 Update 1
    Oracle Solaris Studio 12.2 has been certified with nmake 13 with no issues.
    For details see New Features and Enhancements: Certification for Oracle Solaris Studio 12 update 2.
  3. 100018 - user manuals
    The structure of the User's Guide and the Reference Manual have been reorganized for improved PDF viewing. Document page numbers are now in sync with page numbers shown by common PDF viewers.

3.8 Variables

  1. Change to variable CC.LD - see 100019.
  2. Change to variable CC.SHARED - see 100019.
  3. Change to variable JAVACLASSDEST - see 110006.

3.9 Options

  1. Change to option --explain - see 070043, 100001, 100020.

4. Changes Impacting nmake 12 Makefiles

The changes in nmake 13 are largely backward compatible with nmake 12. Every effort has been made to insure code changes do not unexpectedly change the documented behavior of nmake features. For makefiles that conform to nmake's documentation there will be no makefile updates necessary to migrate from nmake 12 based release to nmake 13.


5. Known Problems and Remarks

5.1 Known Problems

The following is a list of known problems:

  1. 980009 - problem in link=*
    The problem about using linking (specified using the link variable) to install targets in any adjacent nodes in viewpathing still exists. You may still use linking to install, but only in alternate nodes -- installation using copying must alternate with installation using linking. The problem occurs with both symbolic and hard linking.
  2. 030042 - :cc: generated header rebuild
    If a C file is built by using :cc: and this C file shares a generated header file with a C++ file specified in the same makefile, the generated header file may get regenerated during the build causing the source files to keep recompiling. This can be avoided by building the C++ files before the C files, or by generating the header file in a separate makefile at an earlier time during the build.
  3. 990099 - metarules not searched when CC.REPOSITORY is set
    The metarules may not be searched under the following conditions: there is a user defined metarule for a non-compiled file, variable CC.REPOSITORY is defined and CC.DIALECT contains either PTRIMPLICIT or PTRMKDIR, and :: is used to trigger the metarule. Note that CC.REPOSITORY and CC.DIALECT are defined as such in the probe file for some C++ compilers. The work-around is to add .IMPLICIT to the :: assertion, or to not use the :: assertion (such as add the target to :ALL: instead.)
  4. 020018 - adding shared lib building in same makefile won't re-link
    An executable target will not be re-linked when a shared library that is built in the same makefile is added as a prerequisite to the executable. The work-around is to set force_shared=1.
  5. 020051 - first metarule is used by mistake
    When multiple metarules generate the same source file target, such as %.c, the first metarule defined matching an existing file will be triggered instead of the metarule matching the explicit file prerequisite.
  6. 070010 - fails to bind large files
    nmake does not have large file support and cannot reference files over 2 GiB in size.

5.2 Remarks

  1. :LINK: does not handle archive files that are generated by :: or :LIBRARY: assertion operators. Users should avoid use of :LINK: on archive files.
  2. When the cpp -I-S flag is on, -D-M is disabled. Users should not use these two flags together.
  3. Users should avoid including the same header file with both <...>-style and "..."-style #include statements in source files managed by a single makefile. nmake will assign .STD.INCLUDE and .LCL.INCLUDE attributes to the header file, and this can result in incorrect -I lists in the compiler command lines generated.
  4. When the SHELL environment variable points to ksh93 you may get the following warnings when building your shell scripts: warning: line 1: `...` obsolete, use $(...). The warning is generated running your script with ksh -n. To eliminate the warning either update your shell scripts as indicated by the message or set SHELL to another version of ksh that does not generate the warning, such as ksh88.

Last Update: Friday,12-Aug-2016 12:25:42 EDT