[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
export ot sub-make question
From: |
geneSmith |
Subject: |
export ot sub-make question |
Date: |
Mon, 06 Dec 2004 10:58:33 -0500 |
User-agent: |
Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.7.3) Gecko/20040910 |
In the top level Makefile I define and export a recursive variable like
this:
TOPVAR=/path/$(NAM)-map.txt
export TOPVAR
where $(NAM) is not defined in top level Makefile.
Then in the sub-make Makefile I define NAM and use TOPVAR:
NAM=boot
echo "$(TOPVAR)"
and I see TOPVAR is
/path/-map.txt
(not /path/boot-map.txt)
On page 43 of the make manual it states "make exports a variable ... if
its *name* consists only of letters, numbers and underscores" which
TOPVAR does. However it appears that on export, any unexpanded variables
are expanded (NAM to null). This works fine with DOS nmake and NAM is
not expanded until it is actually used in the sub-make.
Comments?
--
Lit up like Levy's
- export ot sub-make question,
geneSmith <=