The syntax
foo:=CFLAGS=-DFOO
for redefining CFLAGS for the target foo seems like a great thing, but it's not valid in gnu-make. I'm currently setting up my make files so that I type "make DEBUG=1" and then defining CFLAGS conditionally based on the definition of DEBUG. I'd much rather type "make debug" and use the syntax given above. 2 questions:

1)  Is it possible to do something like:
if target==debug;    CFLAGS = -DDEBUG; end if
rather than:
ifdef DEBUG; CFLAGS = -DDEBUG; end if

2) Why is the conditional macro definition syntax not incorporated into gnu-make?
It seems like a good idea.


_______________________________________________
Help-make mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-make

Reply via email to