2001-07-21 Tom Tromey <tromey@redhat.com>
+ * tests/Makefile.am (TESTS): Added substtart.test.
+ (XFAIL_TESTS): Likewise.
+ * tests/substtarg.test: New file.
+
* automake.in (handle_dist): Handle case where aux dir doesn't
have a Makefile. Fixes depdist.test.
* tests/Makefile.am (XFAIL_TESTS): Removed depdist.test.
## Process this file with automake to create Makefile.in
-XFAIL_TESTS = subdir5.test
+XFAIL_TESTS = subdir5.test substtarg.test
TESTS = \
acinclude.test \
subobj7.test \
subobj8.test \
subst.test \
+substtarg.test \
suffix.test \
suffix2.test \
suffix3.test \
_am_quote = @_am_quote@
install_sh = @install_sh@
-XFAIL_TESTS = subdir5.test
+XFAIL_TESTS = subdir5.test substtarg.test
TESTS = \
acinclude.test \
subobj7.test \
subobj8.test \
subst.test \
+substtarg.test \
suffix.test \
suffix2.test \
suffix3.test \
--- /dev/null
+#! /bin/sh
+
+# Test that substitutions in variables work.
+# From Lars J. Aas.
+
+. $srcdir/defs || exit 1
+
+cat > configure.in << 'END'
+AC_INIT(fakelib.c)
+AM_INIT_AUTOMAKE(fakelib,0.0)
+AC_PROG_CC
+RANLIB=:
+AC_SUBST(RANLIB)
+SUBST=hei
+AC_SUBST(SUBST)
+AC_OUTPUT(Makefile)
+END
+
+cat > Makefile.am << 'END'
+noinst_LIBRARIES = libfake@SUBST@.a
+
+libfake@SUBST@_a_SOURCES = abra.c kadabra.c
+
+# then we override the target rule:
+libfake@SUBST@.a: Makefile $(libfake@SUBST@_a_OBJECTS) $(libfake@SUBST@_a_DEPENDENCIES)
+ @echo here we do some custom stuff, instead of invoking the linker
+END
+
+set -e
+
+$ACLOCAL
+$AUTOMAKE
+num=`grep '^libfake@SUBST@.a:' Makefile.in | wc -l`
+test $num -eq 1