]> sourceware.org Git - automake.git/commitdiff
* subobj3.test: New file.
authorTom Tromey <tromey@redhat.com>
Thu, 27 May 1999 20:16:47 +0000 (20:16 +0000)
committerTom Tromey <tromey@redhat.com>
Thu, 27 May 1999 20:16:47 +0000 (20:16 +0000)
* Makefile.am (TESTS): Added subobj3.test.
(XFAIL_TESTS): Likewise.

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

index b83a97d53b83949c93aa6b4140f0305524098fa8..63f6284f5a780d50ae1a92057e2c9f2e9e082e9d 100644 (file)
@@ -1,5 +1,9 @@
 1999-05-27  Tom Tromey  <tromey@cygnus.com>
 
+       * subobj3.test: New file.
+       * Makefile.am (TESTS): Added subobj3.test.
+       (XFAIL_TESTS): Likewise.
+
        * ltlibobjs.test: New file.
        * Makefile.am (TESTS): Added ltlibobjs.test.
        (XFAIL_TESTS): Added ltlibobjs.test.
index e2064f41a96d11a26587c7f37ab01a2169c41b62..c719c64ec3cfcce054be1a5b4c7e66c3abe25f41 100644 (file)
@@ -2,7 +2,7 @@
 
 AUTOMAKE_OPTIONS = gnits
 
-XFAIL_TESTS = sourcesub.test ltlibobjs.test
+XFAIL_TESTS = sourcesub.test ltlibobjs.test subobj3.test
 TESTS =        \
 acinclude.test \
 aclocal.test \
@@ -202,6 +202,7 @@ subdir2.test \
 subdir3.test \
 subobj.test \
 subobj2.test \
+subobj3.test \
 subst.test \
 suffix.test \
 symlink.test \
index 1fedc7cdcba5bf5c3fa5cfcada8113a5ccf980d0..07ec69da460598d1156155554da3ccc8cfe8e749 100644 (file)
@@ -67,7 +67,7 @@ VERSION = @VERSION@
 
 AUTOMAKE_OPTIONS = gnits
 
-XFAIL_TESTS = sourcesub.test ltlibobjs.test
+XFAIL_TESTS = sourcesub.test ltlibobjs.test subobj3.test
 TESTS = \
 acinclude.test \
 aclocal.test \
@@ -267,6 +267,7 @@ subdir2.test \
 subdir3.test \
 subobj.test \
 subobj2.test \
+subobj3.test \
 subst.test \
 suffix.test \
 symlink.test \
diff --git a/tests/subobj3.test b/tests/subobj3.test
new file mode 100755 (executable)
index 0000000..5fbf4fd
--- /dev/null
@@ -0,0 +1,46 @@
+#! /bin/sh
+
+# Test of subdir objects with C++.
+
+. $srcdir/defs || exit 1
+
+cat > configure.in << 'END'
+AC_INIT(sub/hello.c)
+AM_INIT_AUTOMAKE(hello,0.23)
+AC_PROG_CC
+AM_PROG_CC_C_O
+AM_C_PROTOTYPES
+AC_OUTPUT(Makefile)
+END
+
+cat > Makefile.am << 'END'
+AUTOMAKE_OPTIONS = subdir-objects
+bin_PROGRAMS = hello
+hello_SOURCES = sub/hello.c
+END
+
+mkdir sub
+cat > sub/hello.c << 'END'
+#include <stdio.h>
+int
+main (int argc, char *argv[])
+{
+   printf ("yeah, yeah\n");
+   return 0;
+}
+END
+
+# Fail gracefully if no autoconf.
+(autoconf --version) > /dev/null 2>&1 || exit 0
+
+# Likewise for gcc.
+(gcc -v) > /dev/null 2>&1 || exit 0
+
+# We use gcc and not gcc -traditional as the latter fails on some
+# Linux boxes (Red Hat 5.1 in particular).
+$ACLOCAL \
+   && autoconf \
+   && $AUTOMAKE -a \
+   && CC='gcc' ./configure \
+   && $MAKE ANSI2KNR=./ansi2knr U=_ \
+   && ./hello
This page took 0.032798 seconds and 5 git commands to generate.