Hello,

I'd say to keep all your C compiler flags in a separate variable,
MY_CFLAGS, say.

Then your rule shoudlmention the two variables, e.g.:

%.o: %.c
        $(CC) $(MY_CFLAGS) $(CFLAGS) -c $<

In this way, users can specify the CFLAGS they want without risking to
accidentally override something the build  system wants. And at the same
timethey have the lastword.

Same goesfor CPPFLAGS, LDFLAGS etc.

hth,

Seb.

Reply via email to