[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: Question Regarding Emile van Bergen's Non-Recursive Make
From: |
Davidson, Josh |
Subject: |
RE: Question Regarding Emile van Bergen's Non-Recursive Make |
Date: |
Mon, 01 Dec 2008 14:29:12 -0700 |
Ok, I'm close to getting this working. I'm trying to find an
alternative to doing:
dir := moduleA
include $(dir)/Rules.mk
dir := moduleB
include $(dir)/Rules.mk
dir := moduleC
include $(dir)/Rules.mk
#etc
Normally, I would do something like
MODULES = moduleA moduleB moduleC #etc
include $(addsuffix /Rules.mk, $(MODULES))
However, I need to set dir before adding the include. Is there a trick
to doing that?
Josh
-----Original Message-----
From: Paul Smith [mailto:address@hidden
Sent: Monday, December 01, 2008 6:41 AM
To: Davidson, Josh
Cc: Mike Shal; address@hidden
Subject: RE: Question Regarding Emile van Bergen's Non-Recursive Make
On Sun, 2008-11-30 at 17:51 -0700, Davidson, Josh wrote:
> Is it valid to treat VPATH like a simply expanded variable? I changed
> my makefiles to add to it like:
>
> VPATH := $(VPATH) SRCIDR_$(d) TESTDIR_$(d)
Yes, this is perfectly legitimate. VPATH is just a variable like any
other variable. The only difference is how/where make uses its value.
--
------------------------------------------------------------------------
-------
Paul D. Smith <address@hidden> Find some GNU make tips at:
http://www.gnu.org http://make.mad-scientist.us
"Please remain calm...I may be mad, but I am a professional." --Mad
Scientist