Re: CFLAGS usage
- From
David Brown <git@davidb.org>
- Date
- Nov 4, 2005, 16:59 UTC
- Message-ID
- <20051104165903.GA13125@old.davidb.org>
- In-Reply-To
- <118833cc0511040721w7f3990fbw631feaa6a4bda936@mail.gmail.com>
On Fri, Nov 04, 2005 at 10:21:55AM -0500, Morten Welinder wrote:
> Various stuff is being added to CFLAGS, but CFLAGS is not being used > after being composed in CFLAGS_ALL.
> CFLAGS = -g -O2 -Wall > ALL_CFLAGS = $(CFLAGS) $(PLATFORM_DEFINES) $(DEFINES) > CFLAGS += -I$(CURLDIR)/include
Make expands variable lazily, so the ALL_CFLAGS expansion only happens at the point of use, where all of the CFLAGS definitions have been made.
Dave