diff options
author | Stefano Lattarini <stefano.lattarini@gmail.com> | 2014-12-23 11:36:20 +0100 |
---|---|---|
committer | Stefano Lattarini <stefano.lattarini@gmail.com> | 2014-12-23 17:58:31 +0100 |
commit | 2629aa9e713c584c799677987ffb03156b8aae8e (patch) | |
tree | b291b3435cc1c45d022e4f8f6ab32e1387bc4e13 /t/distcheck-pr18286.sh | |
parent | 55270ac3222bb00e60505ec7c2d63f0047152bfa (diff) | |
download | automake-2629aa9e713c584c799677987ffb03156b8aae8e.tar.gz |
tests: expose automake bug#18286 "distcheck fails to detect missing files"
* t/distcheck-pr18286.sh: New test, still XFAILing.
* t/list-of-tests.mk: Add it.
Signed-off-by: Stefano Lattarini <stefano.lattarini@gmail.com>
Diffstat (limited to 't/distcheck-pr18286.sh')
-rw-r--r-- | t/distcheck-pr18286.sh | 62 |
1 files changed, 62 insertions, 0 deletions
diff --git a/t/distcheck-pr18286.sh b/t/distcheck-pr18286.sh new file mode 100644 index 000000000..b10773579 --- /dev/null +++ b/t/distcheck-pr18286.sh @@ -0,0 +1,62 @@ +#! /bin/sh +# Copyright (C) 2014 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 <http://www.gnu.org/licenses/>. + +# Ensure "make distcheck" detects all missing files, without getting +# confused by the fact that they exists in the "original" source tree +# from which "make distcheck" is run. See automake bug#18286. + +. test-init.sh + +echo AC_OUTPUT >> configure.ac + +cat > Makefile.am <<'END' +$(srcdir)/test_data.am: $(srcdir)/test_data.txt $(srcdir)/gen-testdata.sh + cd $(srcdir) && $(SHELL) gen-testdata.sh <test_data.txt >test_data.am + +include $(srcdir)/test_data.am + +check-local: + is $(testdata) == foo bar +END + +cat > test_data.txt <<'END' +foo +bar +END + + +cat > gen-testdata.sh <<'END' +#!/bin/sh +printf 'testdata = \\\n' +sed 's/$/ \\/' +echo '$(empty_string)' +END +chmod a+x gen-testdata.sh + +$sleep +./gen-testdata.sh <test_data.txt >test_data.am + +$ACLOCAL +$AUTOCONF +$AUTOMAKE -a + +./configure + +$MAKE check + +run_make -e FAIL -M distcheck + +: |