[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: where is wrong about eval-ing the results of the function call?
From: |
Pan ruochen |
Subject: |
Re: where is wrong about eval-ing the results of the function call? |
Date: |
Fri, 17 Oct 2008 13:43:19 +0800 |
> Regardless, please upgrade to version 3.81, which was released over
> 2.5 *years* ago, and try your makefile again.
>
>
> Philip Guenther
>
I just found I can eliminate the errors by simply moving $(eval ...)
out of ifdef ... endif, for GNU Make version 3.80
-------------------------------------------------------------------------------------------------------------
my_src_dir := dir_a dir_b
define dir-to-vpath
#X
vpath %c $1
vpath %S $1
#Z
endef
ifdef my_src_dir
cmd = $(foreach dir,$(my_src_dir),$(call dir-to-vpath,$(dir)))
$(warning $(cmd))
endif
$(eval $(cmd))
all: 1.c 2.c 3.S
-------------------------------------------------------------------------------------------------------------
Maybe it is a bug for version 3.80 and has been corrected on 3.81 and
later versions
PRC