bug-make
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [bug #17529] Variable set with $(shell date '+%Y%m%d-%H%M%S') change


From: Martin Dorey
Subject: RE: [bug #17529] Variable set with $(shell date '+%Y%m%d-%H%M%S') changes mid-make
Date: Fri, 25 Aug 2006 18:30:17 -0700

> all variables are expanded exactly once - whether they are immediate
or
> deferred

No.  It might sound like that but that's definitely, definitely,
definitely not what happens.  Deferred variables are expanded again
every time they're used.  I thought perhaps I'd quoted the wrong part of
the documentation because, reading it again, I think you're right that
it isn't clear.  Searching for "deferred" didn't find me any other,
clearer part.  Perhaps a clarification patch would be in order.

Try the := idea.  I bet you can't break it.  Another idea that might be
more convincing:

base = $(shell date --iso=ns 1>&2)

That sends the output of date(1) to stderr, where you'll see it
directly, once for each time it's invoked.
-------------------------------------
Martin's Outlook, BlueArc Engineering




reply via email to

[Prev in Thread] Current Thread [Next in Thread]