From: Stefano Lattarini Date: Tue, 27 Apr 2010 00:13:15 +0000 (+0200) Subject: Tests on silent-mode for C/Libtool made stricter. X-Git-Tag: v1.11.1b~82^2~1 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=394f51778d21e9b156f140c95945a16490e1c38b;p=thirdparty%2Fautomake.git Tests on silent-mode for C/Libtool made stricter. * tests/silent.test: Made stricter w.r.t. the grepping of the output produced by `make'. * tests/silent2.test: Likewise. * tests/silent4.test: Likewise. * tests/silent9.test: Likewise. * tests/silent3.test: Likewise, and add a final `make distclean' command to keep it better in sync with tests/silent{4,9}.test. Signed-off-by: Ralf Wildenhues --- diff --git a/ChangeLog b/ChangeLog index ad4f61703..cefd5bd0e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,14 @@ 2010-06-06 Stefano Lattarini + Tests on silent-mode for C/Libtool made stricter. + * tests/silent.test: Made stricter w.r.t. the grepping of the + output produced by `make'. + * tests/silent2.test: Likewise. + * tests/silent4.test: Likewise. + * tests/silent9.test: Likewise. + * tests/silent3.test: Likewise, and add a final `make distclean' + command to keep it better in sync with tests/silent{4,9}.test. + Improved test silent5.test. * tests/silent5.test: Remove by hand all generated C files after non-verbose builds, to ensure the following builds are clean. diff --git a/tests/silent.test b/tests/silent.test index 62fd786e5..c91115c99 100755 --- a/tests/silent.test +++ b/tests/silent.test @@ -63,8 +63,7 @@ $AUTOCONF ./configure --enable-silent-rules $MAKE >stdout || { cat stdout; Exit 1; } cat stdout -grep ' -c' stdout && Exit 1 -grep ' -o foo' stdout && Exit 1 +$EGREP ' (-c|-o)' stdout && Exit 1 grep 'mv ' stdout && Exit 1 grep 'CC .*foo\.' stdout grep 'CC .*bar\.' stdout @@ -80,13 +79,6 @@ $MAKE V=1 >stdout || { cat stdout; Exit 1; } cat stdout grep ' -c' stdout grep ' -o foo' stdout -grep 'CC .*foo\.' stdout && Exit 1 -grep 'CC .*bar\.' stdout && Exit 1 -grep 'CC .*baz\.' stdout && Exit 1 -grep 'CC .*bla\.' stdout && Exit 1 -grep 'CCLD .*foo' stdout && Exit 1 -grep 'CCLD .*bar' stdout && Exit 1 -grep 'CCLD .*baz' stdout && Exit 1 -grep 'CCLD .*bla' stdout && Exit 1 +$EGREP '(CC|LD) ' stdout && Exit 1 : diff --git a/tests/silent2.test b/tests/silent2.test index de6615247..da2271848 100755 --- a/tests/silent2.test +++ b/tests/silent2.test @@ -65,8 +65,7 @@ $AUTOCONF ./configure am_cv_CC_dependencies_compiler_type=gcc --enable-silent-rules $MAKE >stdout || { cat stdout; Exit 1; } cat stdout -grep ' -c' stdout && Exit 1 -grep ' -o foo' stdout && Exit 1 +$EGREP ' (-c|-o)' stdout && Exit 1 grep 'mv ' stdout && Exit 1 grep 'CC .*foo\.' stdout grep 'CC .*bar\.' stdout @@ -82,13 +81,6 @@ $MAKE V=1 >stdout || { cat stdout; Exit 1; } cat stdout grep ' -c' stdout grep ' -o foo' stdout -grep 'CC .*foo\.' stdout && Exit 1 -grep 'CC .*bar\.' stdout && Exit 1 -grep 'CC .*baz\.' stdout && Exit 1 -grep 'CC .*bla\.' stdout && Exit 1 -grep 'CCLD .*foo' stdout && Exit 1 -grep 'CCLD .*bar' stdout && Exit 1 -grep 'CCLD .*baz' stdout && Exit 1 -grep 'CCLD .*bla' stdout && Exit 1 +$EGREP '(CC|LD) ' stdout && Exit 1 : diff --git a/tests/silent3.test b/tests/silent3.test index ca783c82d..d0a013104 100755 --- a/tests/silent3.test +++ b/tests/silent3.test @@ -66,8 +66,7 @@ $AUTOCONF ./configure --enable-silent-rules $MAKE >stdout || { cat stdout; Exit 1; } cat stdout -grep ' -c' stdout && Exit 1 -grep ' -o libfoo' stdout && Exit 1 +$EGREP ' (-c|-o)' stdout && Exit 1 grep 'mv ' stdout && Exit 1 grep ' CC .*foo\.' stdout grep ' CC .*bar\.' stdout @@ -83,13 +82,9 @@ $MAKE V=1 >stdout || { cat stdout; Exit 1; } cat stdout grep ' -c' stdout grep ' -o libfoo' stdout -grep ' CC .*foo\.' stdout && Exit 1 -grep ' CC .*bar\.' stdout && Exit 1 -grep ' CC .*baz\.' stdout && Exit 1 -grep ' CC .*bla\.' stdout && Exit 1 -grep ' CCLD .*foo' stdout && Exit 1 -grep ' CCLD .*bar' stdout && Exit 1 -grep ' CCLD .*baz' stdout && Exit 1 -grep ' CCLD .*bla' stdout && Exit 1 +# The libtool command line can contain e.g. a `--tag=CC' option. +sed 's/--tag=[^ ]*/--tag=x/g' stdout | $EGREP '(CC|LD) ' && Exit 1 + +$MAKE distclean : diff --git a/tests/silent4.test b/tests/silent4.test index 778570961..c6c1298bc 100755 --- a/tests/silent4.test +++ b/tests/silent4.test @@ -67,8 +67,7 @@ $AUTOCONF ./configure am_cv_CC_dependencies_compiler_type=gcc --enable-silent-rules $MAKE >stdout || { cat stdout; Exit 1; } cat stdout -grep ' -c' stdout && Exit 1 -grep ' -o libfoo' stdout && Exit 1 +$EGREP ' (-c|-o)' stdout && Exit 1 grep 'mv ' stdout && Exit 1 grep ' CC .*foo\.' stdout grep ' CC .*bar\.' stdout @@ -84,14 +83,8 @@ $MAKE V=1 >stdout || { cat stdout; Exit 1; } cat stdout grep ' -c' stdout grep ' -o libfoo' stdout -grep ' CC .*foo\.' stdout && Exit 1 -grep ' CC .*bar\.' stdout && Exit 1 -grep ' CC .*baz\.' stdout && Exit 1 -grep ' CC .*bla\.' stdout && Exit 1 -grep ' CCLD .*foo' stdout && Exit 1 -grep ' CCLD .*bar' stdout && Exit 1 -grep ' CCLD .*baz' stdout && Exit 1 -grep ' CCLD .*bla' stdout && Exit 1 +# The libtool command line can contain e.g. a `--tag=CC' option. +sed 's/--tag=[^ ]*/--tag=x/g' stdout | $EGREP '(CC|LD) ' && Exit 1 $MAKE distclean diff --git a/tests/silent9.test b/tests/silent9.test index e24635480..11375f8e6 100755 --- a/tests/silent9.test +++ b/tests/silent9.test @@ -66,8 +66,7 @@ $AUTOCONF ./configure --disable-dependency-tracking --enable-silent-rules $MAKE >stdout || { cat stdout; Exit 1; } cat stdout -grep ' -c' stdout && Exit 1 -grep ' -o libfoo' stdout && Exit 1 +$EGREP ' (-c|-o)' stdout && Exit 1 grep 'mv ' stdout && Exit 1 grep ' CC .*foo\.' stdout grep ' CC .*bar\.' stdout @@ -83,14 +82,8 @@ $MAKE V=1 >stdout || { cat stdout; Exit 1; } cat stdout grep ' -c' stdout grep ' -o libfoo' stdout -grep ' CC .*foo\.' stdout && Exit 1 -grep ' CC .*bar\.' stdout && Exit 1 -grep ' CC .*baz\.' stdout && Exit 1 -grep ' CC .*bla\.' stdout && Exit 1 -grep ' CCLD .*foo' stdout && Exit 1 -grep ' CCLD .*bar' stdout && Exit 1 -grep ' CCLD .*baz' stdout && Exit 1 -grep ' CCLD .*bla' stdout && Exit 1 +# The libtool command line can contain e.g. a `--tag=CC' option. +sed 's/--tag=[^ ]*/--tag=x/g' stdout | $EGREP '(CC|LD) ' && Exit 1 $MAKE distclean