%% "Robert P. J. Day" <[EMAIL PROTECTED]> writes:
rpjd> objects = *.o
rpjd> objects := $(wildcard *.o)
vs.
rpjd> objects = $(wildcard *.o)
rpjd> objects := *.o
rpjd> the first again, i would guess, is a deferred assignment, with
rpjd> the actual value of '$(wildcard *.o)' which will be evaluated
rpjd> when used. how can i print the actual value of a variable
rpjd> without having it evaluated?
If you have GNU make 3.80 you can use the $(value ...) function. If you
don't, you can't do it.
Note this is only relevant for the $(wildcard) line. The *.o doesn't
contain any variable or function values, so it always returns *.o.
rpjd> and that last statement is an immediate assignment, right? so
rpjd> that the wildcard expansion is done before assignment, as long
rpjd> as something matches that pattern.
GNU make doesn't do wildcarding when expanding a variable that contains
a "*". The result of evaluating that value is always the literal string
'*.o'.
The wildcarding may be done by the user of that string, but it isn't
handled during the expansion of the variable.
--
-------------------------------------------------------------------------------
Paul D. Smith <[EMAIL PROTECTED]> Find some GNU make tips at:
http://www.gnu.org http://make.paulandlesley.org
"Please remain calm...I may be mad, but I am a professional." --Mad Scientist
_______________________________________________
Help-make mailing list
[EMAIL PROTECTED]
http://lists.gnu.org/mailman/listinfo/help-make