[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
eval and if-blocks incompatible on i386-pc-linux-gnu
From: |
Arthur Carlson |
Subject: |
eval and if-blocks incompatible on i386-pc-linux-gnu |
Date: |
Wed, 23 Apr 2008 17:11:45 +0200 |
User-agent: |
Debian Thunderbird 1.0.2 (X11/20060423) |
I am doing grid computing on two hosts, gavosrv1.mpe.mpg.de and
siemens.babylon.cs.uni-potsdam.de. On both gavosrv1 and
siemens.babylon.cs.uni-potsdam.de, GNU Make 3.80 is installed, but the
behavior is different. Take the following makefile:
ifeq (true,true)
a:
@echo a
b:
@echo b
ifdef SWITCH
$(eval a : b)
endif
endif
On gavosrv1:
-bash-3.00$ make a
a
-bash-3.00$ make SWITCH=on a
b
a
On siemens.babylon.cs.uni-potsdam.de:
address@hidden:~/grid-modules/cf$ make a
a
address@hidden:~/grid-modules/cf$ make SWITCH=on a
makefile:10: *** missing `endif'. Stop.
That is, on siemens but not on gavosrv1, calling the eval function
interferes with the conditional construct.
The behavior is the same if the statements are physically changed in the
makefile, rather than using the SWITCH on the command line. If you want
to be minimalist, you can also see the same problem in this makefile:
ifdef SWITCH
$(eval a : b)
endif
Running make --help, I noticed that gavosrv1 said "This program built
for i686-redhat-linux-gnu", while siemens said "This program built for
i386-pc-linux-gnu". I can't imagine where else this behavior could be
coming from.
Have fun with it!
Art Carlson
--
Dr. Arthur Carlson
Max-Planck-Institut fuer extraterrestrische Physik
Giessenbachstrasse, 85748 Garching, Germany
Phone: (+49 89) 30000-3357
E-Mail: address@hidden
- eval and if-blocks incompatible on i386-pc-linux-gnu,
Arthur Carlson <=