Jeff.Rosenfeld@FAA.SPEECH.CS.CMU.EDU (07/31/89)
Greetings. In gnu-make version 3.05 the variable $(MAKELEVEL) does not get initialized to 0 in the top-level makefile; it is initially empty although it does get set to the proper values in sub-makes. A trivial makefile to demonstrate this is: ------------ all: @echo $(MAKELEVEL) ------------ Make echos a blank line instead of the zero it should print. I found another bug, too: the subst function doesn't aopear to understand spaces in the from string (this is still, of course, with version 3.05). Here's the makefile I am trying to use: ------------- TMP := $(MAKE) MAKE := $(subst X=$(X),,$(MAKE)) all: @echo $(TMP) $(MAKE) foo foo: @echo $(MAKE) --------------- The command: make all X='a' works as expected; the submake doesn't attempt to define X on the command line. The command: make all X='a b' however, doesn't kill the definition of X. Thank you for any attention you can give these problems, - Jeff Rosenfeld, jdr@andrew.cmu.edu.