]> git.ipfire.org Git - thirdparty/automake.git/commitdiff
* tests/defs (ACLOCAL, AUTOMAKE): Use absolute paths.
authorAlexandre Duret-Lutz <adl@gnu.org>
Mon, 10 Jun 2002 09:39:14 +0000 (09:39 +0000)
committerAlexandre Duret-Lutz <adl@gnu.org>
Mon, 10 Jun 2002 09:39:14 +0000 (09:39 +0000)
* tests/subpkg.test: New file.
* tests/Makefile.am (TESTS): Add subpkg.test.

ChangeLog
tests/Makefile.am
tests/Makefile.in
tests/defs
tests/subpkg.test [new file with mode: 0755]

index ee92a027e22a8cd0e950fb5cbbb80724a7fb7183..5b1b6a07f72d5669b7bf38e0d0f6a89cf31abbbf 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2002-06-10  Alexandre Duret-Lutz  <duret_g@epita.fr>
+
+       * tests/defs (ACLOCAL, AUTOMAKE): Use absolute paths.
+       * tests/subpkg.test: New file.
+       * tests/Makefile.am (TESTS): Add subpkg.test.
+
 2002-06-09  Alexandre Duret-Lutz  <duret_g@epita.fr>
 
        For PR automake/318:
index a80d326d729a48332ea22bfda528ecdcdf1c02ce..e3c883765f7c6e78e35f8c9ead25ebd1f180a085 100644 (file)
@@ -332,6 +332,7 @@ subobj7.test \
 subobj8.test \
 subobj9.test \
 subobjname.test \
+subpkg.test \
 subst.test \
 substref.test \
 substtarg.test \
index 13fc72d963eacd71bfaf41c2c6b336643368edcb..ab2c4ed7912c36e3f2fc2a46f90cea5d82f55d63 100644 (file)
@@ -26,6 +26,7 @@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
 INSTALL = @INSTALL@
 install_sh_DATA = $(install_sh) -c -m 644
 install_sh_PROGRAM = $(install_sh) -c
+install_sh_SCRIPT = $(install_sh) -c
 INSTALL_HEADER = $(INSTALL_DATA)
 NORMAL_INSTALL = :
 PRE_INSTALL = :
@@ -416,6 +417,7 @@ subobj7.test \
 subobj8.test \
 subobj9.test \
 subobjname.test \
+subpkg.test \
 subst.test \
 substref.test \
 substtarg.test \
index 4fb17c766fbce25f30aaa741aadf82ccd6e2d57b..c02a41c2878d8da33e77706aba88ca84e85306e2 100644 (file)
@@ -93,7 +93,7 @@ echo "=== Running test $0"
 if test -z "$AUTOMAKE"; then
    perllibdir=$srcdir/../lib
    export perllibdir
-   AUTOMAKE="$PERL ../../automake --libdir=$srcdir/../lib --foreign --Werror"
+   AUTOMAKE="$PERL `pwd`/../../automake --libdir=$srcdir/../lib --foreign --Werror"
 fi
 
 # See how aclocal should be run.
@@ -103,7 +103,7 @@ if test -z "$ACLOCAL"; then
    # Most of the files are in $srcdir/../m4.  However amversion.m4 is
    # generated in ../m4, so we include that directory in the search
    # path too.
-   ACLOCAL="$PERL ../../aclocal -I `pwd`/../../m4 --acdir=$srcdir/../m4"
+   ACLOCAL="$PERL `pwd`/../../aclocal -I `pwd`/../../m4 --acdir=$srcdir/../m4"
 fi
 
 # We might need extra macros, e.g., from Libtool or Gettext.
diff --git a/tests/subpkg.test b/tests/subpkg.test
new file mode 100755 (executable)
index 0000000..dd3e0e0
--- /dev/null
@@ -0,0 +1,67 @@
+#! /bin/sh
+
+# Check subpackage handling.
+
+. $srcdir/defs || exit 1
+
+set -e
+
+cat >>configure.in <<'END'
+AC_CONFIG_SUBDIRS([lib])
+AC_PROG_CC
+AC_OUTPUT
+END
+
+cat >Makefile.am <<'EOF'
+SUBDIRS = lib
+# Yes, This program is named LDADD.  So what?
+bin_PROGRAMS = LDADD
+LDADD_LDADD = lib/liblib.a
+EOF
+
+cat >LDADD.c <<'EOF'
+int lib ();
+
+int
+main ()
+{
+  return lib ();
+}
+EOF
+
+mkdir lib
+mkdir lib/src
+
+cat >lib/configure.ac <<'EOF'
+AC_INIT([lib], [2.3])
+AM_INIT_AUTOMAKE
+AC_PROG_CC
+AC_PROG_RANLIB
+AC_CONFIG_FILES([Makefile])
+AC_OUTPUT
+EOF
+
+cat >lib/Makefile.am <<'EOF'
+noinst_LIBRARIES = liblib.a
+liblib_a_SOURCES = src/x.c
+EOF
+
+cat >lib/src/x.c <<'EOF'
+int lib ()
+{
+  return 0;
+}
+EOF
+
+$ACLOCAL
+$AUTOCONF
+$AUTOMAKE
+
+cd lib
+$ACLOCAL
+$AUTOCONF
+$AUTOMAKE
+cd ..
+
+./configure
+$MAKE distcheck