%% Manoj Srivastava <[EMAIL PROTECTED]> writes:
ms> Even though 'make -d' is quite verbose about dependencies, it is
ms> not verbose enough about called shell programs and stuff.
ms> I'm currently debugging this line:
ms> ROOT_PREFIX = $(shell perl -MCwd -e '$$_ = cwd;s/^.*src\/?//;@f=split
/\//;$$n=$$#f+1;print "../"x $$n;' )
ms> and all 'make -d' displays wrt this issue is:
ms> Makefile:22: *** unterminated call to function `shell': missing `)'. Stop.
The problem is you have a make comment character "#" in that variable
definition, so the last half of the line is chopped off. You'll need to
escape it.
$ cat Makefile
FOO = $(shell echo hi#there)
all: ; @echo '$(FOO)'
$ make
/tmp/6.mk:2: *** unterminated call to function `shell': missing `)'. Stop.
$ cat Makefile
FOO = $(shell echo hi\#there)
all: ; @echo '$(FOO)'
$ make
hi#there
ms> I'd love it would display anything about that expression,
ms> especially since the perl call does NOT contain any ')' anymore.
I'm not clear on what exactly you're asking for here. FYI, make's -p
option will show you the database of variables and rules; maybe that
would help?
$ make -pq | grep FOO
FOO = $(shell echo hi
--
-------------------------------------------------------------------------------
Paul D. Smith <[EMAIL PROTECTED]> Find some GNU make tips at:
http://www.gnu.org http://www.ultranet.com/~pauld/gmake/
"Please remain calm...I may be mad, but I am a professional." --Mad Scientist