help-make
[Top][All Lists]
Advanced

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

Re: eval with/without define differs


From: Philip Guenther
Subject: Re: eval with/without define differs
Date: Sun, 8 May 2011 19:38:10 -0700

On Sun, May 8, 2011 at 1:31 PM, Larry Evans <address@hidden> wrote:
> The attached simp.mk make fiil produces output:
> --{--simp.mk out--
> remake -f simp.mk not_echo yes_echo
> NotDef_aaa=aaa
> NotDef_yyy=aaa
> NotDef=zzz
> call_NotDef_template_yyy=NotDef:=yyy
> YesDef_aaa=aaa
> YesDef_yyy=aaa
> YesDef=aaa
> call_YesDef_template_yyy=
> --}--simp.mk out--
>
> when I would have expected the same output for the YesDef portion
> as for the NOtDef portion since the only difference (besides the
> names) is the NotDef_template simply didn't use a define
> to define the value.  My understanding, base upon:
>
>  http://www.gnu.org/software/make/manual/make.html#Multi_002dLine
>
> and:
>
>  http://www.gnu.org/software/make/manual/make.html#Eval-Function
>
> is that they should work the same.
>
> What am I missing?

You missed saying what version of make you were running.

My crystal ball says that you're NOT running the version documented by
the website, yet your makefile uses a syntax that was added in 3.82.
To quote the 3.82 NEWS file:
----
* The 'define' make directive now allows a variable assignment operator
  after the variable name, to allow for simple, conditional, or appending
  multi-line variable assignment.
----

Either stick with the docs on your local system (try "info 'gnu
make'") or keep up with the current version.


Philip Guenther



reply via email to

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