From: Daiki Ueno Date: Mon, 12 Mar 2012 10:46:04 +0000 (+0100) Subject: coverage: expose automake bug#10997 X-Git-Tag: v1.11.3b~7^2~7 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b153660787dd7dea409ad969c29393c105e13bf2;p=thirdparty%2Fautomake.git coverage: expose automake bug#10997 * tests/instdir-cond.test: New test. * tests/list-of-tests.mk: Add it. * tests/Makefile.am (XFAIL_TESTS): Likewise. Copyright-paperwork-exempt: yes Signed-off-by: Stefano Lattarini --- diff --git a/tests/Makefile.am b/tests/Makefile.am index b8ede3086..9cac904a1 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -25,6 +25,7 @@ dist-auxfile.test \ dist-auxfile-2.test \ dist-pr109765.test \ gcj6.test \ +instdir-cond.test \ java-nobase.test \ objext-pr10128.test \ pr8365-remake-timing.test \ diff --git a/tests/instdir-cond.test b/tests/instdir-cond.test new file mode 100644 index 000000000..8d83f8826 --- /dev/null +++ b/tests/instdir-cond.test @@ -0,0 +1,49 @@ +#! /bin/sh +# Copyright (C) 2012 Free Software Foundation, Inc. +# +# This program 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. +# +# This program 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 this program. If not, see . + +# Check against automake bug#10997: directories holding only +# conditionally-installed files should not be created unconditionally. + +. ./defs || Exit 1 + +set -e + +cat >> configure.in << 'END' +AM_CONDITIONAL([ENABLE_FOO], [false]) +AC_OUTPUT +END + +: > foo +: > bar + +cat > Makefile.am << 'END' +if ENABLE_FOO +pkgdata_DATA = foo +pkglibexec_SCRIPTS = bar +endif +END + +$ACLOCAL +$AUTOMAKE +$AUTOCONF + +./configure --prefix="`pwd`/inst" + +$MAKE install +test ! -d inst/share/instdir-cond +test ! -d inst/libexec/instdir-cond + +: diff --git a/tests/list-of-tests.mk b/tests/list-of-tests.mk index 023bf3bc6..7fd037673 100644 --- a/tests/list-of-tests.mk +++ b/tests/list-of-tests.mk @@ -459,6 +459,7 @@ instdat.test \ instdat2.test \ instdir.test \ instdir2.test \ +instdir-cond.test \ instdir-java.test \ instdir-lisp.test \ instdir-ltlib.test \