* tests/location.test (Makefile.am): Strengthen.
authorAkim Demaille <akim@epita.fr>
Thu, 31 Oct 2002 11:55:27 +0000 (11:55 +0000)
committerAkim Demaille <akim@epita.fr>
Thu, 31 Oct 2002 11:55:27 +0000 (11:55 +0000)
* lib/Automake/Channels.pm (_print_message): Be sure to flush
$partial when the message is output.
Thanks to Alexandre Duret-Lutz.

ChangeLog
lib/Automake/Channels.pm
tests/location.test

index 74b820e..c48ecb6 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,12 @@
 2002-10-31  Akim Demaille  <akim@epita.fr>
 
+       * tests/location.test (Makefile.am): Strengthen.
+       * lib/Automake/Channels.pm (_print_message): Be sure to flush
+       $partial when the message is output.
+       Thanks to Alexandre Duret-Lutz.
+
+2002-10-31  Akim Demaille  <akim@epita.fr>
+
        * automake.in (&read_am_file): Use $last_where to register the
        _first_ line of a variable definition as location instead of the
        last one.
index 37201e8..eaeed1c 100644 (file)
@@ -421,6 +421,7 @@ sub _print_message ($$%)
     {
       # Prefix with any partial message send so far.
       $msg = $partial . $msg;
+      $partial = '';
     }
 
   # Check for duplicate message if requested.
index ad97f3c..7cb5052 100755 (executable)
@@ -51,10 +51,28 @@ END
 $ACLOCAL
 $AUTOMAKE 2>stderr && exit 1
 cat stderr
-grep 'Makefile\.am:1:.*program.*libfoo\.a' stderr
-grep 'Makefile\.am:3:.*library.*libfoo\.a' stderr
-grep 'Makefile\.am:6:.*program.*ctags' stderr
-grep 'redefinition of.*libfoo\.a' stderr
-grep 'redefinition of.*ctags' stderr
-grep 'Makefile.am:12: VAR multiply defined in condition TRUE' stderr
-grep 'Makefile.am:8: ... .VAR. previously defined here' stderr
+
+# Smash the useless difference of lib file locations.
+sed 's,^.*lib/am/\([a-z]*\.am\),\1,' stderr >observed
+cat >expected <<\EOF
+Makefile.am:12: VAR multiply defined in condition TRUE ...
+Makefile.am:8: ... `VAR' previously defined here
+automake: libfoo_a_OBJECTS should not be defined
+Makefile.am:3:   while processing library `libfoo.a'
+automake: use `libfoo_a_LDADD', not `libfoo_a_LIBADD'
+Makefile.am:3:   while processing library `libfoo.a'
+library.am: deprecated feature: target `libfoo.a' overrides `libfoo.a$(EXEEXT)'
+library.am: change your target to read `libfoo.a$(EXEEXT)'
+Makefile.am:3:   while processing library `libfoo.a'
+program.am: target `libfoo.a$(EXEEXT)' was defined here
+Makefile.am:1:   while processing program `libfoo.a'
+program.am: redefinition of `libfoo.a' in condition `TRUE'...
+Makefile.am:1:   while processing program `libfoo.a'
+library.am: ... `libfoo.a' previously defined here
+Makefile.am:3:   while processing library `libfoo.a'
+tags.am: redefinition of `ctags' in condition `TRUE'...
+program.am: ... `ctags' previously defined here
+Makefile.am:6:   while processing program `ctags'
+EOF
+
+diff expected observed || exit 1