Quoting julvr <[email protected]>:


OK, after some more investigation, it looks like this boils down to whether
EXTRA_CFLAGS is recursivly expanded or simply expanded...  But again, I'm a
bit out of my depth in this:  In the kernel, there are several places where
you see

EXTRA_CFLAGS = xxx

and others where you see

EXTRA_CFLAGS := xxxx

(usb/storage/Makefile and fs/ntfs/Makefile for example)and then a whole lot
of += modifiers...   So if you have both of these in your make-path, which
one takes precedence?  If I include a single file that has a :=, does that
effect all other files, or just sub-makefiles of it?  Does 'export' have any
effect on this

As best as I recall, and I'm away from my regular system so I don't have access to the source ATM, the last one seen takes precedence.

So, in a context where the last assignment was "=", the "+=" is interpreted as a recursive expansion. In a context where the last assignment was ":=", the "+=" is interpreted as a simple expansion. If there was no prior non-append assignment, the default is recursive expansion.

Export has no impact on this.





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

Reply via email to