bug-make
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

MAKEFLAGS set too late


From: Tom Tromey
Subject: MAKEFLAGS set too late
Date: Tue, 27 Aug 2013 12:54:02 -0600
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux)

Consider this Makefile:


================================================================
z := $(MAKEFLAGS)

all:
        @echo $(z)
================================================================

I think that "make -j" should print "j".
However, it does not:

barimba. make -j

barimba. 


This is a contrived example but in practice what it means is that one
cannot use MAKEFLAGS in some "if" conditions.  For instance, if you
rewrite the example from (make) Testing Flags so that each branch of the
"if" declares the target "archive.a:", it will no longer work.

Tom



reply via email to

[Prev in Thread] Current Thread [Next in Thread]