Greg Chicares wrote:
I'm working with someone who wants to do this:
$export CFLAGS="set_in_environment"
$make -f make_0
CFLAGS = -g
I understand why that example works that way, but my friend wants his
environment setting to prevail, without requiring 'make -e': he thinks
any other behavior is astonishing. ...
Am I missing some obvious solution?
Yup. Have him specify the flags on the commandline:
$ make -f make_0 CFLAGS="-g"
By the way, it's standard practice in some circles to
have the Makefile's CFLAGS include $EXTRA_CFLAGS or
something like that, where EXTRA_CFLAGS is empty.
That way the user can *add* flags easily by overriding
EXTRA_CFLAGS.
- Dan
--
Trying to get a job as a c++ developer? See
http://kegel.com/academy/getting-hired.html
_______________________________________________
Help-make mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-make