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?
-regards,
Larry
NotDef:=aaa
NotDef_aaa:=$(NotDef)
NotDef_template = NotDef:=$(1)
call_NotDef_template_yyy := $(call NotDef_template,yyy)
NotDef_yyy:=$(NotDef)
$(eval $(call NotDef_template,zzz))
not_echo:
@echo NotDef_aaa=$(NotDef_aaa)
@echo NotDef_yyy=$(NotDef_yyy)
@echo NotDef=$(NotDef)
@echo call_NotDef_template_yyy=$(call_NotDef_template_yyy)
YesDef:=aaa
YesDef_aaa:=$(YesDef)
define YesDef_template =
YesDef:=$(1)
endef
call_YesDef_template_yyy := $(call YesDef_template,yyy)
YesDef_yyy:=$(YesDef)
$(eval $(call YesDef_template,zzz))
yes_echo:
@echo YesDef_aaa=$(YesDef_aaa)
@echo YesDef_yyy=$(YesDef_yyy)
@echo YesDef=$(YesDef)
@echo call_YesDef_template_yyy=$(call_YesDef_template_yyy)
_______________________________________________
Help-make mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/help-make