Nokia nmake Product Builder
Customer Support Newsletter

http://www.bell-labs.com/project/nmake/newsletters/

Issue No. 33 - March 2010
Contacts
Articles
  1. nmake 12 Release Schedule
  2. Structured Build Log Documentation
  3. :LIBRARY: changes in nmake 11
  4. Feedback and Suggestions

nmake 12 Release Schedule

The team is working towards the nmake 12 release targeted for 3Q2010. The beta period is tentatively scheduled for 6/9/2010 through 7/16/2010. If you are interested in trying the beta please let us know at nmake@alcatel-lucent.com. Here are some of the changes targeted for the new release in addition to the usual fixes and enhancements.

index

Structured Build Log Documentation

Alcatel-Lucent nmake release 11 and above can output build logs in an XML structured format. This facilitates automated build log processing and analysis. Applications include build log visualization and build performance analysis. The standard XML format allows use of widely available tools and libraries to speed implementation of such applications.

New documentation for the feature is now available on our web site. The documentation includes details of how to generate an XML build log, a description of the XML elements and examples of processing the XML build log using different scripting languages such as XSLT, Groovy and Scala.

For details all the build log documentation can be found on the Structured Build Log Documentation page.

index

:LIBRARY: changes in nmake 11

The nmake 11 release changed the output of the :LIBRARY: operator when building versioned shared libraries. The change is intended to make the feature more friendly for users and to bring the versioned library name up to date with current industry practice. We'll illustrate the new behavior by building libabc with the following makefile:

CC = gcc
CCFLAGS += $$(CC.PIC)
LIBDIR = lib
:ALL:
abc :LIBRARY: abc.c

Previous releases will build an archive library and a shared library with version "1.0". The following example uses nmake 10.

$ nmake
+ gcc -O -D_PIC_ -I- -c abc.c
+ ar r libabc.a abc.o
ar: creating libabc.a
+ rm -f abc.o
+ ld -G -o libabc.so.1.0 -zallextract libabc.a -zdefaultextract

$ ls -l libabc*
-rw-r--r-- 1 richb richb  716 Mar 15 16:44 libabc.a
-rwxr-xr-x 1 richb richb 1780 Mar 15 16:44 libabc.so.1.0

Running nmake install installs the versioned .so (or .sl on HP-UX) as a versioned .no file and creates symbolic links for the .so and versioned .so files.

$ nmake install
+ cp libabc.a lib/libabc.a
+ /usr/bin/rm -f lib/libabc.so
+ /usr/bin/ln -s libabc.so.1.0 lib/libabc.so
+ /usr/bin/cp libabc.so.1.0 lib/libabc.to.1.0
+ /usr/bin/rm -f lib/libabc.so.1.0
+ /usr/bin/ln -s libabc.to.1.0 lib/libabc.so.1.0
+ /usr/bin/ln lib/libabc.to.1.0 lib/libabc.no.1.0
+ /usr/bin/rm -f lib/libabc.so.1.0
+ /usr/bin/ln -s libabc.no.1.0 lib/libabc.so.1.0
+ /usr/bin/rm lib/libabc.to.1.0

$ ls -l lib
total 8
-rw-r--r-- 1 richb richb  716 Mar 15 16:44 libabc.a
-rwxr-xr-x 1 richb richb 1780 Mar 15 16:44 libabc.no.1.0
lrwxrwxrwx 1 richb richb   13 Mar 15 16:44 libabc.so -> libabc.so.1.0
lrwxrwxrwx 1 richb richb   13 Mar 15 16:44 libabc.so.1.0 -> libabc.no.1.0

With nmake 11 an archive library is generated and a versioned shared object using version 1 by default instead of 1.0. Running nmake install installs the versioned .so and creates a single symbolic link for the unversioned .so. Here is the example using nmake 11.

$ nmake
+ gcc -O -D_PIC_ -I- -c abc.c
+ ar r libabc.a abc.o
ar: creating libabc.a
+ rm -f abc.o
+ ld -G -o libabc.so.1 -zallextract libabc.a -zdefaultextract

$ ls -l lib*
-rw-r--r-- 1 richb richb  716 Mar 15 16:50 libabc.a
-rwxr-xr-x 1 richb richb 1776 Mar 15 16:50 libabc.so.1

$ nmake install
+ cp libabc.a lib/libabc.a
+ cp libabc.so.1 lib/libabc.so.1
+ /usr/bin/ln -s libabc.so.1 lib/libabc.so

$ ls -l lib
total 8
-rw-r--r-- 1 richb richb  716 Mar 15 16:51 libabc.a
lrwxrwxrwx 1 richb richb   11 Mar 15 16:51 libabc.so -> libabc.so.1
-rwxr-xr-x 1 richb richb 1776 Mar 15 16:51 libabc.so.1

Note that major.minor version numbers can still be specified in the makefile if needed. For example, the following will generate libabc.so.1.1:

abc 1.1 :LIBRARY: abc.c

The new behavior is more straight forward and in line with expectations. If you passed up using :LIBRARY: in the past it is a good time to take another look. For more information on the :LIBRARY: operator see the article Building Shared Libraries from issue 7.

index

Feedback and Suggestions

We are interested in any feedback you might have about nmake. Please send comments / suggestions to nmake@alcatel-lucent.com.

We're also open to suggestions for future articles. If there is anything you would like to see in the newsletter please send us a note to nmake@alcatel-lucent.com. Thanks for your support!

index

<<home / newsletters