Merge branch 'maint' into 'yacc-work'
authorStefano Lattarini <stefano.lattarini@gmail.com>
Thu, 15 Dec 2011 17:41:22 +0000 (18:41 +0100)
committerStefano Lattarini <stefano.lattarini@gmail.com>
Thu, 15 Dec 2011 17:42:55 +0000 (18:42 +0100)
Extra edits:
  * tests/silent-lex.test: Provide a dummy `yywrap()' function, to
  avoid link errors on systems that doesn't provide a "lex library".
  See also commit `v1.11-546-gca0ba5d'.

Commits merged from maint (34 commits):
  readme: reference webpages for automake mailing lists
  readme: update advice about testsuite execution
  readme: don't reference the old homepage at sources.redhat.com
  hacking: some more fixlets
  * NEWS: Fix typo in 'make dist-bzip2' description.
  release: don't run "make distcheck" automatically
  hacking: update on-line documentation for stable releases only
  hacking: described release procedure applies to beta releases too
  readme: the documentation is production quality now
  hacking: tell about platform-testers mailing list
  hacking: we don't use sources.redhat.com anymore
  hacking: miscellaneous minor fixes
  dist-xz, dist-bzip2: don't hard-code -9, honor envvar settings
  news: fix typos, grammaros and suboptimal wording
  maint: sync auxiliary files from upstream
  tests: fix spurious failures due to missing 'yywrap()' function
  depcomp: spelling fix
  tests: fix 'distcheck-override-infodir.test' on Cygwin
  cosmetics: typofix in comments
  coverage: undistributed '.am' and '.m4' files are diagnosed
  coverage: required but missing '.am' and '.m4' files are diagnosed
  coverage: expose automake bug#10111 in the testsuite
  fix: regenerate doc/Makefile
  texinfo: work around Solaris 10 xpg4 shell bug in install rules
  configure: report perl version in config.log
  tests: fix spurious failure with older install-info
  maintcheck: fix spurious failure in 'color2.test'
  tests: fix spurious error in 'uninstall-fail.test' on Solaris
  tests: fix typo in 'uninstall-fail.test'
  tests: avoid a spurious failure of 'ltinit.test' MinGW
  tests: testsuite is now safe to run with dmake in parallel mode
  tests: fix spurious failures w.r.t. parallel make and colorization
  Merge branch 'fix-pr9579' into maint
  tests: fix spurious failure in 'distcheck-override-infodir.test'
  tests: avoid another failure of 'uninstall-fail.test' on Solaris

13 files changed:
1  2 
ChangeLog
NEWS
configure
configure.ac
doc/automake.texi
tests/Makefile.am
tests/Makefile.in
tests/cond35.test
tests/defs.in
tests/lex3.test
tests/silent-lex.test
tests/silent-many-gcc.test
tests/silent-many-generic.test

diff --cc ChangeLog
+++ b/ChangeLog
++2011-12-15  Stefano Lattarini  <stefano.lattarini@gmail.com>
++
++      Merge branch 'maint' into 'yacc-work'
++      * tests/silent-lex.test: Provide a dummy `yywrap()' function, to
++      avoid link errors on systems that doesn't provide a "lex library".
++      See also commit `v1.11-546-gca0ba5d'.
++
+ 2011-12-14  Stefano Lattarini  <stefano.lattarini@gmail.com>
+       readme: reference webpages for automake mailing lists
+       * README: Rationalize and reorganize the (brief) description of
+       the automake mailing lists.   In particular, instead of suggesting
+       the reader to write to the `-request' addresses to subscribe to
+       mailing lists, point him to the relevant webpages, where he can
+       also subscribe via a web form.
+ 2011-12-14  Stefano Lattarini  <stefano.lattarini@gmail.com>
+       readme: update advice about testsuite execution
+       * README: Now that the automake testsuite uses the parallel-tests
+       driver, there is no need for the user to capture the stdout of
+       "make check" to determine which tests have failed: a detailed log
+       is automatically saved into the `tests/test-suite.log' file.
+       Since we are at it, improve the wording by dropping an extra
+       "please".
+ 2011-12-14  Stefano Lattarini  <stefano.lattarini@gmail.com>
+       readme: don't reference the old homepage at sources.redhat.com
+       * README: Don't reference the old homepage at sources.redhat.com,
+       which is no longer active; reference the homepage on www.gnu.org
+       instead.  See also automake bug#10157 and bug#10248.
+       * tests/README: Likewise, and remove related extra-pedantic advice
+       about copyright papers for test cases (we'll ask for those papers
+       explicitly when we think they are warranted).
+ 2011-12-12  Stefano Lattarini  <stefano.lattarini@gmail.com>
+       hacking: some more fixlets
+       * HACKING (Release Procedure): Place the list of pre-release
+       bootstrap-and-test commands on a line of its own, so it's easy to
+       select and then paste it into a terminal window.
+       Fix the explanation of "make git-release", as, since the previous
+       change, "make git-release" would simply run "make dist" rather
+       than "make distcheck".
+       Suggestion from Jim Meyering.
+ 2011-12-12  Peter Rosin  <peda@lysator.liu.se>
+       * NEWS: Fix typo in 'make dist-bzip2' description.
+ 2011-12-10  Stefano Lattarini  <stefano.lattarini@gmail.com>
+       release: don't run "make distcheck" automatically
+       * Makefile.am (git-dist): The developers should test extensively
+       before finally creating the release tarball; so don't run "make
+       distcheck" on their behalf here; instead ...
+       * HACKING (Release procedure): ... state here that "make check"
+       and "make distcheck" should be run before calling "make git-dist".
+ 2011-12-09  Jim Meyering  <meyering@redhat.com>
+           Stefano Lattarini  <stefano.lattarini@gmail.com>
+       dist-xz, dist-bzip2: don't hard-code -9, honor envvar settings
+       Before the present change, automake-generated `dist-xz' rule used
+       a hard-coded `xz -9'.  That was a problem because on this front,
+       xz differs from gzip and bzip2.  While the latter two don't incur
+       any run-time decompression penalty for using a higher compression
+       level, specifying -9 with xz imposes a potentially fatal virtual
+       memory requirement on any client that wants to decompress your
+       tar.xz file.
+       People have complained that a tarball compressed with -9 cannot
+       be uncompressed in a low-memory environment (wrt-based embedded).
+       Hence, instead of defaulting to -9, which is useful only for very
+       large tarballs, it defaults to -e (equivalent to -6e).  This
+       limits the default memory requirements imposed on decompressors,
+       yet still gives very good compression ratios.
+       * lib/am/distdir.am (dist-xz): Do not hard-code xz's -9: that made
+       it impossible to override.  Actually don't default to -9, either,
+       since that induced inordinately large virtual memory usage when
+       merely decompressing.  Instead, use its XZ_OPT envvar, defaulting
+       to -e if not defined.  Suggested by Lasse Collin.
+       (dist, dist-all) [?XZ?]: Likewise
+       (dist-bzip2): Similarly, do not hard-code -9, but do continue to
+       use -9 by default.  Honor the BZIP2 envvar.
+       (dist, dist-all) [?BZIP2?]: Likewise
+       * NEWS: Update.
+       * doc/automake.texi (The Types of Distributions): Describe the
+       newly enabled environment variables.
+ 2011-12-09  Stefano Lattarini  <stefano.lattarini@gmail.com>
+       * NEWS: Fix typos, grammaros and suboptimal wording.
+       Reported by Jim Meyering.
+ 2011-12-07  Stefano Lattarini  <stefano.lattarini@gmail.com>
+       maint: sync auxiliary files from upstream
+       * lib/texinfo.tex: Synced from upstream, by "make fetch".
+       * lib/config.guess: Likewise.
+       * lib/config.sub: Likewise.
+ 2011-12-04  Stefano Lattarini  <stefano.lattarini@gmail.com>
+       tests: fix spurious failures due to missing 'yywrap()' function
+       The AC_PROG_LEX Autoconf macro does not diagnose a failure to find
+       the "lex library" expected to provide a `yywrap' function (function
+       which is required to link most lex-generated programs).  On the
+       contrary, when all the link attempts (i.e., with `-ll' and `-lfl')
+       fail, configure declares that no lex library is needed, and simply
+       proceeds with the configuration process -- only for the build to
+       possibly fail later, at make time.
+       This behaviour is intended; the Autoconf manual reads:
+        ``You are encouraged to use Flex in your sources, since it is
+          both more pleasant to use than plain Lex and the C source it
+          produces is portable.  In order to ensure portability, however,
+          you must either provide a function `yywrap' or, if you don't use
+          it (e.g., your scanner has no `#include'-like feature), simply
+          include a `%noyywrap' statement in the scanner's source.''
+       This AC_PROG_LEX behaviour is causing some spurious failures of
+       the Automake testsuite in environments which lack a proper library
+       providing `yywrap' (this happens for example on Fedora-based
+       systems).   The proper workaround is to simply provide a fall-back
+       implementation of `yywrap' in our lexers.
+       See also partially-overlapping commit `v1.11-871-geb147a1' (from
+       the 'testsuite-work' branch), which was motivated by similar
+       spurious failures experienced when cross-compiling.
+       From a report by Jim Meyering:
+       <http://lists.gnu.org/archive/html/automake-patches/2011-10/msg00092.html>
+       * tests/cond35.test: Provide a dummy `yywrap' function.
+       * tests/lex3.test: Likewise.
+       * tests/silent-lex-generic.test: Likewise.
+       * tests/silent-lex-gcc.test: Likewise.
+       * tests/silent-many-generic.test: Likewise.
+       * tests/silent-many-gcc.test: Likewise.
+ 2011-12-04  Paul Eggert  <eggert@cs.ucla.edu>
+       depcomp: spelling fix
+       * lib/depcomp (-h): Fix misspelling in usage diagnostic.
+ 2011-11-28  Peter Rosin  <peda@lysator.liu.se>
+       tests: fix 'distcheck-override-infodir.test' on Cygwin
+       * tests/distcheck-override-infodir.test (Makefile.am): Do not add
+       any `/' between $(DESTDIR) and the following paths.  Otherwise,
+       when $(DESTDIR) is empty, the recipes will try to access files
+       with a leading double slash, which have an implementation-defined
+       interpretation (e.g., for Cygwin, they mean UNC paths).
+ 2011-11-24  Stefano Lattarini  <stefano.lattarini@gmail.com>
+       cosmetics: typofix in comments
+       * tests/remake-am-pr10111.test (Makefile.am): Fix typo in comments.
+       * THANKS: Update.
+       Reported by Krzysztof Żelechowski.
+ 2011-11-22  Stefano Lattarini  <stefano.lattarini@gmail.com>
+       coverage: undistributed '.am' and '.m4' files are diagnosed
+       The stub rules emitted to work around the "deleted header problem"
+       for `.m4' files (included by autoconf in e.g., configure.ac) and
+       for `.am' files (included by automake in e.g., Makefile.am) should
+       not prevent "make" from correctly complaining when such a required
+       file is missing from a distribution tarball.
+       * tests/dist-missing-am.test: New test.
+       * tests/dist-missing-m4.test: Likewise.
+       * tests/dist-missing-included-m4.test: Likewise.
+       * tests/Makefile.am (TESTS): Add them.
+       Suggestion by Ralf Wildenhues.
+ 2011-11-22  Stefano Lattarini  <stefano.lattarini@gmail.com>
+       coverage: required but missing '.am' and '.m4' files are diagnosed
+       The stub rules emitted to work around the "deleted header problem"
+       for `.m4' files (included by autoconf in e.g., configure.ac) and
+       for `.am' files (included by automake in e.g., Makefile.am) should
+       not prevent the remake rules from correctly erroring out when a
+       still-required file is missing.
+       * tests/deleted-am.test: New test.
+       * tests/deleted-m4.test: Likewise.
+       * tests/Makefile.am (TESTS): Add them.
+ 2011-11-22  Stefano Lattarini  <stefano.lattarini@gmail.com>
+       coverage: expose automake bug#10111 in the testsuite
+       * tests/remake-am-pr10111.test: New test, xfailing.
+       * tests/remake-m4-pr10111.test: Likewise.
+       * tests/Makefile.am (TESTS, XFAIL_TESTS): Add them.
+ 2011-11-19  Stefano Lattarini  <stefano.lattarini@gmail.com>
+       texinfo: work around Solaris 10 xpg4 shell bug in install rules
+       * lib/am/texinfos.am (install-html-am): Use an extra variable
+       indirection to work around a bug in Solaris 10 /usr/xpg4/bin/sh.
+       Bug revealed by a failure of `txinfo21.test'.  See also:
+       <http://lists.gnu.org/archive/html/bug-autoconf/2011-11/msg00005.html>
+       <http://debbugs.gnu.org/cgi/bugreport.cgi?bug=10026#23>
+ 2011-11-17  Stefano Lattarini  <stefano.lattarini@gmail.com>
+       configure: report perl version in config.log
+       * configure.ac: Report the version of the selected perl interpreter
+       in config.log; this should render the logs more informative.
+ 2011-11-13  Stefano Lattarini  <stefano.lattarini@gmail.com>
+       tests: fix spurious failure with older install-info
+       * tests/install-info-dir.test (foo.texi): Also add proper
+       `@settitle', `@dircategory' and `@direntry' directive, otherwise
+       older versions of `install-info' (e.g., 4.8) will fail to create
+       the `dir' index file in ${infodir}.
+       Problem revealed by a failure on NetBSD 5.1.
+ 2011-11-12  Stefano Lattarini  <stefano.lattarini@gmail.com>
+       maintcheck: fix spurious failure in 'color2.test'
+       * tests/color2.test: Avoid creative quoting to avoid a spurious
+       failure of the `sc_tests_Exit_not_exit' maintainer check.
+ 2011-11-12  Stefano Lattarini  <stefano.lattarini@gmail.com>
+       tests: fix spurious error in 'uninstall-fail.test' on Solaris
+       * tests/uninstall-fail.test: Solaris 10 /usr/xpg4/bin/sh can add
+       a line number before the `:' in the error messages issued by shell
+       builtins.  Account for that in our grepping of make output.
+ 2011-11-12  Stefano Lattarini  <stefano.lattarini@gmail.com>
+       tests: fix typo in 'uninstall-fail.test'
+       * tests/uninstall-fail.test: Always use `$rm_f_is_silent_on_error'
+       instead of the bogus `$rm_f_is_silent_on_failure'.
+ 2011-11-10  Stefano Lattarini  <stefano.lattarini@gmail.com>
+       tests: avoid a spurious failure of 'ltinit.test' MinGW
+       * tests/ltinit.test: Be laxer in grepping configure output, to
+       avoid spurious failures on systems which lack POSIX dynamic
+       linking (e.g., MinGW), or when cross-compiling for such systems.
+       See also commit `v1.11-855-ge9e5d4a'.
+       Report and suggestion from Peter Rosin.
+ 2011-11-08  Stefano Lattarini  <stefano.lattarini@gmail.com>
+       tests: testsuite is now safe to run with dmake in parallel mode
+       * tests/defs.in: Unset variables DMAKE_CHILD, DMAKE_DEF_PRINTED
+       and DMAKE_MAX_JOBS, which are exported by Solaris dmake when run
+       in parallel mode, and which might confuse make processes spawned
+       by our testsuite.
+ 2011-11-08  Stefano Lattarini  <stefano.lattarini@gmail.com>
+       tests: fix spurious failures w.r.t. parallel make and colorization
+       * tests/color2.test: Skip the test if the $MAKE program fails to
+       consider the standard output as a tty when spawned by `expect'.
+       This is required for make implementations, like FreeBSD make and
+       Solaris dmake, that redirect the output of recipes to temporary
+       files or pipes when run in parallel mode.  Since we are at it,
+       simplify the detection of a working `expect' program, and throw
+       in other minor simplifications.
+ 2011-11-07  Stefano Lattarini  <stefano.lattarini@gmail.com>
+       tests: fix spurious failure in 'distcheck-override-infodir.test'
+       * tests/distcheck-override-infodir.test ($required): Add
+       'install-info'.
+ 2011-11-07  Stefano Lattarini  <stefano.lattarini@gmail.com>
+       tests: avoid another failure of 'uninstall-fail.test' on Solaris
+       * tests/uninstall-fail.test: On Solaris 10, if `/bin/rm' is run
+       with the `-f' option, it doesn't print any error message when
+       failing to remove a file (due to e.g., "Permission denied").
+       Yikes.  Cater to this incompatibility, by relaxing the test when
+       a faulty `rm' is detected.
  2011-11-03  Zack Weinberg <zackw@panix.com>  (tiny change)
            Stefano Lattarini  <stefano.lattarini@gmail.com>
  
diff --cc NEWS
--- 1/NEWS
--- 2/NEWS
+++ b/NEWS
@@@ -130,23 -119,14 +133,23 @@@ Bugs fixed in 1.11.0a
      make bug triggered by sources containing repeated slashes when the
      `subdir-objects' option was used.
  
-   - The parallel-tests driver now does not produce erroneous results
-     with Tru64/OSF 5.1 sh upon unreadable log files any more.
+   - The parallel-tests driver no longer produces erroneous results with
+     Tru64/OSF 5.1 sh upon unreadable log files.
  
-   - The makedepend and hp depmodes now works better with VPATH builds.
+   - The makedepend and hp depmodes now work better with VPATH builds.
  
-   - Java sources specified with check_JAVA are not compiled anymore upon
-     "make all", but only upon "make check".
+   - Java sources specified with check_JAVA are no longer compiled for
+     "make all", but only for "make check".
  
 +  - Automake now detects the presence of the `-d' flag in the various
 +    `*YFLAGS' variables even when their definitions involve indirections
 +    through other variables, such as in:
 +      foo_opts = -d
 +      AM_YFLAGS = $(foo_opts)
 +
 +  - Automake now complains if a `*YFLAGS' variable has any conditional
 +    content, not only a conditional definition.
 +
    - An usage like "java_JAVA = foo.java" will now cause Automake to warn
      and error out if `javadir' is undefined, instead of silently producing
      a broken Makefile.in.
diff --cc configure
Simple merge
diff --cc configure.ac
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
diff --cc tests/defs.in
Simple merge
diff --cc tests/lex3.test
@@@ -44,15 -52,21 +44,21 @@@ cat > foo.l << 'END
  int
  main ()
  {
 -  while (yylex () != EOF)
 -    ;
 -
 -  return 0;
 +  /* We don't use a 'while' loop here (like a real lexer would do)
 +     to avoid possible hangs. */
 +  if (yylex () == EOF)
 +    return 0;
 +  else
 +    return 1;
  }
+ /* Avoid possible link errors. */
+ int yywrap (void)
+ {
+   return 1;
+ }
  END
  
 -set -e
 -
  $ACLOCAL
  $AUTOCONF
  $AUTOMAKE -a
index 23863d3,0000000..ce1dc5b
mode 100755,000000..100755
--- /dev/null
@@@ -1,135 -1,0 +1,138 @@@
 +#!/bin/sh
 +# Copyright (C) 2010, 2011 Free Software Foundation, Inc.
 +#
 +# This program is free software; you can redistribute it and/or modify
 +# it under the terms of the GNU General Public License as published by
 +# the Free Software Foundation; either version 2, or (at your option)
 +# any later version.
 +#
 +# This program is distributed in the hope that it will be useful,
 +# but WITHOUT ANY WARRANTY; without even the implied warranty of
 +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 +# GNU General Public License for more details.
 +#
 +# You should have received a copy of the GNU General Public License
 +# along with this program.  If not, see <http://www.gnu.org/licenses/>.
 +
 +# Check silent-rules mode for Lex.
 +
 +required=lex
 +. ./defs || Exit 1
 +
 +set -e
 +
 +mkdir sub
 +
 +cat >>configure.in <<'EOF'
 +AM_SILENT_RULES
 +AM_PROG_CC_C_O
 +AC_PROG_LEX
 +AC_CONFIG_FILES([sub/Makefile])
 +AC_OUTPUT
 +EOF
 +
 +cat > Makefile.am <<'EOF'
 +# Need generic and non-generic rules.
 +bin_PROGRAMS = foo1 foo2
 +foo1_SOURCES = foo.l
 +foo2_SOURCES = $(foo1_SOURCES)
 +foo2_LFLAGS = -n
 +foo2_CFLAGS = $(AM_CFLAGS)
 +SUBDIRS = sub
 +LDADD = $(LEXLIB)
 +EOF
 +
 +cat > sub/Makefile.am <<'EOF'
 +AUTOMAKE_OPTIONS = subdir-objects
 +# Need generic and non-generic rules.
 +bin_PROGRAMS = bar1 bar2
 +bar1_SOURCES = bar.l
 +bar2_SOURCES = $(bar1_SOURCES)
 +bar2_LFLAGS = -n
 +bar2_CFLAGS = $(AM_CFLAGS)
 +LDADD = $(LEXLIB)
 +EOF
 +
 +cat > foo.l <<'EOF'
 +%%
 +"END"   return EOF;
 +.
 +%%
++/* Avoid possible link errors. */
++int yywrap (void) { return 1; }
++int   main (void) { return 0; }
 +EOF
 +cp foo.l sub/bar.l
 +
 +$ACLOCAL
 +$AUTOMAKE --add-missing
 +$AUTOCONF
 +
 +# Ensure per-target rules are used, to ensure their coverage below.
 +$FGREP 'foo2-foo.c' Makefile.in || Exit 99
 +$FGREP 'bar2-bar.c' sub/Makefile.in || Exit 99
 +
 +./configure --enable-silent-rules
 +
 +$MAKE >stdout || { cat stdout; Exit 1; }
 +cat stdout
 +
 +$EGREP ' (-c|-o)' stdout && Exit 1
 +$EGREP '(mv|ylwrap) ' stdout && Exit 1
 +
 +grep 'LEX .*foo\.' stdout
 +grep 'LEX .*bar\.' stdout
 +grep ' CC .*foo\.' stdout
 +grep ' CC .*bar\.' stdout
 +grep 'CCLD .*foo1' stdout
 +grep 'CCLD .*bar1' stdout
 +grep 'CCLD .*foo2' stdout
 +grep 'CCLD .*bar2' stdout
 +
 +# Cleaning and then rebuilding with the same V flag (and without
 +# removing the generated sources in between) shouldn't trigger a
 +# different set of rules.
 +$MAKE clean
 +
 +$MAKE >stdout || { cat stdout; Exit 1; }
 +cat stdout
 +
 +$EGREP ' (-c|-o)' stdout && Exit 1
 +$EGREP '(mv|ylwrap) ' stdout && Exit 1
 +
 +# Don't look for LEX, as probably lex hasn't been re-run.
 +grep ' CC .*foo\.' stdout
 +grep ' CC .*bar\.' stdout
 +grep 'CCLD .*foo1' stdout
 +grep 'CCLD .*bar1' stdout
 +grep 'CCLD .*foo2' stdout
 +grep 'CCLD .*bar2' stdout
 +
 +# Ensure a truly clean rebuild.
 +$MAKE clean
 +rm -f *foo.c sub/*bar.c
 +
 +$MAKE V=1 >stdout || { cat stdout; Exit 1; }
 +cat stdout
 +
 +grep ' -c ' stdout
 +grep ' -o ' stdout
 +grep 'ylwrap ' stdout
 +
 +$EGREP '(LEX|CC|CCLD) ' stdout && Exit 1
 +
 +# Cleaning and then rebuilding with the same V flag (and without
 +# removing the generated sources in between) shouldn't trigger a
 +# different set of rules.
 +$MAKE clean
 +
 +$MAKE V=1 >stdout || { cat stdout; Exit 1; }
 +cat stdout
 +
 +# Don't look for ylwrap, as probably lex hasn't been re-run.
 +grep ' -c ' stdout
 +grep ' -o ' stdout
 +
 +$EGREP '(LEX|CC|CCLD) ' stdout && Exit 1
 +
 +:
@@@ -185,15 -187,9 +190,15 @@@ $ACLOCA
  $AUTOMAKE --add-missing
  $AUTOCONF
  
 +# Ensure per-target rules are used, to ensure their coverage below.
 +# (We do not do an exhaustive check, that wouldn't be practical).
 +$FGREP 'bar-bar.o' Makefile.in
 +$FGREP 'fo2-foo5.c' Makefile.in
 +$FGREP 'fo2-foo6.c' Makefile.in
 +
  # Force gcc ("fast") depmode.
  # This apparently useless "for" loop is here to simplify the syncing
- # with sister test `silent-many-gcc.test'.
+ # with sister test `silent-many-generic.test'.
  for config_args in \
    am_cv_CC_dependencies_compiler_type=gcc
  do
Simple merge