I think it might be necessary. What if you had:
$ make -- -FOO=bar
I think without the -- this would cause problems.
I don't know why anyone would want to begin a variable name with '-' but interesting thought...
However it appears to be broken: it DOES cause problems because make does not insert the '--' in that case.
Normally, by default, overrides are passed to submakes, but this example, they aren't. Seems to be a bug. I tested passing option to submake: $(MAKE) -k baz, with the same results.
# Makefile
$(warning MAKEFLAGS=$(MAKEFLAGS))
bar:
@#$(warning MAKEFLAGS=$(MAKEFLAGS))
$(MAKE) baz
baz:
@#$(warning MAKEFLAGS=$(MAKEFLAGS))
#eof[EMAIL PROTECTED] junk]$ make -k FOO=foo bar Makefile:3: MAKEFLAGS=k Makefile:5: MAKEFLAGS=k -- FOO=foo make baz make[1]: Entering directory `/usr/local/apache/htdocs/common/test/junk' Makefile:3: MAKEFLAGS=wk Makefile:8: MAKEFLAGS=wk -- FOO=foo make[1]: Leaving directory `/usr/local/apache/htdocs/common/test/junk'
[EMAIL PROTECTED] junk]$ make -- -FOO=foo bar Makefile:3: MAKEFLAGS= Makefile:5: MAKEFLAGS=-FOO=foo make baz make[1]: Entering directory `/usr/local/apache/htdocs/common/test/junk' Makefile:3: MAKEFLAGS=w Makefile:8: MAKEFLAGS=w make[1]: Leaving directory `/usr/local/apache/htdocs/common/test/junk' [EMAIL PROTECTED] junk]$
- Greg Keraunen http://www.xmake.org
_______________________________________________ Help-make mailing list [EMAIL PROTECTED] http://mail.gnu.org/mailman/listinfo/help-make
