bug-make
[Top][All Lists]
Advanced

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

Re: $(eval) expansion within $(eval)


From: Tony Strauss
Subject: Re: $(eval) expansion within $(eval)
Date: Wed, 16 Apr 2008 16:10:04 -0400



Right.  If you don't want those effects, then don't use inner
$(eval)s!  If you leave out the $(eval)s and just reference $(func2)
and $(func3) inside the definition of func1, those issues don't arise:


define func1
  SOME_VALUE := 1
  MY_FUNC1_VAR := $$(SOME_VALUE)
  all::
        @echo "Here1: $$(MY_FUNC1_VAR)"

  $(func2)
  ifndef SOME_VALUE
     $(func3)
  endif
endef


$ make
Here1: 1
Here2: 1
$

Your suggestion works perfectly, thank you!



reply via email to

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