tests: make 'lzip.test' executable
[automake.git] / tests / dist-auxfile-2.test
blob08daa6caa301bb4b5139a44f7c88acf3bd2c90df
1 #! /bin/sh
2 # Copyright (C) 2011 Free Software Foundation, Inc.
4 # This program is free software; you can redistribute it and/or modify
5 # it under the terms of the GNU General Public License as published by
6 # the Free Software Foundation; either version 2, or (at your option)
7 # any later version.
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 # GNU General Public License for more details.
14 # You should have received a copy of the GNU General Public License
15 # along with this program. If not, see <http://www.gnu.org/licenses/>.
17 # Files specified by AC_REQUIRE_AUX_FILE must exist, and if a Makefile
18 # is present in the build-aux directory, they correctly get automatically
19 # distributed.
20 # Related to automake bug#9651.
22 am_create_testdir=empty
23 . ./defs || Exit 1
25 set -e
27 cat > configure.in <<END
28 AC_INIT([$me], [1.0])
29 AC_CONFIG_AUX_DIR([sub])
30 AM_INIT_AUTOMAKE
31 AC_REQUIRE_AUX_FILE([zardoz])
32 AC_CONFIG_FILES([Makefile sub/Makefile])
33 AC_OUTPUT
34 END
36 cat > Makefile.am <<'END'
37 SUBDIRS = sub
38 test: distdir
39 ls -l $(distdir) $(distdir)/* ;: For debugging.
40 test -f $(distdir)/sub/zardoz
41 .PHONY: test
42 check-local: test
43 END
45 mkdir sub
46 : > sub/Makefile.am
48 echo dummy > sub/zardoz
50 $ACLOCAL
51 $AUTOCONF
52 $AUTOMAKE -a
53 test -f sub/install-sh
54 # Should work also without `--add-missing'.
55 $AUTOMAKE
57 ./configure
59 $MAKE test
60 $MAKE distcheck