2 # Copyright (C) 2012-2013 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)
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 # Check that user recursion works with various types of indirections
18 # *involved in the definition of the '*-local' targets*: make macros,
19 # AC_SUBST'd strings, automake-time file inclusions, automake
24 cat >> configure.ac
<<'END'
31 AM_EXTRA_RECURSIVE_TARGETS([foo])
32 AC_SUBST([FOO_LOCAL], [foo-local])
33 AM_CONDITIONAL([COND], [:])
37 mkdir sub1 sub
1/subsub sub2 sub
2/subsub
39 cat > Makefile.am
<<'END'
41 AM_FOO_LOCAL = foo-local
51 test -f sub1/subsub/foo
53 test -f sub2/subsub/foo
54 test ! -r sub2/subsub/bar
57 cat > sub
1/Makefile.am
<<'END'
64 cat > sub
1/subsub
/Makefile.am
<<'END'
70 cat > sub
2/Makefile.am
<<'END'
71 include $(srcdir)/bar.am
72 include $(srcdir)/baz.am
76 echo 'SUBDIRS = subsub' > sub
2/bar.am
77 echo 'foo-local: ; pwd && : > foo' > sub
2/baz.am
79 cat > sub
2/subsub
/Makefile.am
<<'END'