1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283 |
- #! /bin/sh
- . test-init.sh
- cat >> configure.ac << 'END'
- AC_CONFIG_HEADERS([a.h b.h sub/c.h])
- AC_CONFIG_FILES([sub/Makefile])
- AC_OUTPUT
- END
- mkdir sub
- echo SUBDIRS = sub > Makefile.am
- : > sub/Makefile.am
- $ACLOCAL
- $AUTOCONF
- $AUTOHEADER
- test -f a.h.in && test ! -f c.h.in && test ! -f sub/c.h.in \
- || fatal_ "unexpected autoheader behavior with multiple" \
- "AC_CONFIG_HEADERS arguments"
- AUTOMAKE_fails -Wno-error -Wnone
- grep "^configure\.ac:4:.* required file 'b.h.in' not found" stderr
- grep "^configure\.ac:4:.* required file 'sub/c.h.in' not found" stderr
- : > b.h.in
- : > sub/c.h.in
- $AUTOMAKE
- ./configure
- grep '^$(srcdir)/a\.h\.in:' Makefile.in
- grep '[bc]\.h\.in.*:' Makefile.in sub/Makefile.in && exit 1
- test -f a.h && test -f b.h && test -f sub/c.h \
- || fatal_ "unexpected ./configure behavior with multiple" \
- "AC_CONFIG_HEADERS arguments"
- rm -f a.h.in a.h
- $MAKE
- test -f a.h.in
- test -f a.h
- LANG=C LANGUAGE=C LC_ALL=C
- export LANG LANGUAGE LC_ALL
- ocwd=$(pwd)
- for x in b c; do
- test $x = b || cd sub
- rm -f $x.h.in
- run_make -E -e FAIL $x.h.in
- test ! -f $x.h.in
- if using_gmake; then
- grep "No rule to make target [\`\"']$x\.h\.in[\`\"']" stderr
- fi
- : > $x.h.in
- cd "$ocwd" || fatal_ "cannot chdir back"
- done
- :
|