Alcatel-Lucent nmake Product Builder
High Level Build Assertions
Feature Description
The default base rules provides a set of high level assertion operators to support building common types of targets (executables, libraries, java classes, etc.) from common languages. Users can program their own assertions to simplify Makefiles and to avoid redundant specification of project build procedures. Details are specified only once in a base or global Makefile, updating these automatically updates the behavior in all Makefiles for enhanced portability.
Impact
Productivity
- Development time is saved by not having to write and maintain custom rules.
- The size and complexity of makefiles is reduced.
- Brings consistency among developers and projects.
- Allows specification of what to build, not how to build it.
Build Accuracy
- Consistent makefiles among developers leads to fewer errors.
- Small and simple makefiles are less error prone.
Consequence of Not Having the Feature
- Makefiles become more complex and error prone.
- Inconsistency may rise from developers implementing actions differently.
Examples
The following example uses the built-in double colon (::)
assertion operator. An executable named abc will be
generated from the source files listed on the right hand side and
linked with libxyz. The man page abc.1 will be installed
in the corresponding man directory if the install common
action is used.
INSTALLROOT = $(VROOT) .SOURCE.a : $(LIBDIR) abc :: a.c b.c c.c -lxyz abc.1
$ nmake install + cc -O -I- -c a.c + cc -O -I- -c b.c + cc -O -I- -c c.c + cc -O -o abc a.o b.o c.o ../../lib/libxyz.a + cp abc ../../bin/abc + cp abc.1 ../../man/man1/abc.1







