[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: I: adjust test suite for upcoming GNU Make 3.83
From: |
Alexandre Duret-Lutz |
Subject: |
Re: I: adjust test suite for upcoming GNU Make 3.83 |
Date: |
Wed, 16 Mar 2005 23:51:40 +0100 |
User-agent: |
Gnus/5.110003 (No Gnus v0.3) Emacs/21.3.50 (gnu/linux) |
>>> "pds" == Paul D Smith <address@hidden> writes:
[...]
pds> I'm interested in discussing the issue and possible solutions. The one
pds> I added to the bug report involves using :=, since simply-expanded
pds> variables in GNU make are always only expanded one time, no matter how
pds> many times they're referenced (unless within an eval function). But,
pds> obviously, using := does not yield a portable makefile.
Actually it does not appear to work here.
I compiled CVS make, and patched Automake as follows.
--- tests/dollar.test 14 Nov 2003 21:25:58 -0000 1.7
+++ tests/dollar.test 16 Mar 2005 22:32:49 -0000
@@ -33,7 +33,7 @@
cat > Makefile.am <<'EOF'
mydir = $(prefix)/my
-dist_my_DATA = hello$$world
+dist_my_DATA := hello$$world
check-dist: distdir
test -f '$(distdir)/hello$$world'
@@ -43,7 +43,7 @@
$ACLOCAL
$AUTOCONF
-$AUTOMAKE
+$AUTOMAKE -Wno-portability
./configure --prefix `pwd`/inst
$MAKE install
test -f 'inst/my/hello$world'
This test still fails with
| ~/projs/cvs/automake/HEAD3/tests % ./dollar.test
|
/home/adl/projs/cvs/automake/HEAD3/tests:/home/adl/usr/bin:/usr/local/bin:/usr/bin:/bin:/usr/bin/X11:/usr/games
| dollar: running make --version -v | grep GNU
| GNU Make 3.81beta3
| === Running test ./dollar.test
| ++ pwd
| /home/adl/projs/cvs/automake/HEAD3/tests/testSubDir
| + set -e
| + echo AC_OUTPUT
| + cat
| + :
| + aclocal-1.9a -Werror
| + autoconf
| + automake-1.9a --foreign -Werror -Wall -Wno-portability
| ++ pwd
| + ./configure --prefix
/home/adl/projs/cvs/automake/HEAD3/tests/testSubDir/inst
| checking for a BSD-compatible install... /usr/bin/install -c
| checking whether build environment is sane... yes
| checking for gawk... gawk
| checking whether make sets $(MAKE)... yes
| configure: creating ./config.status
| config.status: creating Makefile
| + make install
| make: *** No rule to make target `helloorld', needed by `all-am'. Stop.
the generated Makefile contains
| dist_my_DATA := hello$$world
|
| DATA = $(dist_my_DATA)
|
| all-am: Makefile $(DATA)
|
| install-dist_myDATA: $(dist_my_DATA)
| @$(NORMAL_INSTALL)
| test -z "$(mydir)" || $(mkdir_p) "$(DESTDIR)$(mydir)"
| @list='$(dist_my_DATA)'; for p in $$list; do \
| if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
| f=$(am__strip_dir) \
| echo " $(dist_myDATA_INSTALL) '$$d$$p' '$(DESTDIR)$(mydir)/$$f'"; \
| $(dist_myDATA_INSTALL) "$$d$$p" "$(DESTDIR)$(mydir)/$$f"; \
| done
this seems to imply that simply-expanded variables are
re-expanded when they appear inside deferred variables.
If I manually change `DATA = $(dist_my_DATA)' (this is not a
real solution, because this line is generated by Automake) to
`DATA := $(dist_my_DATA)', then the all-am rule passes, but the
test fails later with
make[1]: *** No rule to make target `helloorld', needed by
`install-dist_myDATA'. Stop.
--
Alexandre Duret-Lutz