From f79ed3e7b3fac1b6142e3c283f8d7bce4e4b6f34 Mon Sep 17 00:00:00 2001 From: Alexandre Duret-Lutz Date: Sat, 17 May 2003 11:31:57 +0000 Subject: [PATCH] * lib/am/install.am (install, install-exec, install-data, uninstall): Declare conditionally using a if/else/endif block instead of using ?SUBDIRS?-style conditions. The latter fail when %maybe_BUILT_SOURCES% is replaced by several lines. This fixes a bug introduced on 2003-04-06. * tests/bsource.test: New file. * tests/Makefile.am (TESTS): Add bsource.test. Reported by Bruno Haible. --- ChangeLog | 11 +++++++++++ lib/Automake/tests/Makefile.in | 1 - lib/am/Makefile.in | 1 - lib/am/install.am | 24 +++++++++++++----------- m4/Makefile.in | 1 - stamp-vti | 2 +- tests/Makefile.am | 1 + tests/Makefile.in | 2 +- tests/bsource.test | 37 +++++++++++++++++++++++++++++++++++++ version.texi | 2 +- 10 files changed, 65 insertions(+), 17 deletions(-) create mode 100755 tests/bsource.test diff --git a/ChangeLog b/ChangeLog index 9b1a176..5a26b93 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,14 @@ +2003-05-17 Alexandre Duret-Lutz + + * lib/am/install.am (install, install-exec, install-data, uninstall): + Declare conditionally using a if/else/endif block instead of + using ?SUBDIRS?-style conditions. The latter fail when + %maybe_BUILT_SOURCES% is replaced by several lines. + This fixes a bug introduced on 2003-04-06. + * tests/bsource.test: New file. + * tests/Makefile.am (TESTS): Add bsource.test. + Reported by Bruno Haible. + 2003-05-11 Alexandre Duret-Lutz * automake.texi (renamed objects): New node. diff --git a/lib/Automake/tests/Makefile.in b/lib/Automake/tests/Makefile.in index 1a19815..0fcfa07 100644 --- a/lib/Automake/tests/Makefile.in +++ b/lib/Automake/tests/Makefile.in @@ -265,7 +265,6 @@ check: check-am all-am: Makefile installdirs: - install: install-am install-exec: install-exec-am install-data: install-data-am diff --git a/lib/am/Makefile.in b/lib/am/Makefile.in index 5fa673e..dec4947 100644 --- a/lib/am/Makefile.in +++ b/lib/am/Makefile.in @@ -216,7 +216,6 @@ all-am: Makefile $(DATA) installdirs: $(mkinstalldirs) $(DESTDIR)$(amdir) - install: install-am install-exec: install-exec-am install-data: install-data-am diff --git a/lib/am/install.am b/lib/am/install.am index 7216af3..e178c2a 100644 --- a/lib/am/install.am +++ b/lib/am/install.am @@ -34,18 +34,20 @@ ## ----------------- ## .PHONY: install install-exec install-data uninstall - -?SUBDIRS?.PHONY: install-recursive install-exec-recursive install-data-recursive uninstall-recursive -?SUBDIRS?install:%maybe_BUILT_SOURCES% install-recursive -?SUBDIRS?install-exec: install-exec-recursive -?SUBDIRS?install-data: install-data-recursive -?SUBDIRS?uninstall: uninstall-recursive - .PHONY: install-exec-am install-data-am uninstall-am -?!SUBDIRS?install:%maybe_BUILT_SOURCES% install-am -?!SUBDIRS?install-exec: install-exec-am -?!SUBDIRS?install-data: install-data-am -?!SUBDIRS?uninstall: uninstall-am + +if %?SUBDIRS% +.PHONY: install-recursive install-exec-recursive install-data-recursive uninstall-recursive +install:%maybe_BUILT_SOURCES% install-recursive +install-exec: install-exec-recursive +install-data: install-data-recursive +uninstall: uninstall-recursive +else !%?SUBDIRS% +install:%maybe_BUILT_SOURCES% install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am +endif !%?SUBDIRS% .PHONY: install-am install-am: all-am diff --git a/m4/Makefile.in b/m4/Makefile.in index 9d9e0b9..49459c6 100644 --- a/m4/Makefile.in +++ b/m4/Makefile.in @@ -264,7 +264,6 @@ all-am: Makefile $(DATA) installdirs: $(mkinstalldirs) $(DESTDIR)$(m4datadir) $(DESTDIR)$(m4datadir) - install: install-am install-exec: install-exec-am install-data: install-data-am diff --git a/stamp-vti b/stamp-vti index 193293f..b1db8c4 100644 --- a/stamp-vti +++ b/stamp-vti @@ -1,4 +1,4 @@ -@set UPDATED 11 May 2003 +@set UPDATED 17 May 2003 @set UPDATED-MONTH May 2003 @set EDITION 1.7a @set VERSION 1.7a diff --git a/tests/Makefile.am b/tests/Makefile.am index 74ed8d9..4ce2e5c 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -45,6 +45,7 @@ backsl4.test \ badline.test \ badprog.test \ block.test \ +bsource.test \ canon.test \ canon2.test \ canon3.test \ diff --git a/tests/Makefile.in b/tests/Makefile.in index 5600352..934fbb0 100644 --- a/tests/Makefile.in +++ b/tests/Makefile.in @@ -156,6 +156,7 @@ backsl4.test \ badline.test \ badprog.test \ block.test \ +bsource.test \ canon.test \ canon2.test \ canon3.test \ @@ -733,7 +734,6 @@ check: check-am all-am: Makefile installdirs: - install: install-am install-exec: install-exec-am install-data: install-data-am diff --git a/tests/bsource.test b/tests/bsource.test new file mode 100755 index 0000000..282ea57 --- /dev/null +++ b/tests/bsource.test @@ -0,0 +1,37 @@ +#! /bin/sh +# Copyright (C) 2003 Free Software Foundation, Inc. +# +# This file is part of GNU Automake. +# +# GNU Automake is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2, or (at your option) +# any later version. +# +# GNU Automake is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with Automake; see the file COPYING. If not, write to +# the Free Software Foundation, Inc., 59 Temple Place - Suite 330, +# Boston, MA 02111-1307, USA. + +# Regression test for install-recursive appearing in a non recursive Makefile. +# Report from Bruno Haible. + +. ./defs || exit 1 + +set -e + +cat > Makefile.am << 'END' +noinst_SCRIPTS = hostname +include_HEADERS = gettext-po.h +BUILT_SOURCES = po-hash-gen.c +END + +$ACLOCAL +$AUTOMAKE +grep 'install-recursive' Makefile.in && exit 1 +: diff --git a/version.texi b/version.texi index 193293f..b1db8c4 100644 --- a/version.texi +++ b/version.texi @@ -1,4 +1,4 @@ -@set UPDATED 11 May 2003 +@set UPDATED 17 May 2003 @set UPDATED-MONTH May 2003 @set EDITION 1.7a @set VERSION 1.7a -- 2.7.4