From 6f8f38cfbe6ec39e3677e0276235b9c7a2ac5fbf Mon Sep 17 00:00:00 2001 From: Stefano Lattarini Date: Tue, 3 May 2011 17:51:42 +0200 Subject: [PATCH] tests: drop useless requirements of gcc (plus testsuite tweakings) * tests/libobj14.test ($required): Remove 'gcc', as we never run the C compiler. * tests/targetclash.test: Likewise. * tests/ansi6.test ($required): Remove 'gcc', as any working C compiler should be enough. * tests/ansi7.test: Likewise. * tests/ansi9.test: Likewise. * tests/ansi10.test: Likewise. * tests/lex5.test: Likewise. * tests/lexvpath.test: Likewise. * tests/mmodely.test: Likewise. * tests/pr204.test: Likewise. * tests/pr300-lib.test: Likewise. * tests/pr300-prog.test: Likewise. * tests/primary3.test: Likewise. * tests/specflg7.test: Likewise. * tests/specflg8.test: Likewise. * tests/subdir5.test: Likewise. * tests/subdir8.test: Likewise. * tests/subobj6.test: Likewise. * tests/subst3.test: Likewise. * tests/substre2.test: Likewise. * tests/yacc6.test: Likewise. * tests/yacc8.test: Likewise. * tests/depcomp2.test: Likewise. Also, avoid clobbering user-set CFLAGS. * tests/lex3.test: Likewise. * tests/ansi3.test: Likewise. Also, avoid 'CC=gcc' in configure. * tests/ansi3b.test: Likewise. * tests/ansi5.test: Likewise. * tests/autohdr4.test ($required): Remove 'gcc', as any working C compiler should be enough. Also, do not reject slow dependency extractors (which we might be forced to use now that $CC is not necessarily gcc anymore). * tests/cond16.test ($required): Remove 'gcc', as any working C compiler should be enough. Since we are at it, throw in few minor tweakings (mostly cosmetic, stylistic, or consistency-related). * tests/cond18.test: Likewise. * tests/cond35.test: Likewise. * tests/gnits2.test: Likewise. * tests/libtool3.test: Likewise. * tests/libtool7.test: Likewise. * tests/libtool9.test: Likewise. * tests/ltcond.test: Likewise. * tests/ltcond2.test: Likewise. * tests/ltconv.test: Likewise. * tests/ltlibsrc.test: Likewise. * tests/nobase.test: Likewise. * tests/nobase-libtool.test: Likewise. * tests/pr220.test: Likewise. * tests/pr224.test: Likewise. * tests/pr300-ltlib.test: Likewise. * tests/pr401.test: Likewise. * tests/pr401b.test: Likewise. * tests/pr401c.test: Likewise. * tests/subpkg.test: Likewise. * tests/target-cflags.test: Likewise. * tests/transform.test: Likewise. * tests/yacc4.test: Likewise. * tests/cond19.test: Likewise. Also, avoid clobbering user-set CFLAGS. * tests/cond4.test: Likewise. * tests/depend2.test: Likewise. * tests/pr87.test: Likewise. * tests/subobj3.test: Likewise. * tests/substref.test: Likewise. --- ChangeLog | 71 +++++++++++++++++++++++++++++++++++++++++++++++ tests/ansi10.test | 1 - tests/ansi3.test | 12 ++------ tests/ansi3b.test | 9 +----- tests/ansi5.test | 6 +--- tests/ansi6.test | 1 - tests/ansi7.test | 1 - tests/ansi9.test | 1 - tests/autohdr4.test | 9 +++--- tests/cond16.test | 22 ++++++--------- tests/cond18.test | 19 +++++-------- tests/cond19.test | 30 ++++++++------------ tests/cond35.test | 10 ++++--- tests/cond4.test | 6 +--- tests/depcomp2.test | 4 --- tests/depend2.test | 11 ++------ tests/gnits2.test | 13 +++++---- tests/gnits3.test | 10 +++++-- tests/lex3.test | 6 +--- tests/lex5.test | 2 +- tests/lexvpath.test | 2 +- tests/libobj14.test | 1 - tests/libtool3.test | 6 ++-- tests/libtool7.test | 14 +++++----- tests/libtool9.test | 16 +++++------ tests/ltcond.test | 4 ++- tests/ltcond2.test | 37 ++++++++++++++++++------ tests/ltconv.test | 14 ++++++---- tests/ltlibsrc.test | 17 ++++++++---- tests/mmodely.test | 1 - tests/nobase-libtool.test | 6 +++- tests/nobase.test | 5 +++- tests/pr204.test | 2 +- tests/pr220.test | 14 ++++++---- tests/pr224.test | 6 ++-- tests/pr300-lib.test | 1 - tests/pr300-ltlib.test | 10 +++---- tests/pr300-prog.test | 1 - tests/pr401.test | 9 ++---- tests/pr401b.test | 17 +++++------- tests/pr401c.test | 15 ++++------ tests/pr87.test | 20 ++++++------- tests/primary3.test | 1 - tests/specflg7.test | 3 +- tests/specflg8.test | 3 +- tests/subdir5.test | 2 +- tests/subdir8.test | 2 +- tests/subobj3.test | 9 +----- tests/subobj6.test | 1 - tests/subpkg.test | 11 ++++---- tests/subst3.test | 3 +- tests/substre2.test | 1 - tests/substref.test | 11 -------- tests/target-cflags.test | 4 +-- tests/targetclash.test | 1 - tests/transform.test | 7 +++-- tests/yacc4.test | 9 ++++-- tests/yacc8.test | 2 +- 58 files changed, 284 insertions(+), 248 deletions(-) diff --git a/ChangeLog b/ChangeLog index 248ee13..6193e98 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,76 @@ 2011-05-03 Stefano Lattarini + tests: drop useless requirements of gcc (plus testsuite tweakings) + * tests/libobj14.test ($required): Remove 'gcc', as we never run + the C compiler. + * tests/targetclash.test: Likewise. + * tests/ansi6.test ($required): Remove 'gcc', as any working + C compiler should be enough. + * tests/ansi7.test: Likewise. + * tests/ansi9.test: Likewise. + * tests/ansi10.test: Likewise. + * tests/lex5.test: Likewise. + * tests/lexvpath.test: Likewise. + * tests/mmodely.test: Likewise. + * tests/pr204.test: Likewise. + * tests/pr300-lib.test: Likewise. + * tests/pr300-prog.test: Likewise. + * tests/primary3.test: Likewise. + * tests/specflg7.test: Likewise. + * tests/specflg8.test: Likewise. + * tests/subdir5.test: Likewise. + * tests/subdir8.test: Likewise. + * tests/subobj6.test: Likewise. + * tests/subst3.test: Likewise. + * tests/substre2.test: Likewise. + * tests/yacc6.test: Likewise. + * tests/yacc8.test: Likewise. + * tests/depcomp2.test: Likewise. Also, avoid clobbering user-set + CFLAGS. + * tests/lex3.test: Likewise. + * tests/ansi3.test: Likewise. Also, avoid 'CC=gcc' in configure. + * tests/ansi3b.test: Likewise. + * tests/ansi5.test: Likewise. + * tests/autohdr4.test ($required): Remove 'gcc', as any working + C compiler should be enough. + Also, do not reject slow dependency extractors (which we might + be forced to use now that $CC is not necessarily gcc anymore). + * tests/cond16.test ($required): Remove 'gcc', as any working + C compiler should be enough. + Since we are at it, throw in few minor tweakings (mostly cosmetic, + stylistic, or consistency-related). + * tests/cond18.test: Likewise. + * tests/cond35.test: Likewise. + * tests/gnits2.test: Likewise. + * tests/libtool3.test: Likewise. + * tests/libtool7.test: Likewise. + * tests/libtool9.test: Likewise. + * tests/ltcond.test: Likewise. + * tests/ltcond2.test: Likewise. + * tests/ltconv.test: Likewise. + * tests/ltlibsrc.test: Likewise. + * tests/nobase.test: Likewise. + * tests/nobase-libtool.test: Likewise. + * tests/pr220.test: Likewise. + * tests/pr224.test: Likewise. + * tests/pr300-ltlib.test: Likewise. + * tests/pr401.test: Likewise. + * tests/pr401b.test: Likewise. + * tests/pr401c.test: Likewise. + * tests/subpkg.test: Likewise. + * tests/target-cflags.test: Likewise. + * tests/transform.test: Likewise. + * tests/yacc4.test: Likewise. + * tests/cond19.test: Likewise. Also, avoid clobbering user-set + CFLAGS. + * tests/cond4.test: Likewise. + * tests/depend2.test: Likewise. + * tests/pr87.test: Likewise. + * tests/subobj3.test: Likewise. + * tests/substref.test: Likewise. + +2011-05-03 Stefano Lattarini + test defs: increase coverage w.r.t. GNU make * tests/defs (GNUmake): Instead of just skipping the tests requiring GNU make if $MAKE is not GNU make, try to look for diff --git a/tests/ansi10.test b/tests/ansi10.test index eabe544..a21d6ca 100755 --- a/tests/ansi10.test +++ b/tests/ansi10.test @@ -16,7 +16,6 @@ # Make sure ansi2knr works with $(LIBOBJS). -required=gcc . ./defs || Exit 1 cat >> configure.in << 'END' diff --git a/tests/ansi3.test b/tests/ansi3.test index ba05d71..233e378 100755 --- a/tests/ansi3.test +++ b/tests/ansi3.test @@ -15,10 +15,8 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see . -# Actual test of ansi2knr functionality. Relies on existence -# of working gcc. +# Actual test of ansi2knr functionality. -required=gcc . ./defs || Exit 1 cat >> configure.in << 'END' @@ -42,17 +40,11 @@ main (int argc, char *argv[]) } END -# Ignore user CFLAGS. -CFLAGS= -export CFLAGS - -# 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 2>stderr || { cat stderr >&2; Exit 1; } cat stderr >&2 grep 'Makefile.am:1:.*ansi2knr\.c' stderr -CC='gcc' ./configure +./configure ANSI2KNR=./ansi2knr U=_ $MAKE -e ./hello diff --git a/tests/ansi3b.test b/tests/ansi3b.test index 18bf628..3a5bedf 100755 --- a/tests/ansi3b.test +++ b/tests/ansi3b.test @@ -19,7 +19,6 @@ # of working gcc. Same as ansi3.test, but with AUTOMAKE_OPTIONS # defined in configure.in. -required=gcc . ./defs || Exit 1 cat > configure.in << 'END' @@ -43,17 +42,11 @@ main (int argc, char *argv[]) } END -# Ignore user CFLAGS. -CFLAGS= -export CFLAGS - -# 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 2>stderr || { cat stderr >&2; Exit 1; } cat stderr >&2 grep 'configure.in:2:.*ansi2knr\.1' stderr -CC='gcc' ./configure +./configure ANSI2KNR=./ansi2knr U=_ $MAKE -e ./hello diff --git a/tests/ansi5.test b/tests/ansi5.test index 09ffc50..967f772 100755 --- a/tests/ansi5.test +++ b/tests/ansi5.test @@ -16,7 +16,6 @@ # Test for ansi2knr in another directory. -required=gcc . ./defs || Exit 1 cat > configure.in << 'END' @@ -66,10 +65,7 @@ END $ACLOCAL $AUTOCONF $AUTOMAKE -a -# Ignore user CFLAGS. -CFLAGS= -export CFLAGS -CC=gcc ./configure +./configure # This is ugly! If we set U at make time then the "wrong" file gets # included. diff --git a/tests/ansi6.test b/tests/ansi6.test index d6f637b..c29d7b8 100755 --- a/tests/ansi6.test +++ b/tests/ansi6.test @@ -17,7 +17,6 @@ # Check ansi2knr on a source file in subdirectory. # From Kevin Ryde. -required=gcc . ./defs || Exit 1 cat > configure.in << 'END' diff --git a/tests/ansi7.test b/tests/ansi7.test index 02a768b..d73e9eb 100755 --- a/tests/ansi7.test +++ b/tests/ansi7.test @@ -18,7 +18,6 @@ # ansi6.test is the same test without subdir-objects. # From Kevin Ryde. -required=gcc . ./defs || Exit 1 cat > configure.in << 'END' diff --git a/tests/ansi9.test b/tests/ansi9.test index 9023bf3..b57234d 100755 --- a/tests/ansi9.test +++ b/tests/ansi9.test @@ -18,7 +18,6 @@ # can still be deansified. # Report from Paul D. Smith. -required=gcc . ./defs || Exit 1 cat >>configure.in <>configure.in <<'EOF' @@ -41,8 +40,7 @@ cat >sub3/run.c <<'EOF' #include #include -int -main () +int main (void) { puts (NAME); /* from config.h */ puts (PACKAGE); /* from defs.h */ @@ -55,7 +53,8 @@ $AUTOCONF $AUTOHEADER $AUTOMAKE -./configure +# Do not reject slow dependency extractors: we need dependency tracking. +./configure --enable-dependency-tracking $MAKE sub3/run | grep grepme1 @@ -65,3 +64,5 @@ $MAKE sub3/run | grep grepme2 $MAKE distcheck + +: diff --git a/tests/cond16.test b/tests/cond16.test index 9a60e02..483fa64 100755 --- a/tests/cond16.test +++ b/tests/cond16.test @@ -14,22 +14,19 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see . -# Test for bug in conditionals in SOURCES with variable substitution references. +# Test for bug in conditionals in SOURCES with variable substitution +# references. # Report from Richard Boulton -required=gcc . ./defs || Exit 1 -cat > configure.in << 'END' -AC_INIT(hello.c) -AM_INIT_AUTOMAKE(hello,0.23) +cat >> configure.in << 'END' AC_PROG_CC -AM_CONDITIONAL(COND1, true) -AC_OUTPUT(Makefile) +AM_CONDITIONAL([COND1], [true]) +AC_OUTPUT END -cat > hello.c << 'END' -END +: > hello.c cat > Makefile.am << 'END' @@ -47,10 +44,6 @@ echorule: END -# Ignore user CFLAGS. -CFLAGS= -export CFLAGS - $ACLOCAL $AUTOCONF $AUTOMAKE -a @@ -58,5 +51,6 @@ $AUTOMAKE -a ./configure val=`$MAKE -s echorule`; -echo $val test "x$val" = "xfoo.c foo.o" + +: diff --git a/tests/cond18.test b/tests/cond18.test index 5450389..577c31a 100755 --- a/tests/cond18.test +++ b/tests/cond18.test @@ -17,16 +17,14 @@ # Regression test for substitution references to conditional variables. # Report from Richard Boulton -required='GNUmake gcc' +required=GNUmake . ./defs || Exit 1 -cat > configure.in << 'END' -AC_INIT(Makefile.am) -AM_INIT_AUTOMAKE(hello,0.23) +cat >> configure.in << 'END' AC_PROG_CC -AM_CONDITIONAL(COND1, true) -AM_CONDITIONAL(COND2, true) -AC_OUTPUT(Makefile) +AM_CONDITIONAL([COND1], [true]) +AM_CONDITIONAL([COND2], [true]) +AC_OUTPUT END cat > Makefile.am << 'END' @@ -53,10 +51,6 @@ echorule: bin_PROGRAMS = helldl END -# Ignore user CFLAGS. -CFLAGS= -export CFLAGS - $ACLOCAL $AUTOCONF $AUTOMAKE -a @@ -64,5 +58,6 @@ $AUTOMAKE -a ./configure val=`$MAKE --no-print-directory echorule`; -echo $val test "x$val" = "xdlmain.c foo.c dlmain.o foo.o" + +: diff --git a/tests/cond19.test b/tests/cond19.test index ef01c91..a913575 100755 --- a/tests/cond19.test +++ b/tests/cond19.test @@ -17,16 +17,14 @@ # Regression test for substitution references to conditional variables. # Report from Richard Boulton -required='GNUmake gcc' +required=GNUmake . ./defs || Exit 1 -cat > configure.in << 'END' -AC_INIT(Makefile.am) -AM_INIT_AUTOMAKE(hello,0.23) +cat >> configure.in << 'END' AC_PROG_CC -AM_CONDITIONAL(COND1, test "x$CONDITION1" = "xtrue") -AM_CONDITIONAL(COND2, test "x$CONDITION2" = "xtrue") -AC_OUTPUT(Makefile) +AM_CONDITIONAL([COND1], [test "x$CONDITION1" = "xtrue"]) +AM_CONDITIONAL([COND2], [test "x$CONDITION2" = "xtrue"]) +AC_OUTPUT END cat > Makefile.am << 'END' @@ -55,10 +53,6 @@ echorule: bin_PROGRAMS = helldl END -# Ignore user CFLAGS. -CFLAGS= -export CFLAGS - $ACLOCAL $AUTOCONF $AUTOMAKE -a @@ -72,11 +66,9 @@ valc=`$MAKE --no-print-directory echorule`; CONDITION1=false CONDITION2=false ./configure vald=`$MAKE --no-print-directory echorule`; -echo $vala -echo $valb -echo $valc -echo $vald -test "x$vala" = "xdlmaina1.c dlmainb2.c dlmaina1.o dlmainb2.o" || Exit 1 -test "x$valb" = "xdlmainb1.c dlmaina2.c dlmainb1.o dlmaina2.o" || Exit 1 -test "x$valc" = "xdlmaina1.c dlmainb2.c dlmaina1.o dlmainb2.o" || Exit 1 -test "x$vald" = "xdlmainb1.c dlmaina2.c dlmainb1.o dlmaina2.o" || Exit 1 +test "x$vala" = "xdlmaina1.c dlmainb2.c dlmaina1.o dlmainb2.o" +test "x$valb" = "xdlmainb1.c dlmaina2.c dlmainb1.o dlmaina2.o" +test "x$valc" = "xdlmaina1.c dlmainb2.c dlmaina1.o dlmainb2.o" +test "x$vald" = "xdlmainb1.c dlmaina2.c dlmainb1.o dlmaina2.o" + +: diff --git a/tests/cond35.test b/tests/cond35.test index c3c5f0b..8aa1333 100755 --- a/tests/cond35.test +++ b/tests/cond35.test @@ -17,11 +17,11 @@ # Check rules output for parser defined conditionally. # Report from Roman Fietze. -required='flex yacc gcc' +required='flex yacc' . ./defs || Exit 1 cat >>configure.in <<'EOF' -AM_CONDITIONAL([CASE_A], test -z "$case_B") +AM_CONDITIONAL([CASE_A], [test -z "$case_B"]) AC_PROG_CC AM_PROG_LEX AC_PROG_YACC @@ -70,8 +70,8 @@ void yyerror (char *s) {} foobar : 'f' 'o' 'o' 'b' 'a' 'r' EOF {}; END -cat >ta.c <<'END' -int main() +cat > ta.c << 'END' +int main (void) { return 0; } @@ -86,3 +86,5 @@ $MAKE test-ta ./configure case_B=yes $MAKE $MAKE test-tb + +: diff --git a/tests/cond4.test b/tests/cond4.test index 76187dd..7c56103 100755 --- a/tests/cond4.test +++ b/tests/cond4.test @@ -17,7 +17,7 @@ # Another sources-in-conditional test. Report from Tim Goodwin. -required='GNUmake gcc' +required=GNUmake . ./defs || Exit 1 cat >> configure.in << 'END' @@ -52,10 +52,6 @@ test "`grep '^@TWO_FALSE@' Makefile.in | wc -l`" -eq 0 $AUTOCONF -# Ignore user CFLAGS. -CFLAGS= -export CFLAGS - CONDITION1=true CONDITION2=true ./configure msgtt=`$MAKE --no-print-directory echo-objects` CONDITION1=true CONDITION2=false ./configure diff --git a/tests/depcomp2.test b/tests/depcomp2.test index 2efa2ad..176a31e 100755 --- a/tests/depcomp2.test +++ b/tests/depcomp2.test @@ -17,7 +17,6 @@ # Test to make sure that depcomp is not used when it's not installed # From Pavel Roskin. -required=gcc . ./defs || Exit 1 cat >> configure.in << 'END' @@ -40,9 +39,6 @@ END : > subdir/foo.c -# Ignore user CFLAGS. -unset CFLAGS || : - $ACLOCAL $AUTOMAKE --add-missing $AUTOCONF diff --git a/tests/depend2.test b/tests/depend2.test index dd8fe6e..a5ca0c0 100755 --- a/tests/depend2.test +++ b/tests/depend2.test @@ -19,7 +19,6 @@ # --disable-dependency-tracking. # Report from Robert Boehne -required=gcc . ./defs || Exit 1 cat >> configure.in << 'END' @@ -37,8 +36,7 @@ END cat > hello.c << 'END' #include "hello.h" -int -main (int argc, char *argv[]) +int main (int argc, char *argv[]) { printf ("yeah, yeah\n"); return 0; @@ -49,10 +47,7 @@ $ACLOCAL $AUTOCONF $AUTOMAKE -a -# Ignore user CFLAGS. -CFLAGS= -export CFLAGS - ./configure --disable-dependency-tracking - $MAKE + +: diff --git a/tests/gnits2.test b/tests/gnits2.test index b5e750f..26e8747 100755 --- a/tests/gnits2.test +++ b/tests/gnits2.test @@ -17,7 +17,6 @@ # Test to ensure std-options checking is correct. -required=gcc . ./defs || Exit 1 cat >> configure.in << 'END' @@ -39,7 +38,7 @@ bin_SCRIPTS = sub/scriptok.sh sub/scriptnok.sh grep-stderr: grep 'pfubar$(EXEEXT) does not support' stderr grep 'pfubar3$(EXEEXT) does not support' stderr - grep 'pscriptnok.sh does not support' stderr + grep 'pscriptnok\.sh does not support' stderr ## Only three failures please. test `grep 'does not support --help' stderr | wc -l` = 3 test `grep 'does not support --version' stderr | wc -l` = 3 @@ -49,12 +48,16 @@ test-install: install test ! -f ../inst-dir/bin/fine$(EXEEXT) END -echo 'int main () { return 0; }' > fubar.c +cat > fubar.c <<'END' +int main (void) +{ + return 0; +} +END cat > fine.c << 'END' #include -int -main () +int main (void) { puts ("Which version? Which usage?"); return 0; diff --git a/tests/gnits3.test b/tests/gnits3.test index d9965ee..0c86835 100755 --- a/tests/gnits3.test +++ b/tests/gnits3.test @@ -16,7 +16,6 @@ # Check that AM_INSTALLCHECK_STD_OPTIONS_EXEMPT works. -required=gcc . ./defs || Exit 1 cat >> configure.in << 'END' @@ -40,13 +39,18 @@ AM_INSTALLCHECK_STD_OPTIONS_EXEMPT = nok$(EXEEXT) nok.sh grep-stderr: grep 'sub/pnok$(EXEEXT) does not support' stderr - grep 'sub/pnok.sh does not support' stderr + grep 'sub/pnok\.sh does not support' stderr ## Only two failures please. test `grep 'does not support --help' stderr | wc -l` = 2 test `grep 'does not support --version' stderr | wc -l` = 2 END -echo 'int main () { return 0; }' > nok.c +cat > nok.c <<'END' +int main (void) +{ + return 0; +} +END mkdir sub diff --git a/tests/lex3.test b/tests/lex3.test index f702864..b10a6cb 100755 --- a/tests/lex3.test +++ b/tests/lex3.test @@ -19,13 +19,9 @@ # Test associated with PR 19. # From Matthew D. Langston. -required='gcc flex GNUmake' +required='flex GNUmake' . ./defs || Exit 1 -# Ignore user CFLAGS. -CFLAGS= -export CFLAGS - cat >> configure.in << 'END' AC_PROG_CC AM_PROG_LEX diff --git a/tests/lex5.test b/tests/lex5.test index 220bf50..d57a619 100755 --- a/tests/lex5.test +++ b/tests/lex5.test @@ -17,7 +17,7 @@ # Test for subdir lexers. -required='gcc GNUmake flex' +required='GNUmake flex' . ./defs || Exit 1 cat >> configure.in << 'END' diff --git a/tests/lexvpath.test b/tests/lexvpath.test index 300a476..4b75950 100755 --- a/tests/lexvpath.test +++ b/tests/lexvpath.test @@ -22,7 +22,7 @@ # Please keep this in sync with sister test `yaccvapth.test'. -required='gcc flex' +required=flex . ./defs || Exit 1 cat > lexoutroot.in << 'END' diff --git a/tests/libobj14.test b/tests/libobj14.test index 4f05871..daeaa25 100755 --- a/tests/libobj14.test +++ b/tests/libobj14.test @@ -19,7 +19,6 @@ # that uses it. # Report from Bill Davidson -required=gcc . ./defs || Exit 1 cat >>configure.in <<'EOF' diff --git a/tests/libtool3.test b/tests/libtool3.test index 3a6a40e..b50cde2 100755 --- a/tests/libtool3.test +++ b/tests/libtool3.test @@ -17,7 +17,7 @@ # Try to build and package a program linked to a Libtool library. # Also make sure we do not bloat the Makefile with unneeded rules. -required='libtoolize gcc' +required=libtoolize . ./defs || Exit 1 cat >> configure.in << 'END' @@ -50,7 +50,7 @@ cat > sub/1.c << 'END' int zero (); int -main () +main (void) { return zero (); } @@ -85,3 +85,5 @@ $FGREP 'a.lo:' Makefile.in $MAKE $MAKE distcheck + +: diff --git a/tests/libtool7.test b/tests/libtool7.test index afa9b1c..39d64b0 100755 --- a/tests/libtool7.test +++ b/tests/libtool7.test @@ -17,7 +17,7 @@ # Make sure we allow Libtool's -dlopen/-dlpreopen # Also check basic support for AM_LIBTOOLFLAGS/LIBTOOLFLAGS -required='libtoolize gcc' +required=libtoolize . ./defs || Exit 1 cat >> configure.in << 'END' @@ -42,6 +42,7 @@ bin_PROGRAMS = prg prg_SOURCES = prg.c prg_LDADD = -dlopen libmod1.la -dlpreopen mod2.la +.PHONY: print print: @echo 1BEG: $(prg_DEPENDENCIES) :END1 @echo 2BEG: $(libmod1_la_DEPENDENCIES) :END2 @@ -51,24 +52,21 @@ END mkdir sub liba cat > sub/mod1.c << 'END' -int -mod1 () +int mod1 (void) { return 1; } END cat > mod2.c << 'END' -int -mod2 () +int mod2 (void) { return 2; } END cat > prg.c << 'END' -int -main () +int main (void) { return 0; } @@ -96,3 +94,5 @@ grep 'silent.*silent.*libmod1' output env LIBTOOLFLAGS=--silent $MAKE uninstall >output 2>&1 cat output grep 'silent.*silent.*libmod1' output + +: diff --git a/tests/libtool9.test b/tests/libtool9.test index ab03f58..99e16ce 100755 --- a/tests/libtool9.test +++ b/tests/libtool9.test @@ -16,9 +16,10 @@ # Make sure xxx_LINK is defined for each target that requires specific # flags. -# Quite similar to libtool7.test, using AM_LDFLAGS in addition to xxx_LDFLAGS. +# Quite similar to libtool7.test, using AM_LDFLAGS in addition to +# xxx_LDFLAGS. -required='libtoolize gcc' +required=libtoolize . ./defs || Exit 1 cat >> configure.in << 'END' @@ -57,24 +58,21 @@ END mkdir liba cat > mod1.c << 'END' -int -mod1 () +int mod1 (void) { return 1; } END cat > mod2.c << 'END' -int -mod2 () +int mod2 (void) { return 2; } END cat > prg.c << 'END' -int -main () +int main (void) { return 0; } @@ -99,3 +97,5 @@ grep '5BEG: :END5' output grep '6BEG:.* prg2_cflags cflags .*am_ldflags ldflags.* :END6' output grep '6BEG: .*am_cflags.* :END6' output && Exit 1 $MAKE + +: diff --git a/tests/ltcond.test b/tests/ltcond.test index 8ede51b..1c4069d 100755 --- a/tests/ltcond.test +++ b/tests/ltcond.test @@ -17,7 +17,7 @@ # Test for conditional libtool libraries. # This combines two examples from the manual. -required='libtoolize gcc' +required=libtoolize . ./defs || Exit 1 cat >>configure.in <<'END' @@ -100,3 +100,5 @@ test ! -f lib1foo.la test ! -f lib1bar.la test ! -f lib2foo.la test ! -f lib3foo.la + +: diff --git a/tests/ltcond2.test b/tests/ltcond2.test index d4bf064..10e155e 100755 --- a/tests/ltcond2.test +++ b/tests/ltcond2.test @@ -16,14 +16,14 @@ # Test for bug in conditionals. -required='libtoolize gcc' +required=libtoolize . ./defs || Exit 1 cat >> configure.in << 'END' AC_PROG_CC AC_PROG_LIBTOOL AC_SUBST([HELLO_SYSTEM], [hello-generic.lo]) -AM_CONDITIONAL([LINUX], true) +AM_CONDITIONAL([LINUX], [true]) AC_OUTPUT END @@ -54,17 +54,36 @@ check-local: : > check-ok END -echo 'char* str() { return "hello-linux"; }' >hello-linux.c -echo 'char* str() { return "hello-generic"; }' >hello-generic.c -cat >hello-common.c <<'END' +cat > hello-linux.c <<'END' +const char* str (void) +{ + return "hello-linux"; +} +END + +cat > hello-generic.c <<'END' +const char* str (void) +{ + return "hello-generic"; +} +END + +cat > hello-common.c <<'END' #include -char* str(); -void print() +const char* str (void); +void print (void) { puts (str ()); } END -echo 'int main() { print(); return 0; }' >main.c + +cat > main.c <<'END' +int main (void) +{ + print(); + return 0; +} +END libtoolize $ACLOCAL @@ -73,3 +92,5 @@ $AUTOMAKE --add-missing ./configure $MAKE check test -f check-ok + +: diff --git a/tests/ltconv.test b/tests/ltconv.test index 2ea2705..208e2ad 100755 --- a/tests/ltconv.test +++ b/tests/ltconv.test @@ -17,16 +17,16 @@ # Test for libtool convenience libraries. # This example is taken from the manual. -required='libtoolize gcc' +required=libtoolize . ./defs || Exit 1 cat >>configure.in <<'END' AC_PROG_CC AC_PROG_LIBTOOL -AC_CONFIG_FILES(sub1/Makefile - sub2/Makefile - sub2/sub21/Makefile - sub2/sub22/Makefile) +AC_CONFIG_FILES([sub1/Makefile + sub2/Makefile + sub2/sub21/Makefile + sub2/sub22/Makefile]) AC_OUTPUT END @@ -88,7 +88,7 @@ END echo 'int sub22 () { return 22; }' > sub2/sub22/sub22.c -cat >test.c <test.c <<'EOF' #include int main () { @@ -151,3 +151,5 @@ find lib -type f -print > lib.lst test 0 = `wc -l < lib.lst` find bin -type f -print > bin.lst test 0 = `wc -l < bin.lst` + +: diff --git a/tests/ltlibsrc.test b/tests/ltlibsrc.test index 78ac8e2..404d274 100755 --- a/tests/ltlibsrc.test +++ b/tests/ltlibsrc.test @@ -16,7 +16,7 @@ # Test to make sure a sensible default source for libraries is used. -required='libtool gcc' +required=libtool . ./defs || Exit 1 cat >> configure.in << 'END' @@ -37,7 +37,10 @@ $(srcdir)/zoo_d_old2_la.c: $(srcdir)/old_la.c END cat > foo.c << 'END' -int foo (void) { return 0; } +int foo (void) +{ + return 0; +} END cp foo.c zoo.d/bar.c @@ -47,10 +50,10 @@ libtoolize $ACLOCAL $AUTOCONF AUTOMAKE_fails -a -grep 'Makefile.am:2:.*old_la.c' stderr -grep 'Makefile.am:2:.*old.c' stderr -grep 'Makefile.am:3:.*zoo_d_old2_la.c' stderr -grep 'Makefile.am:3:.*zoo\.d/old2.c' stderr +grep '^Makefile\.am:2:.*old_la\.c' stderr +grep '^Makefile\.am:2:.*old\.c' stderr +grep '^Makefile\.am:3:.*zoo_d_old2_la\.c' stderr +grep '^Makefile\.am:3:.*zoo\.d/old2\.c' stderr $AUTOMAKE -Wno-obsolete @@ -66,3 +69,5 @@ test -f old.la test -f zoo.d/old2.la $MAKE distcheck + +: diff --git a/tests/mmodely.test b/tests/mmodely.test index 03c5d0f..f2ad334 100755 --- a/tests/mmodely.test +++ b/tests/mmodely.test @@ -19,7 +19,6 @@ # sources in maintainer mode. # From Derek R. Price. -required=gcc . ./defs || Exit 1 cat >> configure.in << 'END' diff --git a/tests/nobase-libtool.test b/tests/nobase-libtool.test index 15d1b49..e2d2847 100755 --- a/tests/nobase-libtool.test +++ b/tests/nobase-libtool.test @@ -19,7 +19,7 @@ # This is just the libtool equivalent of nobase.test, split # up for greater exposure of nobase.test. -required='libtoolize gcc' +required=libtoolize . ./defs || Exit 1 cat >> configure.in <<'EOF' @@ -47,6 +47,8 @@ test-install-exec: install-exec test -f inst/foo/sub/libnobase.la test ! -f inst/foo/libnobase.la test -f inst/foo/libbase.la + +.PHONY: test-install-exec test-install-data EOF mkdir sub @@ -89,3 +91,5 @@ $MAKE test-install-data $MAKE test-install-exec $MAKE uninstall test `find inst/foo -type f -print | wc -l` = 0 + +: diff --git a/tests/nobase.test b/tests/nobase.test index 2fa9a60..52335d4 100755 --- a/tests/nobase.test +++ b/tests/nobase.test @@ -17,7 +17,6 @@ # Make sure nobase_* works. -required='gcc' . ./defs || Exit 1 cat >> configure.in <<'EOF' @@ -93,6 +92,8 @@ test-install-exec: install-exec test -f inst/foo/sub/libnobase.a test ! -f inst/foo/libnobase.a test -f inst/foo/libbase.a + +.PHONY: test-install-exec test-install-data EOF mkdir sub @@ -141,3 +142,5 @@ $MAKE test-install-data $MAKE test-install-exec $MAKE uninstall test `find inst/foo -type f -print | wc -l` = 0 + +: diff --git a/tests/pr204.test b/tests/pr204.test index 27453e0..c0db1b4 100755 --- a/tests/pr204.test +++ b/tests/pr204.test @@ -17,7 +17,7 @@ # For PR 204. # Sources derived from nodist_ sources should not be distributed. -required='yacc gcc' +required=yacc . ./defs || Exit 1 cat >> configure.in <<'EOF' diff --git a/tests/pr220.test b/tests/pr220.test index 972f5aa..6e8040e 100755 --- a/tests/pr220.test +++ b/tests/pr220.test @@ -23,11 +23,13 @@ # to debug the problem. # Note that this should be also in the documentation. -required=gcc . ./defs || Exit 1 -cat > main.c <<'EOF' -int main() { return 0; } +cat > main.c << 'EOF' +int main (void) +{ + return 0; +} EOF cat > Makefile.am << 'EOF' @@ -41,12 +43,12 @@ EOF cat >> configure.in << 'EOF' AC_PROG_CC -AC_ARG_ENABLE(foo, +AC_ARG_ENABLE([foo], [ --enable-foo Enable foo], [ if test "foo" = "bar" ; then - AM_CONDITIONAL(NEVER_TRUE, true) + AM_CONDITIONAL([NEVER_TRUE], [true]) else - AM_CONDITIONAL(NEVER_TRUE, false) + AM_CONDITIONAL([NEVER_TRUE], [false]) fi ]) AC_OUTPUT diff --git a/tests/pr224.test b/tests/pr224.test index d8b7468..8e9414a 100755 --- a/tests/pr224.test +++ b/tests/pr224.test @@ -23,13 +23,15 @@ # `$(top_srcdir)/build', the location of the `.deps' directory # should be `$(top_builddir)/bar/.deps'. -required=gcc . ./defs || Exit 1 mkdir foo cat >foo/main.c <<'EOF' -int main() { return 0; } +int main (void) +{ + return 0; +} EOF cat >Makefile.am <<'EOF' diff --git a/tests/pr300-lib.test b/tests/pr300-lib.test index 530f6c4..951ec52 100755 --- a/tests/pr300-lib.test +++ b/tests/pr300-lib.test @@ -17,7 +17,6 @@ # Make sure that installing subdirectory libraries works. # PR/300 -required=gcc . ./defs || Exit 1 cat >> configure.in << 'END' diff --git a/tests/pr300-ltlib.test b/tests/pr300-ltlib.test index 1b36136..1ac26af 100755 --- a/tests/pr300-ltlib.test +++ b/tests/pr300-ltlib.test @@ -18,7 +18,7 @@ # Make sure that installing subdirectory libtool libraries works. # PR/300 -required='libtoolize gcc' +required=libtoolize . ./defs || Exit 1 cat >> configure.in << 'END' @@ -39,9 +39,6 @@ cat > a.c << 'END' int i = 3; END -## A rule in the Makefile should create subdir -# mkdir subdir - libtoolize $ACLOCAL $AUTOCONF @@ -49,8 +46,11 @@ $AUTOMAKE --copy --add-missing ./configure --prefix "`pwd`/inst" -$MAKE V=1 >stdout || { cat stdout; Exit 1; } +# A rule in the Makefile should create subdir. +test ! -d subdir +$MAKE >stdout || { cat stdout; Exit 1; } cat stdout +test -d subdir grep 'liba.la .*-rpath .*lib' stdout grep 'liba.la .*-rpath .*lib/subdir' stdout && Exit 1 diff --git a/tests/pr300-prog.test b/tests/pr300-prog.test index 63eef41..c663012 100755 --- a/tests/pr300-prog.test +++ b/tests/pr300-prog.test @@ -18,7 +18,6 @@ # Make sure that installing subdirectory programs works. # PR/300 -required=gcc . ./defs || Exit 1 cat >> configure.in << 'END' diff --git a/tests/pr401.test b/tests/pr401.test index fc3a72f..ad76cb8 100755 --- a/tests/pr401.test +++ b/tests/pr401.test @@ -18,14 +18,12 @@ # Check support for AC_CONFIG_LIBOBJ_DIR vs LIBOBJS. # (pr401b.test and pr401c.test do the same for LTLIBOBJS and ALLOCA) -required=gcc . ./defs || Exit 1 mkdir lib src cat >lib/feep.c <<'EOF' -char * -feep () +const char *feep (void) { return "feep"; } @@ -34,10 +32,9 @@ EOF cat >src/main.c <<'EOF' #include -extern char *feep (); +extern const char *feep (void); -int -main (int argc, char **argv) +int main (void) { puts (feep ()); return 0; diff --git a/tests/pr401b.test b/tests/pr401b.test index 8c7a7e1..1a38443 100755 --- a/tests/pr401b.test +++ b/tests/pr401b.test @@ -18,14 +18,13 @@ # Check support for AC_CONFIG_LIBOBJ_DIR vs LTLIBOBJS. # (pr401.test and pr401c.test do the same for LIBOBJS and ALLOCA) -required='gcc libtoolize' +required=libtoolize . ./defs || Exit 1 mkdir lib src cat >lib/feep.c <<'EOF' -char * -feep () +const char *feep (void) { return "feep"; } @@ -34,10 +33,9 @@ EOF cat >src/main.c <<'EOF' #include -extern char *feep (); +extern const char *feep (void); -int -main (int argc, char **argv) +int main (void) { puts (feep ()); return 0; @@ -84,10 +82,9 @@ $AUTOMAKE -a ./configure $MAKE distcheck - -## ------------------------------------------ ## -## Traditional LIBOBJS with LIBOBJDIR set. ## -## ------------------------------------------ ## +## ----------------------------------------- ## +## Traditional LTLIBOBJS with LIBOBJDIR set. ## +## ----------------------------------------- ## # Invocation of AC_CONFIG_LIBOBJ_DIR may be necessary for reasons # unrelated to Automake or Makefile.am layout. diff --git a/tests/pr401c.test b/tests/pr401c.test index 2b5bcf3..2b35d81 100755 --- a/tests/pr401c.test +++ b/tests/pr401c.test @@ -18,7 +18,6 @@ # Check support for AC_CONFIG_LIBOBJ_DIR vs ALLOCA. # (pr401.test and pr401b.test do the same for LIBOBJS and LTLIBOBJS) -required=gcc . ./defs || Exit 1 mkdir lib src @@ -27,8 +26,7 @@ ac_cv_func_alloca_works=no export ac_cv_func_alloca_works cat >lib/alloca.c <<'EOF' -char * -feep () +const char *feep (void) { return "feep"; } @@ -37,10 +35,9 @@ EOF cat >src/main.c <<'EOF' #include -extern char *feep (); +extern const char *feep (void); -int -main (int argc, char **argv) +int main (void) { puts (feep ()); return 0; @@ -86,9 +83,9 @@ $AUTOMAKE $MAKE distcheck -## ------------------------------------------ ## -## Traditional LIBOBJS with LIBOBJDIR set. ## -## ------------------------------------------ ## +## --------------------------------------- ## +## Traditional ALLOCA with LIBOBJDIR set. ## +## --------------------------------------- ## # Invocation of AC_CONFIG_LIBOBJ_DIR may be necessary for reasons # unrelated to Automake or Makefile.am layout. diff --git a/tests/pr87.test b/tests/pr87.test index 3c860bd..c8c2e91 100755 --- a/tests/pr87.test +++ b/tests/pr87.test @@ -18,19 +18,21 @@ # Test for PR automake/87. # "make distcheck" fails when two source dirs exist. -required=gcc . ./defs || Exit 1 subdirs="foo bar" for i in $subdirs; do mkdir $i - cat >$i/$i.c <$i/$i.c <$i/Makefile.am <$i/Makefile.am <>configure.in <> configure.in << 'END' @@ -59,3 +58,5 @@ $MAKE ./false | grep false test -f ./t-false.o test -f ./f-false.o + +: diff --git a/tests/specflg8.test b/tests/specflg8.test index 1defd0b..9d1d5ff 100755 --- a/tests/specflg8.test +++ b/tests/specflg8.test @@ -18,7 +18,6 @@ # with one extra indirection in the sources (PR/315), and # use of _CPPFLAGS (PR/337). -required=gcc . ./defs || Exit 1 cat >> configure.in << 'END' @@ -62,3 +61,5 @@ $AUTOMAKE -a $MAKE ./true | grep true ./false | grep false + +: diff --git a/tests/subdir5.test b/tests/subdir5.test index 60730cb..9d223d4 100755 --- a/tests/subdir5.test +++ b/tests/subdir5.test @@ -23,7 +23,7 @@ # This test assumes that the `make' utility is able to start # over and reload Makefiles which have been remade (a non-POSIX feature). # See also the related test subdir8.test. -required='GNUmake gcc' +required=GNUmake . ./defs || Exit 1 cat >> configure.in << 'END' diff --git a/tests/subdir8.test b/tests/subdir8.test index 98146ba..1bb4c3c 100755 --- a/tests/subdir8.test +++ b/tests/subdir8.test @@ -23,7 +23,7 @@ # This test assumes that the `make' utility is able to start # over and reload Makefiles which have been remade (a non-POSIX feature). # See also the related test subdir5.test. -required='GNUmake gcc' +required=GNUmake . ./defs || Exit 1 cat >> configure.in << 'END' diff --git a/tests/subobj3.test b/tests/subobj3.test index 5ba999c..0faeaa5 100755 --- a/tests/subobj3.test +++ b/tests/subobj3.test @@ -15,9 +15,8 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see . -# Test of subdir objects with C++. +# Test of subdir objects with ansi2knr. -required=gcc . ./defs || Exit 1 cat > configure.in << END @@ -50,12 +49,6 @@ main (int argc, char *argv[]) } END -# Ignore user CFLAGS. -CFLAGS= -export CFLAGS - -# 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 diff --git a/tests/subobj6.test b/tests/subobj6.test index 48a0f2d..9686bf0 100755 --- a/tests/subobj6.test +++ b/tests/subobj6.test @@ -18,7 +18,6 @@ # Test of subdir make distclean rules. # From Robert Collins -required=gcc . ./defs || Exit 1 cat >> configure.in << 'END' diff --git a/tests/subpkg.test b/tests/subpkg.test index 481cbb4..a89d0cf 100755 --- a/tests/subpkg.test +++ b/tests/subpkg.test @@ -17,7 +17,7 @@ # Check subpackage handling. -required='gcc yacc' +required=yacc . ./defs || Exit 1 mkdir m4 @@ -52,10 +52,9 @@ ACLOCAL_AMFLAGS = -I m4 EOF cat >LDADD.c <<'EOF' -int lib (); +int lib (void); -int -main () +int main (void) { return lib (); } @@ -102,7 +101,7 @@ cp lib/foo.y lib/bar.y cat >lib/src/x.c <<'EOF' #include -int lib () +int lib (void) { return 0; } @@ -125,3 +124,5 @@ $MAKE $MAKE distcheck test ! -d subpack-1 # make sure distcheck cleans up after itself test -f subpack-1.tar.gz + +: diff --git a/tests/subst3.test b/tests/subst3.test index c1b2dfc..d6964a2 100755 --- a/tests/subst3.test +++ b/tests/subst3.test @@ -17,7 +17,6 @@ # Test installation with substitutions. This test is based on nobase.test. -required='gcc' . ./defs || Exit 1 cat >> configure.in <<'EOF' @@ -173,3 +172,5 @@ test `find inst/foo -type f -print | wc -l` = 0 $MAKE $MAKE test-install-nothing-data $MAKE test-install-nothing-exec + +: diff --git a/tests/substre2.test b/tests/substre2.test index c8ffd38..10179cc 100755 --- a/tests/substre2.test +++ b/tests/substre2.test @@ -17,7 +17,6 @@ # Test for bug in variable substitution references, where # undefined variables break later substitutions. -required=gcc . ./defs || Exit 1 cat >> configure.in << 'END' diff --git a/tests/substref.test b/tests/substref.test index 12f72e3..694563b 100755 --- a/tests/substref.test +++ b/tests/substref.test @@ -18,7 +18,6 @@ # pattern is null. # Report from Richard Boulton -required=gcc . ./defs || Exit 1 cat >> configure.in << 'END' @@ -30,24 +29,14 @@ cat > hello.c << 'END' END cat > Makefile.am << 'END' - var1 = dlmain - var2 = $(var1:=.) - helldl_SOURCES = $(var2:=c) - bin_PROGRAMS = helldl - got: @echo $(helldl_SOURCES) $(helldl_OBJECTS) >got - END -# Ignore user CFLAGS. -CFLAGS= -export CFLAGS - $ACLOCAL $AUTOCONF $AUTOMAKE -a diff --git a/tests/target-cflags.test b/tests/target-cflags.test index 352808e..9dda2d6 100755 --- a/tests/target-cflags.test +++ b/tests/target-cflags.test @@ -18,7 +18,6 @@ # Test to make sure target specific CFLAGS work # Assar Westerlund -required=gcc . ./defs || Exit 1 cat >> configure.in << 'END' @@ -37,7 +36,8 @@ END cat > foo.c << 'END' #include #ifdef FOO -int main(void) { +int main(void) +{ return 0; } #endif diff --git a/tests/targetclash.test b/tests/targetclash.test index 22a1ad3..c712fd5 100755 --- a/tests/targetclash.test +++ b/tests/targetclash.test @@ -16,7 +16,6 @@ # Check that target clashes are diagnosed. -required=gcc . ./defs || Exit 1 cat >> configure.in << 'END' diff --git a/tests/transform.test b/tests/transform.test index 04e8d53..67da70e 100755 --- a/tests/transform.test +++ b/tests/transform.test @@ -17,7 +17,6 @@ # Make sure that --program-transform works. -required=gcc . ./defs || Exit 1 cat >>configure.in <<'END' @@ -30,6 +29,7 @@ bin_PROGRAMS = h bin_SCRIPTS = h.sh man_MANS = h.1 +.PHONY: test-install test-install: install test -f inst/bin/gnu-h$(EXEEXT) test -f inst/bin/gnu-h.sh @@ -37,8 +37,7 @@ test-install: install EOF cat >h.c <<'EOF' -int -main () +int main (void) { return 0; } @@ -62,3 +61,5 @@ rm -rf inst $MAKE installdirs test -d inst/bin test -d inst/man/man1 + +: diff --git a/tests/yacc4.test b/tests/yacc4.test index 06376ec..b663300 100755 --- a/tests/yacc4.test +++ b/tests/yacc4.test @@ -16,7 +16,7 @@ # Some simple tests of ylwrap functionality. -required='yacc gcc' +required=yacc . ./defs || Exit 1 cat >> configure.in << 'END' @@ -44,7 +44,7 @@ END # Second parser. cat > bar.y << 'END' %{ -int yylex () {return 0;} +int yylex () { return 0; } void yyerror (char *s) {} %} %% @@ -52,7 +52,10 @@ fubar : 'f' 'o' 'o' 'b' 'a' 'r' {}; END cat > foo.c << 'END' -int main () { return 0; } +int main (void) +{ + return 0; +} END $ACLOCAL diff --git a/tests/yacc8.test b/tests/yacc8.test index fecd54b..88e4123 100755 --- a/tests/yacc8.test +++ b/tests/yacc8.test @@ -17,7 +17,7 @@ # Test for subdir parsers. -required="gcc yacc" +required=yacc . ./defs || Exit 1 -- 2.7.4