> When do you append it?  To what value?  In other words, given the
> following makefile:
> 
>     $(warning FOO = $(FOO))
> 
>     FOO := bar
> 
>     $(warning FOO = $(FOO))
> 
>     FOO += biz
> 
>     $(warning FOO = $(FOO))
> 
>     all: FOO := boz
>     all: FOO += baz
>     all: ; @echo FOO = $(FOO) / '$$FOO' = $$FOO
> 
> What does make print out when you run:
> 
>     make FOO+=foo

First, I need to undertstand what happens when I do this:

$ make
makefile:2: FOO = foo
makefile:5: FOO = foo bar
makefile:9: FOO = foo bar biz
FOO = boz baz / $FOO =

$ setenv FOO gig
$ make
makefile:2: FOO = gig foo
makefile:5: FOO = gig foo bar
makefile:9: FOO = gig foo bar biz
FOO = boz baz / $FOO = boz baz

Why in the second case "/ $FOO" prints "boz baz" and not the empty string? 
When I do "make -e":

$ make -e
makefile:2: FOO = gig
makefile:5: FOO = gig
makefile:9: FOO = gig
FOO = gig / $FOO = gig

Thanks,
Martin



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

Reply via email to