maint: Update HACKING
[automake.git] / t / missing-auxfile-stops-makefiles-creation.sh
blob6d794a3a8b7f5c39591c527bf1f1133364d0aa40
1 #! /bin/sh
2 # Copyright (C) 2011-2017 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 <https://www.gnu.org/licenses/>.
17 # Automake should stop the creation of Makefile.in files at the first
18 # encountered error due to a required auxiliary file not found.
20 . test-init.sh
22 cat >> configure.ac <<END
23 AM_PATH_PYTHON
24 END
26 echo SUBDIRS = > Makefile.am
28 for i in 1 2 3 4 5; do
29 echo "AC_CONFIG_FILES([sub$i/Makefile])" >> configure.ac
30 echo "SUBDIRS += sub$i" >> Makefile.am
31 mkdir sub$i
32 echo python_PYTHON = foo.py > sub$i/Makefile.am
33 done
35 : > sub1/Makefile.am
37 $ACLOCAL
39 unset AUTOMAKE_JOBS
41 AUTOMAKE_fails
42 ls -l Makefile.in */Makefile.in || : # For debugging.
43 # Top-level Makefile.in might be created or not, we don't want to set
44 # too strict semantics here, so don't check for it. But the later
45 # files shouldn't exist.
46 test -f sub1/Makefile.in
47 test ! -e sub2/Makefile.in
48 test ! -e sub3/Makefile.in
49 test ! -e sub4/Makefile.in
50 test ! -e sub5/Makefile.in
52 rm -f Makefile.in */Makefile.in
54 : > sub2/Makefile.am
55 : > sub3/Makefile.am
57 AUTOMAKE_fails
58 ls -l Makefile.in */Makefile.in || : # For debugging.
59 test -f sub1/Makefile.in
60 test -f sub2/Makefile.in
61 test -f sub3/Makefile.in
62 test ! -e sub4/Makefile.in
63 test ! -e sub5/Makefile.in