Merge branch 'maint'
authorRalf Wildenhues <Ralf.Wildenhues@gmx.de>
Sun, 11 Apr 2010 18:04:01 +0000 (20:04 +0200)
committerRalf Wildenhues <Ralf.Wildenhues@gmx.de>
Sun, 11 Apr 2010 18:04:01 +0000 (20:04 +0200)
74 files changed:
.gitignore
ChangeLog
ChangeLog.09
HACKING
Makefile.am
Makefile.in
NEWS
THANKS
aclocal.m4
automake.in [changed mode: 0755->0644]
configure
configure.ac
doc/Makefile.am
doc/Makefile.in
doc/automake.texi
lib/Automake/ChannelDefs.pm
lib/Automake/Condition.pm
lib/Automake/Configure_ac.pm
lib/Automake/Location.pm
lib/Automake/Makefile.am
lib/Automake/Makefile.in
lib/Automake/Options.pm
lib/Automake/RuleDef.pm
lib/Automake/VarDef.pm
lib/Automake/Variable.pm
lib/Automake/Wrap.pm
lib/Automake/XFile.pm
lib/Automake/tests/Cond2.pl [new file with mode: 0644]
lib/Automake/tests/Cond3.pl [new file with mode: 0644]
lib/Automake/tests/Condition-t.pl
lib/Automake/tests/Condition.pl
lib/Automake/tests/DisjCon2.pl [new file with mode: 0644]
lib/Automake/tests/DisjCon3.pl [new file with mode: 0644]
lib/Automake/tests/DisjConditions-t.pl
lib/Automake/tests/DisjConditions.pl
lib/Automake/tests/Makefile.am
lib/Automake/tests/Makefile.in
lib/Automake/tests/Version.pl
lib/Automake/tests/Version2.pl [new file with mode: 0644]
lib/Automake/tests/Version3.pl [new file with mode: 0644]
lib/Automake/tests/Wrap.pl
lib/Makefile.in
lib/am/Makefile.in
lib/am/depend2.am
lib/am/distdir.am
lib/am/tags.am
lib/am/texibuild.am
lib/am/texinfos.am
m4/Makefile.in
m4/amversion.m4
m4/depend.m4
tests/.gitignore
tests/Makefile.am
tests/Makefile.in
tests/README
tests/candist.test [new file with mode: 0755]
tests/cond46.test [new file with mode: 0755]
tests/condinc2.test
tests/cscope.test [new file with mode: 0755]
tests/cscope2.test [new file with mode: 0755]
tests/cscope3.test [new file with mode: 0755]
tests/defs.in
tests/ext3.test [new file with mode: 0755]
tests/extra9.test [new file with mode: 0755]
tests/link_override.test [new file with mode: 0755]
tests/lzip.test [new file with mode: 0755]
tests/parallel-am.test
tests/parallel-am2.test
tests/parallel-am3.test
tests/silent4.test
tests/silent5.test
tests/silent8.test [new file with mode: 0755]
tests/silent9.test [new file with mode: 0755]
tests/subst5.test [new file with mode: 0755]

index 81e5a98..716ef8b 100644 (file)
@@ -7,5 +7,9 @@ config.log
 config.status
 config.status.lineno
 configure.lineno
+cscope.files
+cscope.in.out
+cscope.out
+cscope.po.out
 tags
 TAGS
index 6423875..19b7772 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
        * NEWS, THANKS: Update.
        Report by Pavel Sanda.
 
+2010-04-11  Stefano Lattarini  <stefano.lattarini@gmail.com>
+
+       Avoid possible false negatives in cond46.test.
+       * tests/cond46.test: Enable shell `errexit' flag (and bumped
+       copyright years).  Due to this change, the testcase should now
+       fail on unexpected failures in calls to $ACLOCAL/$AUTOMAKE (whose
+       outcomes were previously unchecked), and on failures in grepping
+       the expected diagnostic in Automake stderr.
+
+2010-04-04  Stefano Lattarini  <stefano.lattarini@gmail.com>
+
+       Generated tests are now just a thin layer around other tests.
+       * tests/Makefile.am: Rewrite the rule to generate the `*-p.test'
+       test scripts so that any of them simply includes the corresponding
+       `*.test' script (after setting `$parallel_tests' to `yes').
+       * tests/.gitignore: Add wildcard for temporary files used in the
+       generation of `*-p.test' tests.
+
 2010-03-30  Stefano Lattarini  <stefano.lattarini@gmail.com>
 
        Avoid an unportable use of `$status' shell variable.
        * tests/parallel-tests6.test: Likewise.
        * tests/parallel-tests7.test: Likewise.
 
+2010-03-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
+
+       Fix cscope test on systems without working Fortran compiler.
+       * tests/cscope.test: Skip remainder of test if `$MAKE all' fails.
+       * THANKS: Update.
+       Report by Peter Johansson.
+
+2010-02-24  Antonio Diaz Diaz  <ant_diaz@teleline.es>  (tiny change)
+           Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
+
+       Add lzip compression support.
+       * automake.in (handle_dist): Recognize dist-lzip.
+       (make_paragraphs): Map LZIP to dist-lzip.
+       * doc/automake.texi (Dist): Add dist-lzip.
+       (Options): Likewise.
+       * lib/Automake/Options.pm (_process_option_list): Add dist-lzip.
+       * lib/am/distdir.am
+       (dist dist-all): Add command to create an lzip-compressed tarball.
+       (distcheck): Handle lzip-compressed tarballs just like the others.
+       * tests/defs.in: Test for lzip, too.
+       * tests/lzip.test: New file, based on nogzip.test.
+       * tests/Makefile.am (TESTS): Add lzip.test.
+       * NEWS: Update.
+
 2010-02-22  Karl Berry  <karl@gnu.org>
 
        Improve help message of mdate-sh.
        Fix some typos in the manual
        * doc/automake.texi (Nested Packages, Rebuilding): Fix typos.
 
+2010-01-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
+
+       Fix silent-rules output for disabled dependency tracking.
+       * lib/am/depend2.am [!%FASTDEP%]: Rework silent-rules variable
+       expansion code to also work in the case where %AMDEP% expands
+       to FALSE at config.status time, using new substitution string
+       %VERBOSE-NODEP%.
+       * automake.in (verbose_nodep_flag): New function, appending
+       `@am__nodep@' to the verbose-variable name.
+       (handle_languages): If dependencies are not disabled, use it to
+       set %VERBOSE-NODEP%.
+       * m4/depend.m4: Substitute am__nodep as '_no', so the second
+       verbose-variable will always expand to an empty string, if
+       dependencies are enabled.
+       * tests/silent5.test: Also test --disable-dependency-tracking;
+       also test per-target flags for non-C language files.
+       * tests/silent9.test: New test, like silent4.test but disable
+       dependency tracking.
+       * tests/Makefile.am: Adjust.
+       * NEWS, THANKS: Update.
+       Report by Dmitry V. Levin <ldv@altlinux.org>.
+
 2010-01-17  Stefano Lattarini  <stefano.lattarini@gmail.com>
 
        Slighty improve tests acoutbs.test and acoutbs2.test.
index 063c06b..7b07c36 100644 (file)
        * lib/gnupload: Mention ncftpput in `--help' output.
        Report by Bruce Korb.
 
+2009-12-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
+
+       * NEWS: Update.
+
 2009-12-05  Antonio Diaz Diaz  <ant_diaz@teleline.es>
 
        Replace unlzma, gunzip, bunzip2 with pack tool -d invocation.
        current directory.  Use it instead of `pwd` command substitution,
        to avoid Heirloom/Solaris Sh bug with `set -e'.
 
+2009-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
+
+       Fix requirements of silent8.test.
+       * tests/silent8.test: Require makeinfo --html, tex, texi2dvi -o,
+       dvips.
+
+2009-12-04  Stefano Lattarini  <stefano.lattarini@gmail.com>
+
+       File `automake.in' is not meant to be executed (only to be
+       preprocessed into `automake'), so don't leave it executable.
+       * automake.in: Remove executable bit.
+
+2009-12-04  Stefano Lattarini  <stefano.lattarini@gmail.com>
+
+       Don't make the generated Automake's Config.pm executable.
+       * lib/Automake/Makefile.am (Config.pm): Don't make the generated
+       `Config.pm' file executable.
+
 2009-11-28  Jim Meyering  <meyering@redhat.com>
 
        do not put world-writable directories in distribution tarballs
        * Makefile.am (EXTRA_DIST): Add bootstrap.
        Report by Jan Engelhardt.
 
+2009-11-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
+
+       Coverage for corner cases in derive_suffix.
+       Ensure unrelatex SUFFIXES entries and unrelated inference rules
+       are ignored silently.
+       * tests/ext3.test: New test.
+       * tests/Makefile.am: Update.
+
+       Coverage for user-provided _LINK variables.
+       * tests/link_override.test: New test.
+       * tests/Makefile.am: Adjust.
+
+       Coverage: warn about substitutions that need EXTRA_PRIMARY.
+       * tests/extra9.test: New test.
+       * tests/Makefile.am: Adjust.
+
+       Coverage: warn about configure substitution in EXTRA_PRIMARY.
+       * tests/subst5.test: New test.
+       * tests/Makefile.am: Update.
+
+       Coverage for syntax errors with conditionals in included fragments.
+       * tests/condinc2.test: Amend test.
+
+       Coverage: diagnose variables with forbidden dist_ prefix.
+       * tests/candist.test: New test.
+       * tests/Makefile.am: Update.
+
+       Coverage for conditional `else' and `endif' arguments.
+       * tests/cond46.test: New test.
+       * tests/Makefile.am: Update.
+
 2009-10-31  Jim Meyering  <meyering@redhat.com>
            Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
 
        * tests/subdir10.test: New test.
        * tests/Makefile.am: Update.
 
+2009-10-18  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
+
+       Simplify Variable::_check_ambiguous_condition.
+       * lib/Automake/Variable.pm (_check_ambiguous_condition): No need
+       to check for $def since ambiguous_p returns an empty $message if
+       there is no other condition which is ambiguous to $cond.
+
+       Coverage for DisjConditions.pm.
+       * lib/Automake/tests/DisjConditions.pl (test_basics): Increase
+       test coverage: test ->human, ->merge, ->simplify, ->multiply.
+       * lib/Automake/tests/DisjConditions-t.pl (test_basics): Likewise
+       changes, but including state copies across thread creation.
+       * lib/Automake/tests/DisjCon2.pl: New test.
+       * lib/Automake/tests/DisjCon3.pl: Likewise.
+       * lib/Automake/tests/Makefile.am (TESTS, XFAIL_TESTS): Adjust.
+
+       Coverage and fixes for Condition.pm.
+       * lib/Automake/Condition.pm (new): Catch common programming
+       errors better by checking type of passed argument before
+       munging them to all be strings through split.
+       * lib/Automake/tests/Condition.pl (test_basics): Also test
+       ->human.
+       (test_merge): New function, test ->merge, ->merge_conds,
+       ->strip.
+       * lib/Automake/tests/Condition-t.pl (test_basics, test_merge):
+       Likewise changes, but including state copies across thread
+       creation.
+       * lib/Automake/tests/Cond2.pl: New test for programming error.
+       * lib/Automake/tests/Cond3.pl: Likewise.
+       * lib/Automake/tests/Makefile.am (TESTS, XFAIL_TESTS): Update.
+
+       Coverage for Wrap.pm.
+       * lib/Automake/tests/Wrap.pl (@tests): Add test for word with
+       trailing space.
+       (test_makefile_wrap, @makefile_tests): New function, new list of
+       tests, to test makefile_wrap.
+
+       Coverage for Version.pm.
+       * lib/Automake/tests/Version.pl (test_version_compare): Also
+       try Automake::Version::check for the version pairs, taking into
+       account the special-case naming of code forks.
+       (@tests): Add more test cases.
+       (test_bad_versions, @bad_versions): New function, new test cases,
+       to ensure bad version strings are rejected.
+       * lib/Automake/tests/Version2.pl: New test.
+       * lib/Automake/tests/Version3.pl: Likewise.
+       * lib/Automake/tests/Makefile.am (TESTS): Add tests here ...
+       (XFAIL_TESTS): ... and here, new.
+
+       Pod coverage for Perl modules.
+       * lib/Automake/ChannelDefs.pm (parse_warnings): Fix
+       typo in Pod documentation.
+       * lib/Automake/Condition.pm: Add a couple of missing `=back'
+       lines.
+       (_has): Renamed from ...
+       (has): ... this, as this is an internal method.
+       (strip, false, true_when): Adjust callers.
+       * lib/Automake/Configure_ac.pm: Add Pod `Functions' section with
+       documentation for find_configure_ac and require_configure_ac.
+       * lib/Automake/Location.pm: Fix typo in Pod.  Add `Methods'
+       section, document methods.
+       * lib/Automake/RuleDef.pm: New `Methods' Pod section.
+       * lib/Automake/VarDef.pm: Document `raw_value'.
+       * lib/Automake/Wrap.pm (_tab_length): Rename from ...
+       (tab_length): ... this, as this is an internal method.
+       (wrap): Adjust callers.
+       * lib/Automake/XFile.pm: Reorganize Pod a bit, add `Methods'
+       section.
+
 2009-10-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
 
+       Perl coverage support using Devel::Cover.
+       This introduces makefile rules to run the testsuite with Perl
+       coverage enabled.  It skips tests that use perl ithreads, by
+       unsetting AUTOMAKE_JOBS and setting WANT_NO_THREADS to make the
+       threaded tests skip.
+       * Makefile.am (PERL_COVERAGE_DB, PERL_COVERAGE_FLAGS)
+       (PERL_COVER): New variables.
+       (check-coverage, recheck-coverage, clean-coverage): New phony
+       targets.
+       (check-coverage-run, recheck-coverage-run): New phony helper
+       targets.
+       (clean-local): New, depend on clean-coverage.
+       * lib/Automake/tests/Condition-t.pl: Skip if WANT_NO_THREADS is
+       set.
+       * lib/Automake/tests/DisjConditions-t.pl: Likewise.
+       * tests/defs.in: New required entry 'perl-threads'.
+       * tests/parallel-am.test: Use it to skip if WANT_NO_THREADS is
+       set.
+       * tests/parallel-am2.test: Likewise.
+       * tests/parallel-am3.test: Likewise.
+
+       Add convenience `recheck' target to our toplevel Makefile.am.
+       * Makefile.am (recheck): New convenience target.
+       * tests/README: Give examples for running only failed or
+       outdated or otherwise selected tests.
+
+       dist: allow running several compressors in parallel.
+       * lib/am/distdir.am (am__post_remove_distdir): New internal
+       variable.
+       (DIST_TARGETS): New variable, set to list of chosen distribution
+       formats.  Order formats by expected duration, slowest first, for
+       better parallelism.
+       (dist-gzip, dist-bzip2, dist-lzma, dist-xz, dist-tarZ)
+       (dist-shar, dist-zip): Use $(am__post_remove_distdir).
+       (dist, dist-all): Do not depend on distdir.  Instead of
+       replicating each compression command, use a recursive invocation
+       to allow running all $(DIST_TARGETS) in parallel.
+       * NEWS: Update.
+       Report by Peter Breitenlohner.
+
+       Fix license headers of cscope tests to be GPLv2+.
+       * tests/cscope.test: Revert to GPL version 2.
+       * tests/cscope2.test: Likewise.
+       * tests/cscope3.test: Likewise.
+
        Sync auxiliary files from upstream.
        * INSTALL, lib/INSTALL, lib/config.guess, lib/config.sub,
        lib/texinfo.tex: Sync from upstream.
        `--no-function-argzero', since the latter does not work with
        versions 3.x of Zsh.
 
+2009-09-26  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
+
+       Fixups and tests for cscope functionality.
+       It seems cscope is not able to take into account relative
+       file names of included cscope.files files, but it is able to
+       canonicalize file names containing '../' sequences.
+       This patch makes the cscope references relative again, and
+       fixes some corner cases.
+       * NEWS: Reword a bit.
+       * THANKS: Update.
+       * automake.in (handle_tags): Use $(am__cd).  Provide default
+       empty rule for the `cscope' target, for empty sources.
+       * lib/am/tags.am (cscopelist): Construct relative path to files
+       in $(srcdir) if $(srcdir) is relative.
+       [TOPDIR_P] (cscope): Do not depend on cscope-clean.  Only invoke
+       $(CSCOPE) if cscope.files is nonemtpy.
+       (clean-cscope): Rename from ...
+       (cscopeclean): ... this.
+       (cscope.files): Depend on clean-cscope.
+       (distclean-tags) [!TOPDIR_P]: No need to remove cscope files
+       here.
+       * tests/cscope.test, tests/cscope2.test, tests/cscope3.test: New
+       tests.
+       * tests/Makefile.am: Adjust.
+
+2009-09-25  Debarshi Ray  <rishi@gnu.org>
+
+       New target to generate cscope database.
+       * automake.in (handle_tags): Handle cscope.
+       * doc/automake.texi (Tags): Document cscope.
+       * lib/am/tags.am (CSCOPE): New macro.
+       [TOPDIR_P] (AM_RECURSIVE_TARGETS): Add cscope.
+       (cscope): New target.
+       (cscopeclean): Likewise.
+       (cscope.files): Likewise.
+       (cscopelist): Likewise.
+       (distclean-tags): Remove `cscope.out', `cscope.in.out',
+       `cscope.po.out' and `cscope.files'.
+       * NEWS: Update.
+       Based upon earlier patch from Jesse Barnes.
+
+2009-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
+
+       Use silent-rules for building the Automake package.
+       * configure.ac (AM_INIT_AUTOMAKE): Add silent-rules option.
+       * Makefile.am (automake, aclocal, INSTALL): Add silencing
+       variables to recipe.
+       * doc/Makefile.am (update_mans, $(srcdir)/aclocal.1)
+       ($(srcdir)/automake.1, $(srcdir)/amhello-1.0.tar.gz): Likewise.
+       * lib/Automake/Makefile.am (Config.pm): Likewise.
+       * tests/Makefile.am ($(srcdir)/parallel-tests.am)
+       ($(parallel_tests), defs-p): Likewise.
+
+2009-09-25  Jack Kelly  <endgame.dos@gmail.com>
+
+       Add silent rules support for texinfo outputs.
+       * automake.in (define_verbose_texinfo): Define several new verbose
+       tagvars and verbose vars.
+       (define_verbose_tagvar): Increase spacing to 8 to accommodate
+       MAKEINFO, TEXI2DVI, TEXI2PDF.
+       (handle_texinfo): Additional substitution for silencing dvips.
+       (output_texinfo_build_rules): Additional substitutions for
+       silencing texi2dvi and texi2pdf.
+       * lib/am/texibuild.am: Add silencing to makeinfo, makeinfo --html,
+       texi2dvi and texi2pdf rules.
+       * lib/am/texinfos.am: Add silencing to .dvi.ps rule.
+       * tests/Makefile.am: Add silent8.test.
+       * tests/silent8.test: New test: tests that silent texinfo rules
+       produce quiet messages.
+       * NEWS: Update.
+
 2009-09-18  Peter Johansson  <trojkan@gmail.com>  (tiny change)
 
        Fix link to "Recursive Make Considered Harmful" paper.
 
 2009-05-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
 
+       Post-release version bump.
+       * configure.ac, NEWS: Bump version to 1.11a.
+
+2009-05-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
+
        Automake 1.11.
        * configure.ac: Bump version to 1.11.
        * doc/automake.texi (Releases): Add line for 1.11.  Remove line
diff --git a/HACKING b/HACKING
index ee85917..fd9f031 100644 (file)
--- a/HACKING
+++ b/HACKING
 * Use `keep_testdirs=yes' to keep test directories for successful
   tests also.
 
+* Use perl coverage information to ensure your new code is thoroughly
+  tested by your new tests.
+
 ================================================================
 = Release procedure
 
index c487874..6c24285 100644 (file)
@@ -84,17 +84,34 @@ do_subst = sed \
 automake: automake.in
 aclocal: aclocal.in
 automake aclocal: Makefile
-       rm -f $@ $@.tmp
-       $(do_subst) $(srcdir)/$@.in >$@.tmp
-       chmod +x $@.tmp
-       chmod a-w $@.tmp
-       mv -f $@.tmp $@
+       $(AM_V_GEN)rm -f $@ $@.tmp
+       $(AM_V_at)$(do_subst) $(srcdir)/$@.in >$@.tmp
+       $(AM_V_at)chmod +x $@.tmp
+       $(AM_V_at)chmod a-w $@.tmp
+       $(AM_V_at)mv -f $@.tmp $@
 
 ## The master location for INSTALL is lib/INSTALL.
 ## This is where `make fetch' will install new versions.
 ## Make sure we also update this copy.
 INSTALL: lib/INSTALL
-       cp $(srcdir)/lib/INSTALL $@
+       $(AM_V_GEN)cp $(srcdir)/lib/INSTALL $@
+
+## recheck: convenience proxy target for the test suites.
+TEST_SUBDIRS = lib/Automake/tests tests
+
+.PHONY: recheck
+recheck:
+       @failcom='exit 1'; \
+       for f in x $$MAKEFLAGS; do \
+         case $$f in \
+           *=* | --[!k]*);; \
+           *k*) failcom='fail=yes';; \
+         esac; \
+       done; \
+       for subdir in $(TEST_SUBDIRS); do \
+         (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $@) || eval $$failcom; \
+       done; \
+       test -z "$$fail"
 
 ################################################################
 ##
@@ -106,6 +123,41 @@ INSTALL: lib/INSTALL
 dist-hook:
        cd $(distdir)/tests && chmod a+rx *.test
 
+
+# Perl coverage statistics.
+PERL_COVERAGE_DB = $(abs_top_builddir)/cover_db
+PERL_COVERAGE_FLAGS = -MDevel::Cover=-db,$(PERL_COVERAGE_DB),-silent,on,-summary,off
+PERL_COVER = cover
+
+check-coverage-run recheck-coverage-run: all
+       $(mkinstalldirs) $(PERL_COVERAGE_DB)
+       PERL5OPT="$$PERL5OPT $(PERL_COVERAGE_FLAGS)"; export PERL5OPT; \
+       WANT_NO_THREADS=yes; export WANT_NO_THREADS; unset AUTOMAKE_JOBS; \
+       $(MAKE) $(AM_MAKEFLAGS) `echo $@ | sed 's/-coverage-run//'`
+
+check-coverage-report:
+       @if test ! -d "$(PERL_COVERAGE_DB)"; then \
+         echo "No coverage database found in \`$(PERL_COVERAGE_DB)'." >&2; \
+         echo "Please run \`make check-coverage' first" >&2; \
+         exit 1; \
+       fi
+       $(PERL_COVER) $(PERL_COVER_FLAGS) "$(PERL_COVERAGE_DB)"
+
+# We don't use direct dependencies here because we'd like to be able
+# to invoke the report even after interrupted check-coverage.
+check-coverage: check-coverage-run
+       $(MAKE) $(AM_MAKEFLAGS) check-coverage-report
+
+recheck-coverage: recheck-coverage-run
+       $(MAKE) $(AM_MAKEFLAGS) check-coverage-report
+
+clean-coverage:
+       rm -rf "$(PERL_COVERAGE_DB)"
+clean-local: clean-coverage
+
+.PHONY: check-coverage recheck-coverage check-coverage-run \
+       recheck-coverage-run check-coverage-report clean-coverage
+
 # Some simple checks, and then ordinary check.  These are only really
 # guaranteed to work on my machine.
 syntax_check_rules = \
index 33d85f3..d8e60c0 100644 (file)
@@ -1,4 +1,4 @@
-# Makefile.in generated by automake 1.11 from Makefile.am.
+# Makefile.in generated by automake 1.11a from Makefile.am.
 # @configure_input@
 
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
@@ -59,9 +59,9 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/amversion.m4 \
        $(top_srcdir)/m4/install-sh.m4 $(top_srcdir)/m4/lead-dot.m4 \
        $(top_srcdir)/m4/missing.m4 $(top_srcdir)/m4/mkdirp.m4 \
        $(top_srcdir)/m4/options.m4 $(top_srcdir)/m4/runlog.m4 \
-       $(top_srcdir)/m4/sanity.m4 $(top_srcdir)/m4/strip.m4 \
-       $(top_srcdir)/m4/substnot.m4 $(top_srcdir)/m4/tar.m4 \
-       $(top_srcdir)/configure.ac
+       $(top_srcdir)/m4/sanity.m4 $(top_srcdir)/m4/silent.m4 \
+       $(top_srcdir)/m4/strip.m4 $(top_srcdir)/m4/substnot.m4 \
+       $(top_srcdir)/m4/tar.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
        $(ACLOCAL_M4)
 am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \
@@ -92,6 +92,12 @@ am__base_list = \
   sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
 am__installdirs = "$(DESTDIR)$(bindir)"
 SCRIPTS = $(bin_SCRIPTS)
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN     " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
@@ -105,9 +111,10 @@ RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive    \
   distclean-recursive maintainer-clean-recursive
 AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \
        $(RECURSIVE_CLEAN_TARGETS:-recursive=) tags TAGS ctags CTAGS \
-       distdir dist dist-all distcheck
+       cscope distdir dist dist-all distcheck
 ETAGS = etags
 CTAGS = ctags
+CSCOPE = cscope
 DIST_SUBDIRS = $(SUBDIRS)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 distdir = $(PACKAGE)-$(VERSION)
@@ -116,6 +123,7 @@ am__remove_distdir = \
   { test ! -d "$(distdir)" \
     || { find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \
          && rm -fr "$(distdir)"; }; }
+am__post_remove_distdir = $(am__remove_distdir)
 am__relativize = \
   dir0=`pwd`; \
   sed_first='s,^\([^/]*\)/.*$$,\1,'; \
@@ -143,10 +151,12 @@ am__relativize = \
   reldir="$$dir2"
 DIST_ARCHIVES = $(distdir).tar.gz $(distdir).tar.bz2
 GZIP_ENV = --best
+DIST_TARGETS = dist-bzip2 dist-gzip
 distuninstallcheck_listfiles = find . -type f -print
 distcleancheck_listfiles = find . -type f -print
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 APIVERSION = @APIVERSION@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -263,6 +273,12 @@ do_subst = sed \
   -e 's,[@]configure_input[@],Generated from $@.in; do not edit by hand.,g' \
   -e 's,[@]datadir[@],$(datadir),g'
 
+TEST_SUBDIRS = lib/Automake/tests tests
+
+# Perl coverage statistics.
+PERL_COVERAGE_DB = $(abs_top_builddir)/cover_db
+PERL_COVERAGE_FLAGS = -MDevel::Cover=-db,$(PERL_COVERAGE_DB),-silent,on,-summary,off
+PERL_COVER = cover
 
 # Some simple checks, and then ordinary check.  These are only really
 # guaranteed to work on my machine.
@@ -457,6 +473,10 @@ ctags-recursive:
        list='$(SUBDIRS)'; for subdir in $$list; do \
          test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
        done
+cscopelist-recursive:
+       list='$(SUBDIRS)'; for subdir in $$list; do \
+         test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) cscopelist); \
+       done
 
 ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
        list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
@@ -520,8 +540,32 @@ GTAGS:
          && $(am__cd) $(top_srcdir) \
          && gtags -i $(GTAGS_ARGS) "$$here"
 
+cscope: cscope.files
+       test ! -s cscope.files \
+         || $(CSCOPE) -b -q $(AM_CSCOPEFLAGS) $(CSCOPEFLAGS) -i cscope.files $(CSCOPE_ARGS)
+
+clean-cscope:
+       -rm -f cscope.files
+
+cscope.files: clean-cscope cscopelist-recursive cscopelist
+
+cscopelist: cscopelist-recursive $(HEADERS) $(SOURCES) $(LISP)
+       list='$(SOURCES) $(HEADERS) $(LISP)'; \
+       case "$(srcdir)" in \
+         [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
+         *) sdir=$(subdir)/$(srcdir) ;; \
+       esac; \
+       for i in $$list; do \
+         if test -f "$$i"; then \
+           echo "$(subdir)/$$i"; \
+         else \
+           echo "$$sdir/$$i"; \
+         fi; \
+       done >> $(top_builddir)/cscope.files
+
 distclean-tags:
        -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
+       -rm -f cscope.out cscope.in.out cscope.po.out cscope.files
 
 distdir: $(DISTFILES)
        $(am__remove_distdir)
@@ -600,36 +644,39 @@ distdir: $(DISTFILES)
        else :; fi
 dist-gzip: distdir
        tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz
-       $(am__remove_distdir)
+       $(am__post_remove_distdir)
 dist-bzip2: distdir
        tardir=$(distdir) && $(am__tar) | bzip2 -9 -c >$(distdir).tar.bz2
-       $(am__remove_distdir)
+       $(am__post_remove_distdir)
+
+dist-lzip: distdir
+       tardir=$(distdir) && $(am__tar) | lzip -9 -c >$(distdir).tar.lz
+       $(am__post_remove_distdir)
 
 dist-lzma: distdir
        tardir=$(distdir) && $(am__tar) | lzma -9 -c >$(distdir).tar.lzma
-       $(am__remove_distdir)
+       $(am__post_remove_distdir)
 
 dist-xz: distdir
        tardir=$(distdir) && $(am__tar) | xz -9 -c >$(distdir).tar.xz
-       $(am__remove_distdir)
+       $(am__post_remove_distdir)
 
 dist-tarZ: distdir
        tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z
-       $(am__remove_distdir)
+       $(am__post_remove_distdir)
 
 dist-shar: distdir
        shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz
-       $(am__remove_distdir)
+       $(am__post_remove_distdir)
 
 dist-zip: distdir
        -rm -f $(distdir).zip
        zip -rq $(distdir).zip $(distdir)
-       $(am__remove_distdir)
+       $(am__post_remove_distdir)
 
-dist dist-all: distdir
-       tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz
-       tardir=$(distdir) && $(am__tar) | bzip2 -9 -c >$(distdir).tar.bz2
-       $(am__remove_distdir)
+dist dist-all:
+       $(MAKE) $(AM_MAKEFLAGS) $(DIST_TARGETS) am__post_remove_distdir='@:'
+       $(am__post_remove_distdir)
 
 # This target untars the dist file and tries a VPATH configuration.  Then
 # it guarantees that the distribution is self-contained by making another
@@ -642,6 +689,8 @@ distcheck: dist
          bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\
        *.tar.lzma*) \
          lzma -dc $(distdir).tar.lzma | $(am__untar) ;;\
+       *.tar.lz*) \
+         lzip -dc $(distdir).tar.lz | $(am__untar) ;;\
        *.tar.xz*) \
          xz -dc $(distdir).tar.xz | $(am__untar) ;;\
        *.tar.Z*) \
@@ -684,7 +733,7 @@ distcheck: dist
          && $(MAKE) $(AM_MAKEFLAGS) distcleancheck \
          && cd "$$am__cwd" \
          || exit 1
-       $(am__remove_distdir)
+       $(am__post_remove_distdir)
        @(echo "$(distdir) archives ready for distribution: "; \
          list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \
          sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x'
@@ -742,7 +791,7 @@ maintainer-clean-generic:
        @echo "it deletes files that may require special tools to rebuild."
 clean: clean-recursive
 
-clean-am: clean-generic mostlyclean-am
+clean-am: clean-generic clean-local mostlyclean-am
 
 distclean: distclean-recursive
        -rm -f $(am__CONFIG_DISTCLEAN_FILES)
@@ -811,26 +860,27 @@ ps-am:
 uninstall-am: uninstall-binSCRIPTS
        @$(NORMAL_INSTALL)
        $(MAKE) $(AM_MAKEFLAGS) uninstall-hook
-.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) ctags-recursive \
-       install-am install-exec-am install-strip tags-recursive \
-       uninstall-am
+.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) \
+       cscopelist-recursive ctags-recursive install-am \
+       install-exec-am install-strip tags-recursive uninstall-am
 
 .PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
-       all all-am am--refresh check check-am clean clean-generic \
-       ctags ctags-recursive dist dist-all dist-bzip2 dist-gzip \
-       dist-hook dist-lzma dist-shar dist-tarZ dist-xz dist-zip \
-       distcheck distclean distclean-generic distclean-tags \
-       distcleancheck distdir distuninstallcheck dvi dvi-am html \
-       html-am info info-am install install-am install-binSCRIPTS \
-       install-data install-data-am install-dvi install-dvi-am \
-       install-exec install-exec-am install-exec-hook install-html \
-       install-html-am install-info install-info-am install-man \
-       install-pdf install-pdf-am install-ps install-ps-am \
-       install-strip installcheck installcheck-am installdirs \
-       installdirs-am maintainer-clean maintainer-clean-generic \
-       mostlyclean mostlyclean-generic pdf pdf-am ps ps-am tags \
-       tags-recursive uninstall uninstall-am uninstall-binSCRIPTS \
-       uninstall-hook
+       all all-am am--refresh check check-am clean clean-cscope \
+       clean-generic clean-local cscope cscopelist \
+       cscopelist-recursive ctags ctags-recursive dist dist-all \
+       dist-bzip2 dist-gzip dist-hook dist-lzip dist-lzma dist-shar \
+       dist-tarZ dist-xz dist-zip distcheck distclean \
+       distclean-generic distclean-tags distcleancheck distdir \
+       distuninstallcheck dvi dvi-am html html-am info info-am \
+       install install-am install-binSCRIPTS install-data \
+       install-data-am install-dvi install-dvi-am install-exec \
+       install-exec-am install-exec-hook install-html install-html-am \
+       install-info install-info-am install-man install-pdf \
+       install-pdf-am install-ps install-ps-am install-strip \
+       installcheck installcheck-am installdirs installdirs-am \
+       maintainer-clean maintainer-clean-generic mostlyclean \
+       mostlyclean-generic pdf pdf-am ps ps-am tags tags-recursive \
+       uninstall uninstall-am uninstall-binSCRIPTS uninstall-hook
 
 
 install-exec-hook:
@@ -853,14 +903,28 @@ uninstall-hook:
 automake: automake.in
 aclocal: aclocal.in
 automake aclocal: Makefile
-       rm -f $@ $@.tmp
-       $(do_subst) $(srcdir)/$@.in >$@.tmp
-       chmod +x $@.tmp
-       chmod a-w $@.tmp
-       mv -f $@.tmp $@
+       $(AM_V_GEN)rm -f $@ $@.tmp
+       $(AM_V_at)$(do_subst) $(srcdir)/$@.in >$@.tmp
+       $(AM_V_at)chmod +x $@.tmp
+       $(AM_V_at)chmod a-w $@.tmp
+       $(AM_V_at)mv -f $@.tmp $@
 
 INSTALL: lib/INSTALL
-       cp $(srcdir)/lib/INSTALL $@
+       $(AM_V_GEN)cp $(srcdir)/lib/INSTALL $@
+
+.PHONY: recheck
+recheck:
+       @failcom='exit 1'; \
+       for f in x $$MAKEFLAGS; do \
+         case $$f in \
+           *=* | --[!k]*);; \
+           *k*) failcom='fail=yes';; \
+         esac; \
+       done; \
+       for subdir in $(TEST_SUBDIRS); do \
+         (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $@) || eval $$failcom; \
+       done; \
+       test -z "$$fail"
 
 ################################################################
 
@@ -868,6 +932,35 @@ INSTALL: lib/INSTALL
 dist-hook:
        cd $(distdir)/tests && chmod a+rx *.test
 
+check-coverage-run recheck-coverage-run: all
+       $(mkinstalldirs) $(PERL_COVERAGE_DB)
+       PERL5OPT="$$PERL5OPT $(PERL_COVERAGE_FLAGS)"; export PERL5OPT; \
+       WANT_NO_THREADS=yes; export WANT_NO_THREADS; unset AUTOMAKE_JOBS; \
+       $(MAKE) $(AM_MAKEFLAGS) `echo $@ | sed 's/-coverage-run//'`
+
+check-coverage-report:
+       @if test ! -d "$(PERL_COVERAGE_DB)"; then \
+         echo "No coverage database found in \`$(PERL_COVERAGE_DB)'." >&2; \
+         echo "Please run \`make check-coverage' first" >&2; \
+         exit 1; \
+       fi
+       $(PERL_COVER) $(PERL_COVER_FLAGS) "$(PERL_COVERAGE_DB)"
+
+# We don't use direct dependencies here because we'd like to be able
+# to invoke the report even after interrupted check-coverage.
+check-coverage: check-coverage-run
+       $(MAKE) $(AM_MAKEFLAGS) check-coverage-report
+
+recheck-coverage: recheck-coverage-run
+       $(MAKE) $(AM_MAKEFLAGS) check-coverage-report
+
+clean-coverage:
+       rm -rf "$(PERL_COVERAGE_DB)"
+clean-local: clean-coverage
+
+.PHONY: check-coverage recheck-coverage check-coverage-run \
+       recheck-coverage-run check-coverage-report clean-coverage
+
 .PHONY: $(syntax_check_rules)
 $(syntax_check_rules): automake aclocal
 maintainer-check: $(syntax_check_rules)
diff --git a/NEWS b/NEWS
index fee7f83..74887fb 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -1,17 +1,36 @@
-New in 1.11.0a:
+New in 1.11a:
+
+* Changes to automake:
+
+  - automake now generates silenced rules for texinfo outputs.
+
+* New targets:
+
+  - New `cscope' target to build a cscope database for the source tree.
 
 * Miscellaneous changes:
 
+  - The `dist' and `dist-all' targets now can run compressors in parallel.
+
   - The `lzma' compression scheme and associated automake option `dist-lzma'
     is obsoleted by `xz' and `dist-xz' due to upstream changes.
 
-Bugs fixed in 1.11.0a:
+  - "make dist" can now create lzip-compressed tarballs.
+
+Bugs fixed in 1.11a:
+
+  - Lots of minor bugfixes.
 
 * Bugs introduced by 1.11:
 
   - The `parallel-tests' test driver works around a GNU make 3.80 bug with
     trailing white space in the test list (`TESTS = foo $(EMPTY)').
 
+  - The `silent-rules' option now also silences all compile rules if dependency
+    tracking is disabled.  Also, when `silent-rules' is not used, the output from
+    `make' does not contain spurious extra lines with only a backslash in them
+    any more; it now again matches that from pre-1.11 Automake.
+
   - The `dist-xz' option now uses `xz -9' for maximum compression.
 
 * Long standing bugs:
@@ -28,6 +47,11 @@ Bugs fixed in 1.11.0a:
   - AM_PROG_GCJ uses AC_CHECK_TOOLS to look for `gcj' now, so that prefixed
     tools are preferred in a cross-compile setup.
 
+  - The distribution is tarred up with mode 755 now by the `dist*' targets.
+    This fixes a race condition where untrusted users could modify files
+    in the $(PACKAGE)-$(VERSION) distdir before packing if the toplevel
+    build directory was world-searchable.  This is CVE-2009-4029.
+
   - Several scripts as well as the parallel-tests testsuite driver now
     exit with the right exit status upon receiving a signal.
 
diff --git a/THANKS b/THANKS
index 4f8fa84..91d0f4b 100644 (file)
--- a/THANKS
+++ b/THANKS
@@ -65,6 +65,7 @@ danbp                 danpb@nospam.postmaster.co.uk
 Daniel Jacobowitz      drow@false.org
 Daniel Kahn Gillmor    dkg@fifthhorseman.net
 Daniel Richard G.      danielg@teragram.com
+Debarshi Ray           rishi@gnu.org
 Dave Brolley           brolley@redhat.com
 Dave Korn              dave.korn.cygwin@googlemail.com
 Dave Morrison          dave@bnl.gov
@@ -268,6 +269,7 @@ Per Oyvind Hvidsten poeh@enter.vg
 Peter Breitenlohner    peb@mppmu.mpg.de
 Peter Eisentraut       peter_e@gmx.net
 Peter Gavin            pgavin@debaser.kicks-ass.org
+Peter Johansson                trojkan@gmail.com
 Peter Mattis           petm@scam.XCF.Berkeley.EDU
 Peter Muir             iyhi@yahoo.com
 Peter O'Gorman         peter@pogma.com
index d7cbc11..3c960a3 100644 (file)
@@ -1,4 +1,4 @@
-# generated automatically by aclocal 1.11 -*- Autoconf -*-
+# generated automatically by aclocal 1.11a -*- Autoconf -*-
 
 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
 # 2005, 2006, 2007, 2008, 2009, 2010  Free Software Foundation, Inc.
@@ -29,6 +29,7 @@ m4_include([m4/mkdirp.m4])
 m4_include([m4/options.m4])
 m4_include([m4/runlog.m4])
 m4_include([m4/sanity.m4])
+m4_include([m4/silent.m4])
 m4_include([m4/strip.m4])
 m4_include([m4/substnot.m4])
 m4_include([m4/tar.m4])
old mode 100755 (executable)
new mode 100644 (file)
index 503c221..d5e3ec2
@@ -1183,6 +1183,14 @@ sub verbose_flag ($)
     return '';
 }
 
+sub verbose_nodep_flag ($)
+{
+    my ($name) = @_;
+    return '$(' . verbose_var ($name) . subst ('am__nodep') . ')'
+      if (option 'silent-rules');
+    return '';
+}
+
 # silent_flag
 # -----------
 # Contents of %SILENT%: variable to expand to `@' when silent.
@@ -1199,11 +1207,25 @@ sub define_verbose_tagvar ($)
     my ($name) = @_;
     if (option 'silent-rules')
       {
-       define_verbose_var ($name, '@echo "  '. $name . ' ' x (6 - length ($name)) . '" $@;');
+       define_verbose_var ($name, '@echo "  '. $name . ' ' x (8 - length ($name)) . '" $@;');
        define_verbose_var ('at', '@');
       }
 }
 
+# define_verbose_texinfo
+# ----------------------
+# Engage the needed `silent-rules' machinery for assorted texinfo commands.
+sub define_verbose_texinfo ()
+{
+  my @tagvars = ('DVIPS', 'MAKEINFO', 'INFOHTML', 'TEXI2DVI', 'TEXI2PDF');
+  foreach my $tag (@tagvars)
+    {
+      define_verbose_tagvar($tag);
+    }
+  define_verbose_var('texinfo', '-q');
+  define_verbose_var('texidevnull', '> /dev/null');
+}
+
 # define_verbose_libtool
 # ----------------------
 # Engage the needed `silent-rules' machinery for `libtool --silent'.
@@ -1380,6 +1402,8 @@ sub handle_languages
          ? ('FALSE', 'FALSE') : ('AMDEP', "am__fastdep$fpfx");
 
        my $verbose = verbose_flag ($lang->ccer || 'GEN');
+       my $verbose_nodep = ($AMDEP eq 'FALSE')
+         ? $verbose : verbose_nodep_flag ($lang->ccer || 'GEN');
        my $silent = silent_flag ();
 
        my %transform = ('EXT'     => $ext,
@@ -1394,6 +1418,7 @@ sub handle_languages
                         'DERIVED-EXT' => 'BUG',
                         DIST_SOURCE   => 1,
                         VERBOSE   => $verbose,
+                        'VERBOSE-NODEP' => $verbose_nodep,
                         SILENT    => $silent,
                        );
 
@@ -1616,6 +1641,7 @@ sub handle_languages
                             LTOBJ     => "$obj.lo",
 
                             VERBOSE   => $verbose,
+                            'VERBOSE-NODEP'  => $verbose_nodep,
                             SILENT    => $silent,
                             COMPILE   => $obj_compile,
                             LTCOMPILE => $obj_ltcompile,
@@ -3233,6 +3259,9 @@ sub output_texinfo_build_rules ($$$@)
 
   $output_rules .= file_contents ('texibuild',
                                  new Automake::Location,
+                                  AM_V_MAKEINFO    => verbose_flag('MAKEINFO'),
+                                  AM_V_TEXI2DVI    => verbose_flag('TEXI2DVI'),
+                                  AM_V_TEXI2PDF    => verbose_flag('TEXI2PDF'),
                                  DEPS             => "@deps",
                                  DEST_PREFIX      => $dpfx,
                                  DEST_INFO_PREFIX => $dipfx,
@@ -3242,12 +3271,15 @@ sub output_texinfo_build_rules ($$$@)
                                  GENERIC_INFO     => $generic_info,
                                  INSRC            => $insrc,
                                  MAKEINFOFLAGS    => $makeinfoflags,
+                                  SILENT           => silent_flag(),
                                  SOURCE           => ($generic
                                                       ? '$<' : $source),
                                  SOURCE_INFO      => ($generic_info
                                                       ? '$<' : $source),
                                  SOURCE_REAL      => $source,
                                  SOURCE_SUFFIX    => $ssfx,
+                                  TEXIQUIET        => verbose_flag('texinfo'),
+                                  TEXIDEVNULL      => verbose_flag('texidevnull'),
                                  );
   return ($dirstamp, "$dpfx.dvi", "$dpfx.pdf", "$dpfx.ps", "$dpfx.html");
 }
@@ -3556,6 +3588,7 @@ sub handle_texinfo ()
   my ($mostlyclean, $clean, $maintclean) = ('', '', '');
   if ($info_texinfos)
     {
+      define_verbose_texinfo;
       ($mostlyclean, $clean, $maintclean) = handle_texinfo_helper ($info_texinfos);
       chomp $mostlyclean;
       chomp $clean;
@@ -3564,10 +3597,12 @@ sub handle_texinfo ()
 
   $output_rules .=  file_contents ('texinfos',
                                   new Automake::Location,
+                                   AM_V_DVIPS    => verbose_flag('DVIPS'),
                                   MOSTLYCLEAN   => $mostlyclean,
                                   TEXICLEAN     => $clean,
                                   MAINTCLEAN    => $maintclean,
-                                  'LOCAL-TEXIS' => !!$info_texinfos);
+                                  'LOCAL-TEXIS' => !!$info_texinfos,
+                                   TEXIQUIET     => verbose_flag('texinfo'));
 }
 
 
@@ -3724,6 +3759,7 @@ sub handle_tags
 {
     my @tag_deps = ();
     my @ctag_deps = ();
+    my @cscope_deps = ();
     if (var ('SUBDIRS'))
     {
        $output_rules .= ("tags-recursive:\n"
@@ -3747,6 +3783,17 @@ sub handle_tags
        push (@ctag_deps, 'ctags-recursive');
        &depend ('.PHONY', 'ctags-recursive');
        &depend ('.MAKE', 'ctags-recursive');
+
+       $output_rules .= ("cscopelist-recursive:\n"
+                         . "\tlist=\'\$(SUBDIRS)\'; for subdir in \$\$list; do \\\n"
+                         # Never fail here if a subdir fails; it
+                         # isn't important.
+                         . "\t  test \"\$\$subdir\" = . || (\$(am__cd) \$\$subdir"
+                         . " && \$(MAKE) \$(AM_MAKEFLAGS) cscopelist); \\\n"
+                         . "\tdone\n");
+       push (@cscope_deps, 'cscopelist-recursive');
+       &depend ('.PHONY', 'cscopelist-recursive');
+       &depend ('.MAKE', 'cscopelist-recursive');
     }
 
     if (&saw_sources_p (1)
@@ -3769,7 +3816,8 @@ sub handle_tags
                                         new Automake::Location,
                                         CONFIG    => "@config",
                                         TAGSDIRS  => "@tag_deps",
-                                        CTAGSDIRS => "@ctag_deps");
+                                        CTAGSDIRS => "@ctag_deps",
+                                        CSCOPEDIRS => "@cscope_deps");
 
        set_seen 'TAGS_DEPENDENCIES';
     }
@@ -3784,8 +3832,9 @@ sub handle_tags
        # Otherwise, it would be possible for a top-level "make TAGS"
        # to fail because some subdirectory failed.
        $output_rules .= "tags: TAGS\nTAGS:\n\n";
-       # Ditto ctags.
+       # Ditto ctags and cscope.
        $output_rules .= "ctags: CTAGS\nCTAGS:\n\n";
+       $output_rules .= "cscope cscopelist:\n\n";
     }
 }
 
@@ -3895,7 +3944,7 @@ sub handle_dist ()
     {
       my $archive_defined = option 'no-dist-gzip' ? 0 : 1;
       $archive_defined ||=
-       grep { option "dist-$_" } qw(shar zip tarZ bzip2 lzma xz);
+       grep { option "dist-$_" } qw(shar zip tarZ bzip2 lzip lzma xz);
       error (option 'no-dist-gzip',
             "no-dist-gzip specified but no dist-* specified, "
             . "at least one archive format must be enabled")
@@ -7049,6 +7098,7 @@ sub make_paragraphs ($%)
 
                 'XZ'          => !! option 'dist-xz',
                 'LZMA'        => !! option 'dist-lzma',
+                'LZIP'        => !! option 'dist-lzip',
                 'BZIP2'       => !! option 'dist-bzip2',
                 'COMPRESS'    => !! option 'dist-tarZ',
                 'GZIP'        =>  ! option 'no-dist-gzip',
index 9dc1545..6bb1f12 100755 (executable)
--- a/configure
+++ b/configure
@@ -1,6 +1,6 @@
 #! /bin/sh
 # Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.65 for GNU Automake 1.11.
+# Generated by GNU Autoconf 2.65 for GNU Automake 1.11a.
 #
 # Report bugs to <bug-automake@gnu.org>.
 #
@@ -552,8 +552,8 @@ MAKEFLAGS=
 # Identity of this package.
 PACKAGE_NAME='GNU Automake'
 PACKAGE_TARNAME='automake'
-PACKAGE_VERSION='1.11'
-PACKAGE_STRING='GNU Automake 1.11'
+PACKAGE_VERSION='1.11a'
+PACKAGE_STRING='GNU Automake 1.11a'
 PACKAGE_BUGREPORT='bug-automake@gnu.org'
 PACKAGE_URL='http://www.gnu.org/software/automake/'
 
@@ -572,6 +572,8 @@ PERL_THREADS
 PERL
 pkgvdatadir
 APIVERSION
+AM_BACKSLASH
+AM_DEFAULT_VERBOSITY
 am__untar
 am__tar
 AMTAR
@@ -642,6 +644,7 @@ SHELL'
 ac_subst_files=''
 ac_user_opts='
 enable_option_checking
+enable_silent_rules
 '
       ac_precious_vars='build_alias
 host_alias
@@ -1187,7 +1190,7 @@ if test "$ac_init_help" = "long"; then
   # Omit some internal or obsolete options to make the list less imposing.
   # This message is too long to be a string in the A/UX 3.1 sh.
   cat <<_ACEOF
-\`configure' configures GNU Automake 1.11 to adapt to many kinds of systems.
+\`configure' configures GNU Automake 1.11a to adapt to many kinds of systems.
 
 Usage: $0 [OPTION]... [VAR=VALUE]...
 
@@ -1256,10 +1259,17 @@ fi
 
 if test -n "$ac_init_help"; then
   case $ac_init_help in
-     short | recursive ) echo "Configuration of GNU Automake 1.11:";;
+     short | recursive ) echo "Configuration of GNU Automake 1.11a:";;
    esac
   cat <<\_ACEOF
 
+Optional Features:
+  --disable-option-checking  ignore unrecognized --enable/--with options
+  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
+  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
+  --enable-silent-rules          less verbose build output (undo: `make V=1')
+  --disable-silent-rules         verbose build output (undo: `make V=0')
+
 Report bugs to <bug-automake@gnu.org>.
 GNU Automake home page: <http://www.gnu.org/software/automake/>.
 General help using GNU software: <http://www.gnu.org/gethelp/>.
@@ -1325,7 +1335,7 @@ fi
 test -n "$ac_init_help" && exit $ac_status
 if $ac_init_version; then
   cat <<\_ACEOF
-GNU Automake configure 1.11
+GNU Automake configure 1.11a
 generated by GNU Autoconf 2.65
 
 Copyright (C) 2009 Free Software Foundation, Inc.
@@ -1342,7 +1352,7 @@ cat >config.log <<_ACEOF
 This file contains any messages produced by compilers while
 running configure, to aid debugging if configure makes a mistake.
 
-It was created by GNU Automake $as_me 1.11, which was
+It was created by GNU Automake $as_me 1.11a, which was
 generated by GNU Autoconf 2.65.  Invocation command line was
 
   $ $0 $@
@@ -1762,7 +1772,7 @@ am_AUTOCONF="${AUTOCONF-autoconf}"
 am_AUTOHEADER="${AUTOHEADER-autoheader}"
 
 
-am__api_version='1.11'
+am__api_version='1.11a'
 
 # Find a good install program.  We prefer a C program (faster),
 # so one script is as good as another.  But avoid the broken or
@@ -2182,6 +2192,18 @@ else
 fi
 rmdir .tst 2>/dev/null
 
+# Check whether --enable-silent-rules was given.
+if test "${enable_silent_rules+set}" = set; then :
+  enableval=$enable_silent_rules;
+fi
+
+case $enable_silent_rules in
+yes) AM_DEFAULT_VERBOSITY=0;;
+no)  AM_DEFAULT_VERBOSITY=1;;
+*)   AM_DEFAULT_VERBOSITY=1;;
+esac
+AM_BACKSLASH='\'
+
 if test "`cd $srcdir && pwd`" != "`pwd`"; then
   # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
   # is not polluted with repeated "-I."
@@ -2204,7 +2226,7 @@ fi
 
 # Define the identity of the package.
  PACKAGE='automake'
- VERSION='1.11'
+ VERSION='1.11a'
 
 
 cat >>confdefs.h <<_ACEOF
@@ -3280,7 +3302,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
 # report actual input values of CONFIG_FILES etc. instead of their
 # values after options handling.
 ac_log="
-This file was extended by GNU Automake $as_me 1.11, which was
+This file was extended by GNU Automake $as_me 1.11a, which was
 generated by GNU Autoconf 2.65.  Invocation command line was
 
   CONFIG_FILES    = $CONFIG_FILES
@@ -3335,7 +3357,7 @@ _ACEOF
 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
 ac_cs_version="\\
-GNU Automake config.status 1.11
+GNU Automake config.status 1.11a
 configured by $0, generated by GNU Autoconf 2.65,
   with options \\"\$ac_cs_config\\"
 
index 759952d..9f8eabe 100644 (file)
@@ -16,7 +16,7 @@
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-AC_INIT([GNU Automake], [1.11], [bug-automake@gnu.org])
+AC_INIT([GNU Automake], [1.11a], [bug-automake@gnu.org])
 
 AC_CONFIG_SRCDIR(automake.in)
 AC_CONFIG_AUX_DIR(lib)
@@ -29,7 +29,8 @@ AC_CANONICAL_BUILD
 AC_SUBST([am_AUTOCONF], ["${AUTOCONF-autoconf}"])
 AC_SUBST([am_AUTOHEADER], ["${AUTOHEADER-autoheader}"])
 
-AM_INIT_AUTOMAKE([1.10a dist-bzip2 filename-length-max=99 color-tests parallel-tests])
+AM_INIT_AUTOMAKE([1.10a dist-bzip2 filename-length-max=99 color-tests
+                 parallel-tests silent-rules])
 
 # The API version is the base version.  We must guarantee
 # compatibility for all releases with the same API version.
index bb48fa2..01cf663 100644 (file)
@@ -27,12 +27,12 @@ dist_man1_MANS = \
   $(srcdir)/automake-$(APIVERSION).1
 MAINTAINERCLEANFILES = $(dist_man1_MANS)
 update_mans = \
-  PATH="`pwd`/../tests$(PATH_SEPARATOR)$$PATH" && \
+  $(AM_V_GEN)PATH="`pwd`/../tests$(PATH_SEPARATOR)$$PATH" && \
   export PATH && \
   $(HELP2MAN) --output=$@
 $(dist_man1_MANS): $(top_srcdir)/configure.ac
 $(srcdir)/aclocal.1 $(srcdir)/automake.1:
-       f=`echo $@ | sed 's|.*/||; s|\.1$$||; $(transform)'`; \
+       $(AM_V_GEN)f=`echo $@ | sed 's|.*/||; s|\.1$$||; $(transform)'`; \
        echo ".so man1/$$f-$(APIVERSION).1" > $@
 $(srcdir)/aclocal-$(APIVERSION).1: $(srcdir)/../aclocal.in
        $(update_mans) aclocal-$(APIVERSION)
@@ -70,7 +70,7 @@ dist_doc_DATA = $(srcdir)/amhello-1.0.tar.gz
 # aclocal-$(APIVERSION) and automake-$(APIVERSION) are generated by
 # configure in tests/.
 $(srcdir)/amhello-1.0.tar.gz: $(amhello_sources) $(top_srcdir)/configure.ac
-       PATH="`pwd`/../tests$(PATH_SEPARATOR)$$PATH" && \
+       $(AM_V_GEN)PATH="`pwd`/../tests$(PATH_SEPARATOR)$$PATH" && \
        export PATH && \
        cd $(srcdir)/amhello && \
        ACLOCAL=aclocal-$(APIVERSION) AUTOMAKE=automake-$(APIVERSION) \
index 95a8fb8..d2e5a82 100644 (file)
@@ -1,4 +1,4 @@
-# Makefile.in generated by automake 1.11 from Makefile.am.
+# Makefile.in generated by automake 1.11a from Makefile.am.
 # @configure_input@
 
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
@@ -59,16 +59,43 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/amversion.m4 \
        $(top_srcdir)/m4/install-sh.m4 $(top_srcdir)/m4/lead-dot.m4 \
        $(top_srcdir)/m4/missing.m4 $(top_srcdir)/m4/mkdirp.m4 \
        $(top_srcdir)/m4/options.m4 $(top_srcdir)/m4/runlog.m4 \
-       $(top_srcdir)/m4/sanity.m4 $(top_srcdir)/m4/strip.m4 \
-       $(top_srcdir)/m4/substnot.m4 $(top_srcdir)/m4/tar.m4 \
-       $(top_srcdir)/configure.ac
+       $(top_srcdir)/m4/sanity.m4 $(top_srcdir)/m4/silent.m4 \
+       $(top_srcdir)/m4/strip.m4 $(top_srcdir)/m4/substnot.m4 \
+       $(top_srcdir)/m4/tar.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
        $(ACLOCAL_M4)
 mkinstalldirs = $(SHELL) $(top_srcdir)/lib/mkinstalldirs
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN     " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
+AM_V_DVIPS = $(am__v_DVIPS_$(V))
+am__v_DVIPS_ = $(am__v_DVIPS_$(AM_DEFAULT_VERBOSITY))
+am__v_DVIPS_0 = @echo "  DVIPS   " $@;
+AM_V_MAKEINFO = $(am__v_MAKEINFO_$(V))
+am__v_MAKEINFO_ = $(am__v_MAKEINFO_$(AM_DEFAULT_VERBOSITY))
+am__v_MAKEINFO_0 = @echo "  MAKEINFO" $@;
+AM_V_INFOHTML = $(am__v_INFOHTML_$(V))
+am__v_INFOHTML_ = $(am__v_INFOHTML_$(AM_DEFAULT_VERBOSITY))
+am__v_INFOHTML_0 = @echo "  INFOHTML" $@;
+AM_V_TEXI2DVI = $(am__v_TEXI2DVI_$(V))
+am__v_TEXI2DVI_ = $(am__v_TEXI2DVI_$(AM_DEFAULT_VERBOSITY))
+am__v_TEXI2DVI_0 = @echo "  TEXI2DVI" $@;
+AM_V_TEXI2PDF = $(am__v_TEXI2PDF_$(V))
+am__v_TEXI2PDF_ = $(am__v_TEXI2PDF_$(AM_DEFAULT_VERBOSITY))
+am__v_TEXI2PDF_0 = @echo "  TEXI2PDF" $@;
+AM_V_texinfo = $(am__v_texinfo_$(V))
+am__v_texinfo_ = $(am__v_texinfo_$(AM_DEFAULT_VERBOSITY))
+am__v_texinfo_0 = -q
+AM_V_texidevnull = $(am__v_texidevnull_$(V))
+am__v_texidevnull_ = $(am__v_texidevnull_$(AM_DEFAULT_VERBOSITY))
+am__v_texidevnull_0 = > /dev/null
 INFO_DEPS = $(srcdir)/automake.info
 TEXINFO_TEX = $(top_srcdir)/lib/texinfo.tex
 am__TEXINFO_TEX_DIR = $(top_srcdir)/lib
@@ -114,6 +141,7 @@ CTAGS = ctags
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 APIVERSION = @APIVERSION@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -212,7 +240,7 @@ dist_man1_MANS = \
 
 MAINTAINERCLEANFILES = $(dist_man1_MANS)
 update_mans = \
-  PATH="`pwd`/../tests$(PATH_SEPARATOR)$$PATH" && \
+  $(AM_V_GEN)PATH="`pwd`/../tests$(PATH_SEPARATOR)$$PATH" && \
   export PATH && \
   $(HELP2MAN) --output=$@
 
@@ -278,7 +306,7 @@ $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 $(am__aclocal_m4_deps):
 
 .texi.info:
-       restore=: && backupdir="$(am__leading_dot)am$$$$" && \
+       $(AM_V_MAKEINFO)restore=: && backupdir="$(am__leading_dot)am$$$$" && \
        am__cwd=`pwd` && $(am__cd) $(srcdir) && \
        rm -rf $$backupdir && mkdir $$backupdir && \
        if ($(MAKEINFO) --version) >/dev/null 2>&1; then \
@@ -300,18 +328,18 @@ $(am__aclocal_m4_deps):
        rm -rf $$backupdir; exit $$rc
 
 .texi.dvi:
-       TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
+       $(AM_V_TEXI2DVI)TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
        MAKEINFO='$(MAKEINFO) $(AM_MAKEINFOFLAGS) $(MAKEINFOFLAGS) -I $(srcdir)' \
-       $(TEXI2DVI) $<
+       $(TEXI2DVI) $(AM_V_texinfo) $< $(AM_V_texidevnull)
 
 .texi.pdf:
-       TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
+       $(AM_V_TEXI2PDF)TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
        MAKEINFO='$(MAKEINFO) $(AM_MAKEINFOFLAGS) $(MAKEINFOFLAGS) -I $(srcdir)' \
-       $(TEXI2PDF) $<
+       $(TEXI2PDF) $(AM_V_texinfo) $< $(AM_V_texidevnull)
 
 .texi.html:
-       rm -rf $(@:.html=.htp)
-       if $(MAKEINFOHTML) $(AM_MAKEINFOHTMLFLAGS) $(MAKEINFOFLAGS) -I $(srcdir) \
+       $(AM_V_MAKEINFO)rm -rf $(@:.html=.htp)
+       $(AM_V_at)if $(MAKEINFOHTML) $(AM_MAKEINFOHTMLFLAGS) $(MAKEINFOFLAGS) -I $(srcdir) \
         -o $(@:.html=.htp) $<; \
        then \
          rm -rf $@; \
@@ -346,8 +374,8 @@ mostlyclean-vti:
 maintainer-clean-vti:
        -rm -f $(srcdir)/stamp-vti $(srcdir)/version.texi
 .dvi.ps:
-       TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
-       $(DVIPS) -o $@ $<
+       $(AM_V_DVIPS)TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
+       $(DVIPS) $(AM_V_texinfo) -o $@ $<
 
 uninstall-dvi-am:
        @$(NORMAL_UNINSTALL)
@@ -548,6 +576,20 @@ GTAGS:
          && $(am__cd) $(top_srcdir) \
          && gtags -i $(GTAGS_ARGS) "$$here"
 
+cscopelist:  $(HEADERS) $(SOURCES) $(LISP)
+       list='$(SOURCES) $(HEADERS) $(LISP)'; \
+       case "$(srcdir)" in \
+         [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
+         *) sdir=$(subdir)/$(srcdir) ;; \
+       esac; \
+       for i in $$list; do \
+         if test -f "$$i"; then \
+           echo "$(subdir)/$$i"; \
+         else \
+           echo "$$sdir/$$i"; \
+         fi; \
+       done >> $(top_builddir)/cscope.files
+
 distclean-tags:
        -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 
@@ -780,24 +822,25 @@ uninstall-man: uninstall-man1
 .MAKE: install-am install-strip
 
 .PHONY: CTAGS GTAGS all all-am check check-am clean clean-aminfo \
-       clean-generic ctags dist-info distclean distclean-generic \
-       distclean-tags distdir dvi dvi-am html html-am info info-am \
-       install install-am install-data install-data-am \
-       install-dist_docDATA install-dvi install-dvi-am install-exec \
-       install-exec-am install-html install-html-am install-info \
-       install-info-am install-man install-man1 install-pdf \
-       install-pdf-am install-ps install-ps-am install-strip \
-       installcheck installcheck-am installdirs maintainer-clean \
-       maintainer-clean-aminfo maintainer-clean-generic \
-       maintainer-clean-vti mostlyclean mostlyclean-aminfo \
-       mostlyclean-generic mostlyclean-vti pdf pdf-am ps ps-am tags \
-       uninstall uninstall-am uninstall-dist_docDATA uninstall-dvi-am \
-       uninstall-html-am uninstall-info-am uninstall-man \
-       uninstall-man1 uninstall-pdf-am uninstall-ps-am
+       clean-generic cscopelist ctags dist-info distclean \
+       distclean-generic distclean-tags distdir dvi dvi-am html \
+       html-am info info-am install install-am install-data \
+       install-data-am install-dist_docDATA install-dvi \
+       install-dvi-am install-exec install-exec-am install-html \
+       install-html-am install-info install-info-am install-man \
+       install-man1 install-pdf install-pdf-am install-ps \
+       install-ps-am install-strip installcheck installcheck-am \
+       installdirs maintainer-clean maintainer-clean-aminfo \
+       maintainer-clean-generic maintainer-clean-vti mostlyclean \
+       mostlyclean-aminfo mostlyclean-generic mostlyclean-vti pdf \
+       pdf-am ps ps-am tags uninstall uninstall-am \
+       uninstall-dist_docDATA uninstall-dvi-am uninstall-html-am \
+       uninstall-info-am uninstall-man uninstall-man1 \
+       uninstall-pdf-am uninstall-ps-am
 
 $(dist_man1_MANS): $(top_srcdir)/configure.ac
 $(srcdir)/aclocal.1 $(srcdir)/automake.1:
-       f=`echo $@ | sed 's|.*/||; s|\.1$$||; $(transform)'`; \
+       $(AM_V_GEN)f=`echo $@ | sed 's|.*/||; s|\.1$$||; $(transform)'`; \
        echo ".so man1/$$f-$(APIVERSION).1" > $@
 $(srcdir)/aclocal-$(APIVERSION).1: $(srcdir)/../aclocal.in
        $(update_mans) aclocal-$(APIVERSION)
@@ -809,7 +852,7 @@ $(srcdir)/automake-$(APIVERSION).1: $(srcdir)/../automake.in
 # aclocal-$(APIVERSION) and automake-$(APIVERSION) are generated by
 # configure in tests/.
 $(srcdir)/amhello-1.0.tar.gz: $(amhello_sources) $(top_srcdir)/configure.ac
-       PATH="`pwd`/../tests$(PATH_SEPARATOR)$$PATH" && \
+       $(AM_V_GEN)PATH="`pwd`/../tests$(PATH_SEPARATOR)$$PATH" && \
        export PATH && \
        cd $(srcdir)/amhello && \
        ACLOCAL=aclocal-$(APIVERSION) AUTOMAKE=automake-$(APIVERSION) \
index c945d44..9bfcf65 100644 (file)
@@ -313,7 +313,7 @@ Support for Test Suites
 
 Miscellaneous Rules
 
-* Tags::                        Interfacing to etags and mkid
+* Tags::                        Interfacing to cscope, etags and mkid
 * Suffixes::                    Handling new file extensions
 * Multilibs::                   Support for multilibs.
 
@@ -8441,6 +8441,11 @@ frequently smaller than gzipped archives.
 Generate a gzip tar archive of the distribution.
 @trindex dist-gzip
 
+@item @code{dist-lzip}
+Generate an @samp{lzip} tar archive of the distribution.  @command{lzip}
+archives are frequently smaller than @command{bzip2}-compressed archives.
+@trindex dist-lzip
+
 @item @code{dist-lzma}
 Generate an @samp{lzma} tar archive of the distribution.  @command{lzma}
 archives are frequently smaller than @command{bzip2}-compressed archives.
@@ -8991,6 +8996,12 @@ Cause @command{dejagnu}-specific rules to be generated.  @xref{DejaGnu Tests}.
 Hook @code{dist-bzip2} to @code{dist}.
 @trindex dist-bzip2
 
+@item @option{dist-lzip}
+@cindex Option, @option{dist-lzip}
+@opindex dist-lzip
+Hook @code{dist-lzip} to @code{dist}.
+@trindex dist-lzip
+
 @item @option{dist-lzma}
 @cindex Option, @option{dist-lzma}
 @opindex dist-lzma
@@ -9263,7 +9274,8 @@ In order to use this option with C sources, you should add
 These three mutually exclusive options select the tar format to use
 when generating tarballs with @samp{make dist}.  (The tar file created
 is then compressed according to the set of @option{no-dist-gzip},
-@option{dist-bzip2}, @option{dist-xz} and @option{dist-tarZ} options in use.)
+@option{dist-bzip2}, @option{dist-lzip}, @option{dist-tarZ} and
+@option{dist-xz} options in use.)
 
 These options must be passed as arguments to @code{AM_INIT_AUTOMAKE}
 (@pxref{Macros}) because they can require additional configure checks.
@@ -9335,7 +9347,7 @@ the @code{AM_INIT_AUTOMAKE} macro in @file{configure.ac}.
 There are a few rules and variables that didn't fit anywhere else.
 
 @menu
-* Tags::                        Interfacing to etags and mkid
+* Tags::                        Interfacing to cscope, etags and mkid
 * Suffixes::                    Handling new file extensions
 * Multilibs::                   Support for multilibs.
 @end menu
@@ -9397,6 +9409,14 @@ Automake will also generate an @code{ID} rule that will run
 directory-by-directory basis.
 @trindex id
 
+Similarly, the @code{cscope} rule will create a list of all the source
+files in the tree and run @command{cscope} to build an inverted index
+database.  The variable @code{CSCOPE} is the name of the program to invoke
+(by default @command{cscope}); @code{CSCOPEFLAGS} and
+@code{CSCOPE_ARGS} can be used by the user to pass additional flags and
+file names respectively, while @code{AM_CSCOPEFLAGS} can be used by the
+@file{Makefile.am}.
+
 Finally, Automake also emits rules to support the
 @uref{http://www.gnu.org/software/global/, GNU Global Tags program}.
 The @code{GTAGS} rule runs Global Tags and puts the
@@ -12921,4 +12941,4 @@ parentheses is the number of generated test cases.
 @c  LocalWords:  LTALLOCA MALLOC malloc memcmp strdup alloca libcompat xyz DFOO
 @c  LocalWords:  unprefixed buildable preprocessed DBAZ DDATADIR WARNINGCFLAGS
 @c  LocalWords:  LIBFOOCFLAGS LIBFOOLDFLAGS ftable testSubDir obj LIBTOOLFLAGS
-@c  LocalWords:  barexec Pinard's automatize initialize lzma xz
+@c  LocalWords:  barexec Pinard's automatize initialize lzip lzma xz cscope
index a740603..ce6bf29 100644 (file)
@@ -1,4 +1,5 @@
-# Copyright (C) 2002, 2003, 2006, 2008, 2009 Free Software Foundation, Inc.
+# Copyright (C) 2002, 2003, 2006, 2008, 2009 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
@@ -43,7 +44,7 @@ Automake::ChannelDefs - channel definitions for Automake and helper functions
   verb ($MESSAGE, [%OPTIONS]);
   switch_warning ($CATEGORY);
   parse_WARNINGS ();
-  parse_warning ($OPTION, $ARGUMENT);
+  parse_warnings ($OPTION, $ARGUMENT);
   Automake::ChannelDefs::set_strictness ($STRICTNESS_NAME);
 
 =head1 DESCRIPTION
@@ -307,7 +308,7 @@ sub parse_WARNINGS ()
     }
 }
 
-=item C<parse_warning ($OPTION, $ARGUMENT)>
+=item C<parse_warnings ($OPTION, $ARGUMENT)>
 
 Parse the argument of C<--warning=CATEGORY> or C<-WCATEGORY>.
 
index 2d649f6..5c54b8b 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright (C) 1997, 2001, 2002, 2003, 2006, 2008  Free Software
+# Copyright (C) 1997, 2001, 2002, 2003, 2006, 2008, 2009  Free Software
 # Foundation, Inc.
 
 # This program is free software; you can redistribute it and/or modify
@@ -180,18 +180,21 @@ sub new ($;@)
   };
   bless $self, $class;
 
-  # Accept strings like "FOO BAR" as shorthand for ("FOO", "BAR").
-  @conds = map { split (' ', $_) } @conds;
-
   for my $cond (@conds)
     {
-      next if $cond eq 'TRUE';
-
       # Catch some common programming errors:
       # - A Condition passed to new
       confess "`$cond' is a reference, expected a string" if ref $cond;
       # - A Condition passed as a string to new
       confess "`$cond' does not look like a condition" if $cond =~ /::/;
+    }
+
+  # Accept strings like "FOO BAR" as shorthand for ("FOO", "BAR").
+  @conds = map { split (' ', $_) } @conds;
+
+  for my $cond (@conds)
+    {
+      next if $cond eq 'TRUE';
 
       # Detect cases when @conds can be simplified to FALSE.
       if (($cond eq 'FALSE' && $#conds > 0)
@@ -250,7 +253,7 @@ except those of C<$minuscond>.  This is the opposite of C<merge>.
 sub strip ($$)
 {
   my ($self, $minus) = @_;
-  my @res = grep { not $minus->has ($_) } $self->conds;
+  my @res = grep { not $minus->_has ($_) } $self->conds;
   return new Automake::Condition @res;
 }
 
@@ -274,7 +277,7 @@ sub conds ($ )
 }
 
 # Undocumented, shouldn't be needed outside of this class.
-sub has ($$)
+sub _has ($$)
 {
   my ($self, $cond) = @_;
   return exists $self->{'hash'}{$cond};
@@ -289,7 +292,7 @@ Return 1 iff this condition is always false.
 sub false ($ )
 {
   my ($self) = @_;
-  return $self->has ('FALSE');
+  return $self->_has ('FALSE');
 }
 
 =item C<$cond-E<gt>true>
@@ -426,7 +429,7 @@ sub true_when ($$)
   # exists in $WHEN.
   foreach my $cond ($self->conds)
     {
-      return 0 unless $when->has ($cond);
+      return 0 unless $when->_has ($cond);
     }
   return 1;
 }
@@ -518,6 +521,8 @@ sub multiply ($@)
   return (values %res);
 }
 
+=back
+
 =head2 Other helper functions
 
 =over 4
@@ -615,6 +620,8 @@ sub conditional_negate ($)
   return $cond;
 }
 
+=back
+
 =head1 SEE ALSO
 
 L<Automake::DisjConditions>.
index 646fad3..d5ad977 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright (C) 2003, 2005, 2006  Free Software Foundation, Inc.
+# Copyright (C) 2003, 2005, 2006, 2009  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
@@ -49,6 +49,20 @@ Automake::Configure_ac - Locate configure.ac or configure.in.
   my $file_name = find_configure_ac ($dir);
   my $file_name = require_configure_ac ($dir);
 
+=over 4
+
+=back
+
+=head2 Functions
+
+=over 4
+
+=item C<$configure_ac = find_configure_ac ([$directory])>
+
+Find a F<configure.ac> or F<configure.in> file in C<$directory>,
+defaulting to the current directory.  Complain if both files are present.
+Return the name of the file found, or the former if neither is present.
+
 =cut
 
 sub find_configure_ac (;@)
@@ -78,6 +92,12 @@ sub find_configure_ac (;@)
 }
 
 
+=item C<$configure_ac = require_configure_ac ([$directory])>
+
+Like C<find_configure_ac>, but fail if neither is present.
+
+=cut
+
 sub require_configure_ac (;$)
 {
   my $res = find_configure_ac (@_);
index 613dc80..1dc81dc 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright (C) 2002, 2003, 2008  Free Software Foundation, Inc.
+# Copyright (C) 2002, 2003, 2008, 2009  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
@@ -50,7 +50,7 @@ Automake::Location - a class for location tracking, with a stack of contexts
       ...
     }
 
-  # Pop a context, and reset the location from the previous context.
+  # Pop a context, and reset the location to the previous context.
   $where->pop_context;
 
   # Clone a Location.  Use this when storing the state of a location
@@ -84,6 +84,16 @@ You can pass a C<Location> to C<Automake::Channels::msg>.
 
 =cut
 
+=head2 Methods
+
+=over
+
+=item C<$where = new Automake::Location ([$position])>
+
+Create and return a new Location object.
+
+=cut
+
 sub new ($;$)
 {
   my ($class, $position) = @_;
@@ -95,18 +105,36 @@ sub new ($;$)
   return $self;
 }
 
+=item C<$location-E<gt>set ($position)>
+
+Change the location to be C<$position>.
+
+=cut
+
 sub set ($$)
 {
   my ($self, $position) = @_;
   $self->{'position'} = $position;
 }
 
+=item C<$location-E<gt>get>
+
+Get the location (without context).
+
+=cut
+
 sub get ($)
 {
   my ($self) = @_;
   return $self->{'position'};
 }
 
+=item C<$location-E<gt>push_context ($context)>
+
+Push a context to the location.
+
+=cut
+
 sub push_context ($$)
 {
   my ($self, $context) = @_;
@@ -114,6 +142,12 @@ sub push_context ($$)
   $self->set (undef);
 }
 
+=item C<$where = $location-E<gt>pop_context ($context)>
+
+Pop a context, and reset the location to the previous context.
+
+=cut
+
 sub pop_context ($)
 {
   my ($self) = @_;
@@ -122,12 +156,25 @@ sub pop_context ($)
   return @{$pair};
 }
 
+=item C<@contexts = $location-E<gt>get_contexts>
+
+Return the array of contexts.
+
+=cut
+
 sub get_contexts ($)
 {
   my ($self) = @_;
   return @{$self->{'contexts'}};
 }
 
+=item C<$location = $location-E<gt>clone>
+
+Clone a Location.  Use this when storing the state of a location
+that would otherwise be modified.
+
+=cut
+
 sub clone ($)
 {
   my ($self) = @_;
@@ -140,6 +187,12 @@ sub clone ($)
   return $other;
 }
 
+=item C<$res = $location-E<gt>dump>
+
+Print the location and the stack of context (for debugging).
+
+=cut
+
 sub dump ($)
 {
   my ($self) = @_;
@@ -152,6 +205,13 @@ sub dump ($)
   return $res;
 }
 
+=item C<@array = $location-E<gt>serialize>
+
+Serialize a Location object (for passing through a thread queue,
+for example).
+
+=cut
+
 sub serialize ($)
 {
   my ($self) = @_;
@@ -166,6 +226,12 @@ sub serialize ($)
   return @serial;
 }
 
+=item C<new Automake::Location::deserialize ($queue)>
+
+De-serialize: recreate a Location object from a queue.
+
+=cut
+
 sub deserialize ($)
 {
   my ($queue) = @_;
@@ -179,6 +245,8 @@ sub deserialize ($)
   return $self;
 }
 
+=back
+
 =head1 SEE ALSO
 
 L<Automake::Channels>
index 3b9b863..c0b536c 100644 (file)
@@ -63,10 +63,9 @@ do_subst = in=`echo $@ | sed 's/\.[^.]*$$//'`; sed \
 ## $(datadir) or other do_subst'ituted variables change.
 ## Use chmod a-w to prevent people from editing the wrong file by accident.
 Config.pm: Config.in Makefile
-       rm -f Config.tmp Config.pm
-       $(do_subst) $(srcdir)/Config.in >Config.tmp
-       chmod +x Config.tmp
-       chmod a-w Config.tmp
-       mv -f Config.tmp Config.pm
+       $(AM_V_GEN)rm -f Config.tmp Config.pm
+       $(AM_V_at)$(do_subst) $(srcdir)/Config.in >Config.tmp
+       $(AM_V_at)chmod a-w Config.tmp
+       $(AM_V_at)mv -f Config.tmp Config.pm
 
 EXTRA_DIST = Config.in
index 896bccf..e434809 100644 (file)
@@ -1,4 +1,4 @@
-# Makefile.in generated by automake 1.11 from Makefile.am.
+# Makefile.in generated by automake 1.11a from Makefile.am.
 # @configure_input@
 
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
@@ -58,14 +58,20 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/amversion.m4 \
        $(top_srcdir)/m4/install-sh.m4 $(top_srcdir)/m4/lead-dot.m4 \
        $(top_srcdir)/m4/missing.m4 $(top_srcdir)/m4/mkdirp.m4 \
        $(top_srcdir)/m4/options.m4 $(top_srcdir)/m4/runlog.m4 \
-       $(top_srcdir)/m4/sanity.m4 $(top_srcdir)/m4/strip.m4 \
-       $(top_srcdir)/m4/substnot.m4 $(top_srcdir)/m4/tar.m4 \
-       $(top_srcdir)/configure.ac
+       $(top_srcdir)/m4/sanity.m4 $(top_srcdir)/m4/silent.m4 \
+       $(top_srcdir)/m4/strip.m4 $(top_srcdir)/m4/substnot.m4 \
+       $(top_srcdir)/m4/tar.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
        $(ACLOCAL_M4)
 mkinstalldirs = $(SHELL) $(top_srcdir)/lib/mkinstalldirs
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN     " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
@@ -134,6 +140,7 @@ am__relativize = \
   reldir="$$dir2"
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 APIVERSION = @APIVERSION@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -405,6 +412,10 @@ ctags-recursive:
        list='$(SUBDIRS)'; for subdir in $$list; do \
          test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
        done
+cscopelist-recursive:
+       list='$(SUBDIRS)'; for subdir in $$list; do \
+         test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) cscopelist); \
+       done
 
 ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
        list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
@@ -468,6 +479,20 @@ GTAGS:
          && $(am__cd) $(top_srcdir) \
          && gtags -i $(GTAGS_ARGS) "$$here"
 
+cscopelist: cscopelist-recursive $(HEADERS) $(SOURCES) $(LISP)
+       list='$(SOURCES) $(HEADERS) $(LISP)'; \
+       case "$(srcdir)" in \
+         [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
+         *) sdir=$(subdir)/$(srcdir) ;; \
+       esac; \
+       for i in $$list; do \
+         if test -f "$$i"; then \
+           echo "$(subdir)/$$i"; \
+         else \
+           echo "$$sdir/$$i"; \
+         fi; \
+       done >> $(top_builddir)/cscope.files
+
 distclean-tags:
        -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 
@@ -629,17 +654,18 @@ ps-am:
 
 uninstall-am: uninstall-dist_perllibDATA uninstall-nodist_perllibDATA
 
-.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) ctags-recursive \
-       install-am install-strip tags-recursive
+.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) \
+       cscopelist-recursive ctags-recursive install-am install-strip \
+       tags-recursive
 
 .PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
-       all all-am check check-am clean clean-generic ctags \
-       ctags-recursive distclean distclean-generic distclean-tags \
-       distdir dvi dvi-am html html-am info info-am install \
-       install-am install-data install-data-am \
-       install-dist_perllibDATA install-dvi install-dvi-am \
-       install-exec install-exec-am install-html install-html-am \
-       install-info install-info-am install-man \
+       all all-am check check-am clean clean-generic cscopelist \
+       cscopelist-recursive ctags ctags-recursive distclean \
+       distclean-generic distclean-tags distdir dvi dvi-am html \
+       html-am info info-am install install-am install-data \
+       install-data-am install-dist_perllibDATA install-dvi \
+       install-dvi-am install-exec install-exec-am install-html \
+       install-html-am install-info install-info-am install-man \
        install-nodist_perllibDATA install-pdf install-pdf-am \
        install-ps install-ps-am install-strip installcheck \
        installcheck-am installdirs installdirs-am maintainer-clean \
@@ -649,11 +675,10 @@ uninstall-am: uninstall-dist_perllibDATA uninstall-nodist_perllibDATA
 
 
 Config.pm: Config.in Makefile
-       rm -f Config.tmp Config.pm
-       $(do_subst) $(srcdir)/Config.in >Config.tmp
-       chmod +x Config.tmp
-       chmod a-w Config.tmp
-       mv -f Config.tmp Config.pm
+       $(AM_V_GEN)rm -f Config.tmp Config.pm
+       $(AM_V_at)$(do_subst) $(srcdir)/Config.in >Config.tmp
+       $(AM_V_at)chmod a-w Config.tmp
+       $(AM_V_at)mv -f Config.tmp Config.pm
 
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
index 9543aa5..0c38838 100644 (file)
@@ -260,7 +260,7 @@ sub _process_option_list (\%$@)
       elsif ($_ eq 'no-installman' || $_ eq 'no-installinfo'
             || $_ eq 'dist-shar' || $_ eq 'dist-zip'
             || $_ eq 'dist-tarZ' || $_ eq 'dist-bzip2'
-            || $_ eq 'dist-lzma' || $_ eq 'dist-xz'
+            || $_ eq 'dist-lzip' || $_ eq 'dist-lzma' || $_ eq 'dist-xz'
             || $_ eq 'no-dist-gzip' || $_ eq 'no-dist'
             || $_ eq 'dejagnu' || $_ eq 'no-texinfo.tex'
             || $_ eq 'readme-alpha' || $_ eq 'check-news'
index 20bc106..3bd506d 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright (C) 2003  Free Software Foundation, Inc.
+# Copyright (C) 2003, 2009  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
@@ -36,6 +36,7 @@ Automake::RuleDef - a class for rule definitions
 =head1 DESCRIPTION
 
 This class gathers data related to one Makefile-rule definition.
+It shouldn't be needed outside of F<Rule.pm>.
 
 =head2 Constants
 
@@ -50,6 +51,20 @@ Possible owners for rules.
 use constant RULE_AUTOMAKE => 0; # Rule defined by Automake.
 use constant RULE_USER => 1;     # Rule defined in the user's Makefile.am.
 
+=back
+
+=head2 Methods
+
+=over 4
+
+=item C<new Automake::RuleDef ($name, $comment, $location, $owner, $source)>
+
+Create a new rule definition with target C<$name>, with associated comment
+C<$comment>, Location C<$location> and owner C<$owner>, defined in file
+C<$source>.
+
+=cut
+
 sub new ($$$$$)
 {
   my ($class, $name, $comment, $location, $owner, $source) = @_;
@@ -60,12 +75,24 @@ sub new ($$$$$)
   return $self;
 }
 
+=item C<$source = $rule-E<gt>source>
+
+Return the source of the rule.
+
+=cut
+
 sub source ($)
 {
   my ($self) = @_;
   return $self->{'source'};
 }
 
+=item C<$name = $rule-E<gt>name>
+
+Return the name of the rule.
+
+=cut
+
 sub name ($)
 {
   my ($self) = @_;
index d7ba155..7d10bb6 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright (C) 2003, 2004, 2006  Free Software Foundation, Inc.
+# Copyright (C) 2003, 2004, 2006, 2009  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
@@ -204,6 +204,8 @@ sub append ($$$)
 
 =item C<$def-E<gt>value>
 
+=item C<$def-E<gt>raw_value>
+
 =item C<$def-E<gt>type>
 
 =item C<$def-E<gt>pretty>
index 8a5b568..c340dc7 100644 (file)
@@ -470,7 +470,7 @@ sub _check_ambiguous_condition ($$$)
   # We allow silent variables to be overridden silently,
   # by either silent or non-silent variables.
   my $def = $self->def ($ambig_cond);
-  if ($message && !($def && $def->pretty == VAR_SILENT))
+  if ($message && $def->pretty != VAR_SILENT)
     {
       msg 'syntax', $where, "$message ...", partial => 1;
       msg_var ('syntax', $var, "... `$var' previously defined here");
index 66213d1..59b3e5a 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright (C) 2003, 2006  Free Software Foundation, Inc.
+# Copyright (C) 2003, 2006, 2009  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
@@ -48,10 +48,10 @@ maximum length allowed.  (Ticket #17141, fixed in Perl 5.8.0.)
 
 =cut
 
-# tab_length ($TXT)
-# -----------------
+# _tab_length ($TXT)
+# ------------------
 # Compute the length of TXT, counting tab characters as 8 characters.
-sub tab_length($)
+sub _tab_length($)
 {
   my ($txt) = @_;
   my $len = length ($txt);
@@ -78,16 +78,16 @@ sub wrap($$$$@)
   my ($head, $fill, $eol, $max_len, @values) = @_;
 
   my $result = $head;
-  my $column = tab_length ($head);
+  my $column = _tab_length ($head);
 
-  my $fill_len = tab_length ($fill);
-  my $eol_len = tab_length ($eol);
+  my $fill_len = _tab_length ($fill);
+  my $eol_len = _tab_length ($eol);
 
   my $not_first_word = 0;
 
   foreach (@values)
     {
-      my $len = tab_length ($_);
+      my $len = _tab_length ($_);
 
       # See if the new variable fits on this line.
       # (The + 1 is for the space we add in front of the value.).
index 7c8f5eb..a7bb219 100644 (file)
@@ -68,18 +68,6 @@ methods C<close>, C<lock> (corresponding to C<flock>), C<new>,
 C<open>, C<seek>, and C<truncate>.  It also overrides the C<getline>
 and C<getlines> methods to translate C<\r\n> to C<\n>.
 
-=head1 SEE ALSO
-
-L<perlfunc>,
-L<perlop/"I/O Operators">,
-L<IO::File>
-L<IO::Handle>
-L<IO::Seekable>
-
-=head1 HISTORY
-
-Derived from IO::File.pm by Akim Demaille E<lt>F<akim@freefriends.org>E<gt>.
-
 =cut
 
 require 5.000;
@@ -113,9 +101,16 @@ eval {
 # Used in croak error messages.
 my $me = basename ($0);
 
-################################################
-## Constructor
-##
+=head2 Methods
+
+=over
+
+=item C<$fh = new Automake::XFile ([$expr, ...]>
+
+Constructor a new XFile object.  Additional arguments
+are passed to C<open>, if any.
+
+=cut
 
 sub new
 {
@@ -129,9 +124,12 @@ sub new
   $fh;
 }
 
-################################################
-## Open
-##
+=item C<$fh-E<gt>open ([$file, ...])>
+
+Open a file, passing C<$file> and further arguments to C<IO::File::open>.
+Die if opening fails.  Store the name of the file.  Use binmode for writing.
+
+=cut
 
 sub open
 {
@@ -156,9 +154,11 @@ sub open
   binmode $fh if $file =~ /^\s*>/;
 }
 
-################################################
-## Close
-##
+=item C<$fh-E<gt>close>
+
+Close the file, handling errors.
+
+=cut
 
 sub close
 {
@@ -172,9 +172,12 @@ sub close
     }
 }
 
-################################################
-## Getline
-##
+=item C<$line = $fh-E<gt>getline>
+
+Read and return a line from the file.  Ensure C<\r\n> is translated to
+C<\n> on input files.
+
+=cut
 
 # Some Win32/perl installations fail to translate \r\n to \n on input
 # so we do that here.
@@ -187,9 +190,11 @@ sub getline
   return $_;
 }
 
-################################################
-## Getlines
-##
+=item C<@lines = $fh-E<gt>getlines>
+
+Slurp lines from the files.
+
+=cut
 
 sub getlines
 {
@@ -199,9 +204,11 @@ sub getlines
   return @res;
 }
 
-################################################
-## Name
-##
+=item C<$name = $fh-E<gt>name>
+
+Return the name of the file.
+
+=cut
 
 sub name
 {
@@ -209,9 +216,13 @@ sub name
   return ${*$fh}{'autom4te_xfile_file'};
 }
 
-################################################
-## Lock
-##
+=item C<$fh-E<gt>lock>
+
+Lock the file using C<flock>.  If locking fails for reasons other than
+C<flock> being unsupported, then error out if C<$ENV{'MAKEFLAGS'}> indicates
+that we are spawned from a parallel C<make>.
+
+=cut
 
 sub lock
 {
@@ -243,9 +254,11 @@ sub lock
     }
 }
 
-################################################
-## Seek
-##
+=item C<$fh-E<gt>seek ($position, [$whence])>
+
+Seek file to C<$position>.  Die if seeking fails.
+
+=cut
 
 sub seek
 {
@@ -258,9 +271,11 @@ sub seek
     }
 }
 
-################################################
-## Truncate
-##
+=item C<$fh-E<gt>truncate ($len)>
+
+Truncate the file to length C<$len>.  Die on failure.
+
+=cut
 
 sub truncate
 {
@@ -272,6 +287,22 @@ sub truncate
     }
 }
 
+=back
+
+=head1 SEE ALSO
+
+L<perlfunc>,
+L<perlop/"I/O Operators">,
+L<IO::File>
+L<IO::Handle>
+L<IO::Seekable>
+
+=head1 HISTORY
+
+Derived from IO::File.pm by Akim Demaille E<lt>F<akim@freefriends.org>E<gt>.
+
+=cut
+
 1;
 
 ### Setup "GNU" style for perl-mode and cperl-mode.
diff --git a/lib/Automake/tests/Cond2.pl b/lib/Automake/tests/Cond2.pl
new file mode 100644 (file)
index 0000000..4ad0e1c
--- /dev/null
@@ -0,0 +1,6 @@
+# Catch common programming error:
+# A Condition passed as a string to 'new'.
+use Automake::Condition;
+
+my $cond = new Automake::Condition ('TRUE');
+new Automake::Condition ($cond);
diff --git a/lib/Automake/tests/Cond3.pl b/lib/Automake/tests/Cond3.pl
new file mode 100644 (file)
index 0000000..dc957af
--- /dev/null
@@ -0,0 +1,6 @@
+# Catch common programming error:
+# A Condition passed as a string to 'new'.
+use Automake::Condition;
+
+my $cond = new Automake::Condition ("COND1_TRUE");
+new Automake::Condition ("$cond");
index 06eb34e..99004ac 100644 (file)
@@ -1,4 +1,5 @@
-# Copyright (C) 2001, 2002, 2003, 2008  Free Software Foundation, Inc.
+# Copyright (C) 2001, 2002, 2003, 2008, 2009  Free Software Foundation,
+# Inc.
 #
 # This file is part of GNU Automake.
 #
@@ -18,7 +19,8 @@
 BEGIN {
   use Config;
   if (eval { require 5.007_002; }      # for CLONE support
-      && $Config{useithreads})
+      && $Config{useithreads}
+      && !$ENV{WANT_NO_THREADS})
     {
       require threads;
       import threads;
@@ -32,15 +34,15 @@ use Automake::Condition qw/TRUE FALSE/;
 
 sub test_basics ()
 {
-  my @tests = (# [[Conditions], is_true?, is_false?, string, subst-string]
-              [[], 1, 0, 'TRUE', ''],
-              [['TRUE'], 1, 0, 'TRUE', ''],
-              [['FALSE'], 0, 1, 'FALSE', '#'],
-              [['A_TRUE'], 0, 0, 'A_TRUE', '@A_TRUE@'],
+  my @tests = (# [[Conditions], is_true?, is_false?, string, subst-string, human]
+              [[], 1, 0, 'TRUE', '', 'TRUE'],
+              [['TRUE'], 1, 0, 'TRUE', '', 'TRUE'],
+              [['FALSE'], 0, 1, 'FALSE', '#', 'FALSE'],
+              [['A_TRUE'], 0, 0, 'A_TRUE', '@A_TRUE@', 'A'],
               [['A_TRUE', 'B_FALSE'],
-               0, 0, 'A_TRUE B_FALSE', '@A_TRUE@@B_FALSE@'],
-              [['B_TRUE', 'FALSE'], 0, 1, 'FALSE', '#'],
-              [['B_TRUE', 'B_FALSE'], 0, 1, 'FALSE', '#']);
+               0, 0, 'A_TRUE B_FALSE', '@A_TRUE@@B_FALSE@', 'A and !B'],
+              [['B_TRUE', 'FALSE'], 0, 1, 'FALSE', '#', 'FALSE'],
+              [['B_TRUE', 'B_FALSE'], 0, 1, 'FALSE', '#', 'FALSE']);
 
   for (@tests)
     {
@@ -53,6 +55,7 @@ sub test_basics ()
          return 1 if $_->[2] != ($a == FALSE);
          return 1 if $_->[3] ne $a->string;
          return 1 if $_->[4] ne $a->subst_string;
+         return 1 if $_->[5] ne $a->human;
        })->join;
     }
   return 0;
@@ -281,7 +284,33 @@ sub test_reduce_or ()
   return $failed;
 }
 
-exit (test_basics || test_true_when || test_reduce_and || test_reduce_or);
+sub test_merge ()
+{
+  my $cond = new Automake::Condition "COND1_TRUE", "COND2_FALSE";
+  return threads->new(sub {
+      my $other = new Automake::Condition "COND3_FALSE";
+      return threads->new(sub {
+       my $both = $cond->merge ($other);
+       return threads->new(sub {
+         my $both2 = $cond->merge_conds ("COND3_FALSE");
+         return threads->new(sub {
+           $cond = $both->strip ($other);
+           my @conds = $cond->conds;
+           return 1 if $both->string ne "COND1_TRUE COND2_FALSE COND3_FALSE";
+           return 1 if $cond->string ne "COND1_TRUE COND2_FALSE";
+           return 1 if $both != $both2;
+         })->join;
+       })->join;
+      })->join;
+    })->join;
+  return 0;
+}
+
+exit (test_basics
+      || test_true_when
+      || test_reduce_and
+      || test_reduce_or
+      || test_merge);
 
 ### Setup "GNU" style for perl-mode and cperl-mode.
 ## Local Variables:
index 86f1745..e330e53 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright (C) 2001, 2002, 2003  Free Software Foundation, Inc.
+# Copyright (C) 2001, 2002, 2003, 2009  Free Software Foundation, Inc.
 #
 # This file is part of GNU Automake.
 #
@@ -19,15 +19,15 @@ use Automake::Condition qw/TRUE FALSE/;
 
 sub test_basics ()
 {
-  my @tests = (# [[Conditions], is_true?, is_false?, string, subst-string]
-              [[], 1, 0, 'TRUE', ''],
-              [['TRUE'], 1, 0, 'TRUE', ''],
-              [['FALSE'], 0, 1, 'FALSE', '#'],
-              [['A_TRUE'], 0, 0, 'A_TRUE', '@A_TRUE@'],
+  my @tests = (# [[Conditions], is_true?, is_false?, string, subst-string, human]
+              [[], 1, 0, 'TRUE', '', 'TRUE'],
+              [['TRUE'], 1, 0, 'TRUE', '', 'TRUE'],
+              [['FALSE'], 0, 1, 'FALSE', '#', 'FALSE'],
+              [['A_TRUE'], 0, 0, 'A_TRUE', '@A_TRUE@', 'A'],
               [['A_TRUE', 'B_FALSE'],
-               0, 0, 'A_TRUE B_FALSE', '@A_TRUE@@B_FALSE@'],
-              [['B_TRUE', 'FALSE'], 0, 1, 'FALSE', '#'],
-              [['B_TRUE', 'B_FALSE'], 0, 1, 'FALSE', '#']);
+               0, 0, 'A_TRUE B_FALSE', '@A_TRUE@@B_FALSE@', 'A and !B'],
+              [['B_TRUE', 'FALSE'], 0, 1, 'FALSE', '#', 'FALSE'],
+              [['B_TRUE', 'B_FALSE'], 0, 1, 'FALSE', '#', 'FALSE']);
 
   for (@tests)
     {
@@ -38,6 +38,7 @@ sub test_basics ()
       return 1 if $_->[2] != ($a == FALSE);
       return 1 if $_->[3] ne $a->string;
       return 1 if $_->[4] ne $a->subst_string;
+      return 1 if $_->[5] ne $a->human;
     }
   return 0;
 }
@@ -240,7 +241,25 @@ sub test_reduce_or ()
   return $failed;
 }
 
-exit (test_basics || test_true_when || test_reduce_and || test_reduce_or);
+sub test_merge ()
+{
+  my $cond = new Automake::Condition "COND1_TRUE", "COND2_FALSE";
+  my $other = new Automake::Condition "COND3_FALSE";
+  my $both = $cond->merge ($other);
+  my $both2 = $cond->merge_conds ("COND3_FALSE");
+  $cond = $both->strip ($other);
+  my @conds = $cond->conds;
+  return 1 if $both->string ne "COND1_TRUE COND2_FALSE COND3_FALSE";
+  return 1 if $cond->string ne "COND1_TRUE COND2_FALSE";
+  return 1 if $both != $both2;
+  return 0;
+}
+
+exit (test_basics
+      || test_true_when
+      || test_reduce_and
+      || test_reduce_or
+      || test_merge);
 
 ### Setup "GNU" style for perl-mode and cperl-mode.
 ## Local Variables:
diff --git a/lib/Automake/tests/DisjCon2.pl b/lib/Automake/tests/DisjCon2.pl
new file mode 100644 (file)
index 0000000..9edd8d5
--- /dev/null
@@ -0,0 +1,8 @@
+# Catch common programming error:
+# A non-Condition reference passed to new.
+use Automake::Condition;
+use Automake::DisjConditions;
+
+my $cond = new Automake::Condition ('TRUE');
+my $cond2 = new Automake::DisjConditions ($cond);
+new Automake::DisjConditions ($cond2);
diff --git a/lib/Automake/tests/DisjCon3.pl b/lib/Automake/tests/DisjCon3.pl
new file mode 100644 (file)
index 0000000..8e69e2b
--- /dev/null
@@ -0,0 +1,7 @@
+# Catch common programming error:
+# A non-reference passed to new.
+use Automake::Condition qw/TRUE FALSE/;
+use Automake::DisjConditions;
+
+my $cond = new Automake::Condition ("COND1_TRUE");
+new Automake::DisjConditions ("$cond");
index 2fe275b..4df5112 100644 (file)
@@ -1,4 +1,5 @@
-# Copyright (C) 2001, 2002, 2003, 2008  Free Software Foundation, Inc.
+# Copyright (C) 2001, 2002, 2003, 2008, 2009  Free Software Foundation,
+# Inc.
 #
 # This file is part of GNU Automake.
 #
@@ -18,7 +19,8 @@
 BEGIN {
   use Config;
   if (eval { require 5.007_002; }      # for CLONE support
-      && $Config{useithreads})
+      && $Config{useithreads}
+      && !$ENV{WANT_NO_THREADS})
     {
       require threads;
       import threads;
@@ -33,18 +35,44 @@ use Automake::DisjConditions;
 
 sub test_basics ()
 {
+  my $true = new Automake::DisjConditions TRUE;
+  my $false = new Automake::DisjConditions FALSE;
   my $cond = new Automake::Condition "COND1_TRUE", "COND2_FALSE";
   return threads->new (sub {
     my $other = new Automake::Condition "COND3_FALSE";
+    my $another = new Automake::Condition "COND3_TRUE", "COND4_FALSE";
     return threads->new (sub {
       my $set1 = new Automake::DisjConditions $cond, $other;
       return threads->new (sub {
        my $set2 = new Automake::DisjConditions $other, $cond;
+       my $set3 = new Automake::DisjConditions FALSE, $another;
        return 1 unless $set1 == $set2;
        return 1 if $set1->false;
        return 1 if $set1->true;
        return 1 unless (new Automake::DisjConditions)->false;
        return 1 if (new Automake::DisjConditions)->true;
+       return 1 unless $true->human eq 'TRUE';
+       return 1 unless $false->human eq 'FALSE';
+       return 1 unless $set1->human eq "(COND1 and !COND2) or (!COND3)";
+       return 1 unless $set2->human eq "(COND1 and !COND2) or (!COND3)";
+       my $one_cond_human = $set1->one_cond->human;
+       return 1 unless $one_cond_human eq "!COND3"
+                       || $one_cond_human eq "COND1 and !COND2";
+       return 1 unless $set1->string eq "COND1_TRUE COND2_FALSE | COND3_FALSE";
+
+       my $merged1 = $set1->merge ($set2);
+       my $merged2 = $set1->merge ($cond);
+       my $mult1 = $set1->multiply ($set3);
+       return threads->new (sub {
+         my $mult2 = $set1->multiply ($another);
+         return threads->new (sub {
+           return 1 unless $merged1->simplify->string eq "COND1_TRUE COND2_FALSE | COND3_FALSE";
+           return 1 unless $merged2->simplify->string eq "COND1_TRUE COND2_FALSE | COND3_FALSE";
+           return 1 unless $mult1->string eq "COND1_TRUE COND2_FALSE COND3_TRUE COND4_FALSE";
+           return 1 unless $mult1 == $mult2;
+           return 0;
+         })->join;
+       })->join;
       })->join;
     })->join;
   })->join;
index 47dea83..7ccac13 100644 (file)
@@ -1,4 +1,5 @@
-# Copyright (C) 2001, 2002, 2003, 2008  Free Software Foundation, Inc.
+# Copyright (C) 2001, 2002, 2003, 2008, 2009  Free Software Foundation,
+# Inc.
 #
 # This file is part of GNU Automake.
 #
@@ -20,15 +21,38 @@ use Automake::DisjConditions;
 
 sub test_basics ()
 {
+  my $true = new Automake::DisjConditions TRUE;
+  my $false = new Automake::DisjConditions FALSE;
   my $cond = new Automake::Condition "COND1_TRUE", "COND2_FALSE";
   my $other = new Automake::Condition "COND3_FALSE";
+  my $another = new Automake::Condition "COND3_TRUE", "COND4_FALSE";
   my $set1 = new Automake::DisjConditions $cond, $other;
   my $set2 = new Automake::DisjConditions $other, $cond;
+  my $set3 = new Automake::DisjConditions FALSE, $another;
   return 1 unless $set1 == $set2;
   return 1 if $set1->false;
   return 1 if $set1->true;
   return 1 unless (new Automake::DisjConditions)->false;
   return 1 if (new Automake::DisjConditions)->true;
+  return 1 unless $true->human eq 'TRUE';
+  return 1 unless $false->human eq 'FALSE';
+  return 1 unless $set1->human eq "(COND1 and !COND2) or (!COND3)";
+  return 1 unless $set2->human eq "(COND1 and !COND2) or (!COND3)";
+  my $one_cond_human = $set1->one_cond->human;
+  return 1 unless $one_cond_human eq "!COND3"
+                  || $one_cond_human eq "COND1 and !COND2";
+  return 1 unless $set1->string eq "COND1_TRUE COND2_FALSE | COND3_FALSE";
+
+  my $merged1 = $set1->merge ($set2);
+  my $merged2 = $set1->merge ($cond);
+  my $mult1 = $set1->multiply ($set3);
+  my $mult2 = $set1->multiply ($another);
+  return 1 unless $merged1->simplify->string eq "COND1_TRUE COND2_FALSE | COND3_FALSE";
+  return 1 unless $merged2->simplify->string eq "COND1_TRUE COND2_FALSE | COND3_FALSE";
+  return 1 unless $mult1->string eq "COND1_TRUE COND2_FALSE COND3_TRUE COND4_FALSE";
+  return 1 unless $mult1 == $mult2;
+
+  return 0;
 }
 
 sub build_set (@)
index c5e53d2..b4f09f1 100644 (file)
@@ -22,9 +22,23 @@ TEST_EXTENSIONS = .pl
 TESTS = \
 Condition.pl \
 Condition-t.pl \
+Cond2.pl \
+Cond3.pl \
 DisjConditions.pl \
 DisjConditions-t.pl \
+DisjCon2.pl \
+DisjCon3.pl \
 Version.pl \
+Version2.pl \
+Version3.pl \
 Wrap.pl
 
+XFAIL_TESTS = \
+Cond2.pl \
+Cond3.pl \
+DisjCon2.pl \
+DisjCon3.pl \
+Version2.pl \
+Version3.pl
+
 EXTRA_DIST = $(TESTS)
index 1401eb9..4ed8c1e 100644 (file)
@@ -1,4 +1,4 @@
-# Makefile.in generated by automake 1.11 from Makefile.am.
+# Makefile.in generated by automake 1.11a from Makefile.am.
 # @configure_input@
 
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
@@ -55,14 +55,20 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/amversion.m4 \
        $(top_srcdir)/m4/install-sh.m4 $(top_srcdir)/m4/lead-dot.m4 \
        $(top_srcdir)/m4/missing.m4 $(top_srcdir)/m4/mkdirp.m4 \
        $(top_srcdir)/m4/options.m4 $(top_srcdir)/m4/runlog.m4 \
-       $(top_srcdir)/m4/sanity.m4 $(top_srcdir)/m4/strip.m4 \
-       $(top_srcdir)/m4/substnot.m4 $(top_srcdir)/m4/tar.m4 \
-       $(top_srcdir)/configure.ac
+       $(top_srcdir)/m4/sanity.m4 $(top_srcdir)/m4/silent.m4 \
+       $(top_srcdir)/m4/strip.m4 $(top_srcdir)/m4/substnot.m4 \
+       $(top_srcdir)/m4/tar.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
        $(ACLOCAL_M4)
 mkinstalldirs = $(SHELL) $(top_srcdir)/lib/mkinstalldirs
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN     " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 # If stdout is a non-dumb tty, use colors.  If test -t is not supported,
@@ -150,6 +156,7 @@ TEST_LOGS_TMP = $(TEST_LOGS:.log=.log-t)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 APIVERSION = @APIVERSION@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -244,11 +251,25 @@ TEST_EXTENSIONS = .pl
 TESTS = \
 Condition.pl \
 Condition-t.pl \
+Cond2.pl \
+Cond3.pl \
 DisjConditions.pl \
 DisjConditions-t.pl \
+DisjCon2.pl \
+DisjCon3.pl \
 Version.pl \
+Version2.pl \
+Version3.pl \
 Wrap.pl
 
+XFAIL_TESTS = \
+Cond2.pl \
+Cond3.pl \
+DisjCon2.pl \
+DisjCon3.pl \
+Version2.pl \
+Version3.pl
+
 EXTRA_DIST = $(TESTS)
 all: all-am
 
@@ -290,6 +311,8 @@ TAGS:
 ctags: CTAGS
 CTAGS:
 
+cscope cscopelist:
+
 
 # To be appended to the command running the test.  Handle the stdout
 # and stderr redirection, and catch the exit status.
index e496435..bea91f0 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright (C) 2002, 2003  Free Software Foundation, Inc.
+# Copyright (C) 2002, 2003, 2009  Free Software Foundation, Inc.
 #
 # This file is part of GNU Automake.
 #
@@ -42,6 +42,29 @@ sub test_version_compare
     print "compare (\"$left\", \"$right\") = $res! (not $result?)\n";
     $failed = 1;
   }
+
+  my $check_expected = ($result == 0 || $result == 1) ? 0 : 1;
+  # Exception for 'foo' fork.
+  $check_expected = 1
+    if ($right =~ /foo/ && !($left =~ /foo/));
+
+  my $check = Automake::Version::check ($left, $right);
+  if ($check != $check_expected)
+  {
+    print "check (\"$left\", \"$right\") = $check! (not $check_expected?)\n";
+    $failed = 1;
+  }
+}
+
+sub test_bad_versions
+{
+  my ($ver) = @_;
+  my @version = Automake::Version::split ($ver);
+  if ($#version != -1)
+  {
+    print "shouldn't grok \"$ver\"\n";
+    $failed = 1;
+  }
 }
 
 my @tests = (
@@ -69,15 +92,24 @@ my @tests = (
   ['1.5a', '1.5.1f', 1],
   ['1.5', '1.5.1a', -1],
   ['1.5.1a', '1.5.1f', -1],
+  ['1.5.1f', '1.5.1a', 1],
+  ['1.5.1f', '1.5.1f', 0],
 # special exceptions
   ['1.6-p5a', '1.6.5a', 0],
   ['1.6', '1.6-p5a', -1],
   ['1.6-p4b', '1.6-p5a', -1],
   ['1.6-p4b', '1.6-foo', 1],
-  ['1.6-p4b', '1.6a-foo', -1]
+  ['1.6-p4b', '1.6a-foo', -1],
+  ['1.6-p5', '1.6.5', 0],
+  ['1.6a-foo', '1.6a-foo', 0],
+);
+
+my @bad_versions = (
+  '', 'a', '1', '1a', '1.2.3.4', '-1.2'
 );
 
 test_version_compare (@{$_}) foreach @tests;
+test_bad_versions ($_) foreach @bad_versions;
 
 exit $failed;
 
diff --git a/lib/Automake/tests/Version2.pl b/lib/Automake/tests/Version2.pl
new file mode 100644 (file)
index 0000000..038466d
--- /dev/null
@@ -0,0 +1,5 @@
+# prog_error due to invalid $VERSION.
+
+use Automake::Version;
+
+Automake::Version::check ('', '1.2.3');
diff --git a/lib/Automake/tests/Version3.pl b/lib/Automake/tests/Version3.pl
new file mode 100644 (file)
index 0000000..ebac23f
--- /dev/null
@@ -0,0 +1,5 @@
+# prog_error due to invalid $REQUIRED.
+
+use Automake::Version;
+
+Automake::Version::check ('1.2.3', '');
index 8d840fc..b415401 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright (C) 2003  Free Software Foundation, Inc.
+# Copyright (C) 2003, 2009  Free Software Foundation, Inc.
 #
 # This file is part of GNU Automake.
 #
@@ -15,7 +15,7 @@
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-use Automake::Wrap 'wrap';
+use Automake::Wrap qw/wrap makefile_wrap/;
 
 my $failed = 0;
 
@@ -31,6 +31,18 @@ sub test_wrap
     }
 }
 
+sub test_makefile_wrap
+{
+  my ($in, $exp_out) = @_;
+
+  my $out = &makefile_wrap (@$in);
+  if ($out ne $exp_out)
+    {
+      print STDERR "For: @$in\nGot:\n$out\nInstead of:\n$exp_out\n---\n";
+      ++$failed;
+    }
+}
+
 my @tests = (
   [["HEAD:", "NEXT:", "CONT", 13, "v" ,"a", "l", "ue", "s", "values"],
 "HEAD:v aCONT
@@ -55,10 +67,32 @@ big continuation:diag3
 "big header: END
 cont: word1 END
 cont: word2
+"],
+  [["big header:", "", " END", 16, "w1", "w2 ", "w3"],
+"big header: END
+w1 w2 w3
 "]);
 
+my @makefile_tests = (
+  [["target:"],
+"target:
+"],
+  [["target:", "\t"],
+"target:
+"],
+  [["target:", "\t", "prereq1", "prereq2"],
+"target: prereq1 prereq2
+"],
+  [["target: ", "\t", "this is a long list of prerequisites ending in space",
+    "so that there is no need for another space before the backslash",
+    "unlike in the second line"],
+"target: this is a long list of prerequisites ending in space \\
+\tso that there is no need for another space before the backslash \\
+\tunlike in the second line
+"]);
 
 test_wrap (@{$_}) foreach @tests;
+test_makefile_wrap (@{$_}) foreach @makefile_tests;
 
 exit $failed;
 
index f90b085..f13650b 100644 (file)
@@ -1,4 +1,4 @@
-# Makefile.in generated by automake 1.11 from Makefile.am.
+# Makefile.in generated by automake 1.11a from Makefile.am.
 # @configure_input@
 
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
@@ -60,14 +60,20 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/amversion.m4 \
        $(top_srcdir)/m4/install-sh.m4 $(top_srcdir)/m4/lead-dot.m4 \
        $(top_srcdir)/m4/missing.m4 $(top_srcdir)/m4/mkdirp.m4 \
        $(top_srcdir)/m4/options.m4 $(top_srcdir)/m4/runlog.m4 \
-       $(top_srcdir)/m4/sanity.m4 $(top_srcdir)/m4/strip.m4 \
-       $(top_srcdir)/m4/substnot.m4 $(top_srcdir)/m4/tar.m4 \
-       $(top_srcdir)/configure.ac
+       $(top_srcdir)/m4/sanity.m4 $(top_srcdir)/m4/silent.m4 \
+       $(top_srcdir)/m4/strip.m4 $(top_srcdir)/m4/substnot.m4 \
+       $(top_srcdir)/m4/tar.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
        $(ACLOCAL_M4)
 mkinstalldirs = $(SHELL) $(top_srcdir)/lib/mkinstalldirs
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN     " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
@@ -136,6 +142,7 @@ am__relativize = \
   reldir="$$dir2"
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 APIVERSION = @APIVERSION@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -377,6 +384,10 @@ ctags-recursive:
        list='$(SUBDIRS)'; for subdir in $$list; do \
          test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
        done
+cscopelist-recursive:
+       list='$(SUBDIRS)'; for subdir in $$list; do \
+         test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) cscopelist); \
+       done
 
 ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
        list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
@@ -440,6 +451,20 @@ GTAGS:
          && $(am__cd) $(top_srcdir) \
          && gtags -i $(GTAGS_ARGS) "$$here"
 
+cscopelist: cscopelist-recursive $(HEADERS) $(SOURCES) $(LISP)
+       list='$(SOURCES) $(HEADERS) $(LISP)'; \
+       case "$(srcdir)" in \
+         [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
+         *) sdir=$(subdir)/$(srcdir) ;; \
+       esac; \
+       for i in $$list; do \
+         if test -f "$$i"; then \
+           echo "$(subdir)/$$i"; \
+         else \
+           echo "$$sdir/$$i"; \
+         fi; \
+       done >> $(top_builddir)/cscope.files
+
 distclean-tags:
        -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 
@@ -601,22 +626,24 @@ ps-am:
 
 uninstall-am: uninstall-dist_pkgvdataDATA uninstall-dist_scriptDATA
 
-.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) ctags-recursive \
-       install-am install-data-am install-strip tags-recursive
+.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) \
+       cscopelist-recursive ctags-recursive install-am \
+       install-data-am install-strip tags-recursive
 
 .PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
-       all all-am check check-am clean clean-generic ctags \
-       ctags-recursive distclean distclean-generic distclean-tags \
-       distdir dvi dvi-am html html-am info info-am install \
-       install-am install-data install-data-am install-data-hook \
-       install-dist_pkgvdataDATA install-dist_scriptDATA install-dvi \
-       install-dvi-am install-exec install-exec-am install-html \
-       install-html-am install-info install-info-am install-man \
-       install-pdf install-pdf-am install-ps install-ps-am \
-       install-strip installcheck installcheck-am installcheck-local \
-       installdirs installdirs-am maintainer-clean \
-       maintainer-clean-generic mostlyclean mostlyclean-generic pdf \
-       pdf-am ps ps-am tags tags-recursive uninstall uninstall-am \
+       all all-am check check-am clean clean-generic cscopelist \
+       cscopelist-recursive ctags ctags-recursive distclean \
+       distclean-generic distclean-tags distdir dvi dvi-am html \
+       html-am info info-am install install-am install-data \
+       install-data-am install-data-hook install-dist_pkgvdataDATA \
+       install-dist_scriptDATA install-dvi install-dvi-am \
+       install-exec install-exec-am install-html install-html-am \
+       install-info install-info-am install-man install-pdf \
+       install-pdf-am install-ps install-ps-am install-strip \
+       installcheck installcheck-am installcheck-local installdirs \
+       installdirs-am maintainer-clean maintainer-clean-generic \
+       mostlyclean mostlyclean-generic pdf pdf-am ps ps-am tags \
+       tags-recursive uninstall uninstall-am \
        uninstall-dist_pkgvdataDATA uninstall-dist_scriptDATA
 
 
index 8924d17..acc5d9a 100644 (file)
@@ -1,4 +1,4 @@
-# Makefile.in generated by automake 1.11 from Makefile.am.
+# Makefile.in generated by automake 1.11a from Makefile.am.
 # @configure_input@
 
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
@@ -58,14 +58,20 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/amversion.m4 \
        $(top_srcdir)/m4/install-sh.m4 $(top_srcdir)/m4/lead-dot.m4 \
        $(top_srcdir)/m4/missing.m4 $(top_srcdir)/m4/mkdirp.m4 \
        $(top_srcdir)/m4/options.m4 $(top_srcdir)/m4/runlog.m4 \
-       $(top_srcdir)/m4/sanity.m4 $(top_srcdir)/m4/strip.m4 \
-       $(top_srcdir)/m4/substnot.m4 $(top_srcdir)/m4/tar.m4 \
-       $(top_srcdir)/configure.ac
+       $(top_srcdir)/m4/sanity.m4 $(top_srcdir)/m4/silent.m4 \
+       $(top_srcdir)/m4/strip.m4 $(top_srcdir)/m4/substnot.m4 \
+       $(top_srcdir)/m4/tar.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
        $(ACLOCAL_M4)
 mkinstalldirs = $(SHELL) $(top_srcdir)/lib/mkinstalldirs
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN     " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
@@ -94,6 +100,7 @@ DATA = $(dist_am_DATA)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 APIVERSION = @APIVERSION@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -285,6 +292,8 @@ TAGS:
 ctags: CTAGS
 CTAGS:
 
+cscope cscopelist:
+
 
 distdir: $(DISTFILES)
        @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
index 3674fee..9a193a4 100644 (file)
@@ -1,6 +1,6 @@
 ## automake - create Makefile.in from Makefile.am
 ## Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-## 2003, 2004, 2006, 2008, 2009  Free Software Foundation, Inc.
+## 2003, 2004, 2006, 2008, 2009, 2010  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
@@ -71,18 +71,17 @@ if %FASTDEP%
 ?GENERIC??SUBDIROBJ?   %COMPILE% -MT %OBJ% -MD -MP -MF %DEPBASE%.Tpo %-c% -o %OBJ% %SOURCEFLAG%%SOURCE% &&\
 ?GENERIC??SUBDIROBJ?   $(am__mv) %DEPBASE%.Tpo %DEPBASE%.Po
 else !%FASTDEP%
-?VERBOSE?      %VERBOSE% @AM_BACKSLASH@
 if %AMDEP%
-       source='%SOURCE%' object='%OBJ%' libtool=no @AMDEPBACKSLASH@
+       %VERBOSE%source='%SOURCE%' object='%OBJ%' libtool=no @AMDEPBACKSLASH@
        DEPDIR=$(DEPDIR) $(%FPFX%DEPMODE) $(depcomp) @AMDEPBACKSLASH@
 endif %AMDEP%
 if %?GENERIC%
-?-o?   %COMPILE% %-c% %-o% %OBJ% %SOURCEFLAG%%SOURCE%
-?!-o?  %COMPILE% %-c% %SOURCEFLAG%%SOURCE%
+?-o?   %VERBOSE-NODEP%%COMPILE% %-c% %-o% %OBJ% %SOURCEFLAG%%SOURCE%
+?!-o?  %VERBOSE-NODEP%%COMPILE% %-c% %SOURCEFLAG%%SOURCE%
 else !%?GENERIC%
 ## For non-suffix rules, we must emulate a VPATH search on %SOURCE%.
-?-o?   %COMPILE% %-c% %-o% %OBJ% %SOURCEFLAG%`test -f '%SOURCE%' || echo '$(srcdir)/'`%SOURCE%
-?!-o?  %COMPILE% %-c% %SOURCEFLAG%`test -f '%SOURCE%' || echo '$(srcdir)/'`%SOURCE%
+?-o?   %VERBOSE-NODEP%%COMPILE% %-c% %-o% %OBJ% %SOURCEFLAG%`test -f '%SOURCE%' || echo '$(srcdir)/'`%SOURCE%
+?!-o?  %VERBOSE-NODEP%%COMPILE% %-c% %SOURCEFLAG%`test -f '%SOURCE%' || echo '$(srcdir)/'`%SOURCE%
 endif !%?GENERIC%
 endif !%FASTDEP%
 
@@ -99,18 +98,17 @@ if %FASTDEP%
 ?GENERIC??SUBDIROBJ?   %COMPILE% -MT %OBJOBJ% -MD -MP -MF %DEPBASE%.Tpo %-c% -o %OBJOBJ% %SOURCEFLAG%`$(CYGPATH_W) '%SOURCE%'` &&\
 ?GENERIC??SUBDIROBJ?   $(am__mv) %DEPBASE%.Tpo %DEPBASE%.Po
 else !%FASTDEP%
-?VERBOSE?      %VERBOSE% @AM_BACKSLASH@
 if %AMDEP%
-       source='%SOURCE%' object='%OBJOBJ%' libtool=no @AMDEPBACKSLASH@
+       %VERBOSE%source='%SOURCE%' object='%OBJOBJ%' libtool=no @AMDEPBACKSLASH@
        DEPDIR=$(DEPDIR) $(%FPFX%DEPMODE) $(depcomp) @AMDEPBACKSLASH@
 endif %AMDEP%
 if %?GENERIC%
-?-o?   %COMPILE% %-c% %-o% %OBJOBJ% %SOURCEFLAG%`$(CYGPATH_W) '%SOURCE%'`
-?!-o?  %COMPILE% %-c% `$(CYGPATH_W) %SOURCEFLAG%'%SOURCE%'`
+?-o?   %VERBOSE-NODEP%%COMPILE% %-c% %-o% %OBJOBJ% %SOURCEFLAG%`$(CYGPATH_W) '%SOURCE%'`
+?!-o?  %VERBOSE-NODEP%%COMPILE% %-c% `$(CYGPATH_W) %SOURCEFLAG%'%SOURCE%'`
 else !%?GENERIC%
 ## For non-suffix rules, we must emulate a VPATH search on %SOURCE%.
-?-o?   %COMPILE% %-c% %-o% %OBJOBJ% %SOURCEFLAG%`if test -f '%SOURCE%'; then $(CYGPATH_W) '%SOURCE%'; else $(CYGPATH_W) '$(srcdir)/%SOURCE%'; fi`
-?!-o?  %COMPILE% %-c% %SOURCEFLAG%`if test -f '%SOURCE%'; then $(CYGPATH_W) '%SOURCE%'; else $(CYGPATH_W) '$(srcdir)/%SOURCE%'; fi`
+?-o?   %VERBOSE-NODEP%%COMPILE% %-c% %-o% %OBJOBJ% %SOURCEFLAG%`if test -f '%SOURCE%'; then $(CYGPATH_W) '%SOURCE%'; else $(CYGPATH_W) '$(srcdir)/%SOURCE%'; fi`
+?!-o?  %VERBOSE-NODEP%%COMPILE% %-c% %SOURCEFLAG%`if test -f '%SOURCE%'; then $(CYGPATH_W) '%SOURCE%'; else $(CYGPATH_W) '$(srcdir)/%SOURCE%'; fi`
 endif !%?GENERIC%
 endif !%FASTDEP%
 endif %?NONLIBTOOL%
@@ -129,14 +127,13 @@ if %FASTDEP%
 ?GENERIC??SUBDIROBJ?   %LTCOMPILE% -MT %LTOBJ% -MD -MP -MF %DEPBASE%.Tpo %-c% -o %LTOBJ% %SOURCEFLAG%%SOURCE% &&\
 ?GENERIC??SUBDIROBJ?   $(am__mv) %DEPBASE%.Tpo %DEPBASE%.Plo
 else !%FASTDEP%
-?VERBOSE?      %VERBOSE% @AM_BACKSLASH@
 if %AMDEP%
-       source='%SOURCE%' object='%LTOBJ%' libtool=yes @AMDEPBACKSLASH@
+       %VERBOSE%source='%SOURCE%' object='%LTOBJ%' libtool=yes @AMDEPBACKSLASH@
        DEPDIR=$(DEPDIR) $(%FPFX%DEPMODE) $(depcomp) @AMDEPBACKSLASH@
 endif %AMDEP%
 ## We can always use `-o' with Libtool.
-?GENERIC?      %LTCOMPILE% %-c% -o %LTOBJ% %SOURCEFLAG%%SOURCE%
+?GENERIC?      %VERBOSE-NODEP%%LTCOMPILE% %-c% -o %LTOBJ% %SOURCEFLAG%%SOURCE%
 ## For non-suffix rules, we must emulate a VPATH search on %SOURCE%.
-?!GENERIC?     %LTCOMPILE% %-c% -o %LTOBJ% %SOURCEFLAG%`test -f '%SOURCE%' || echo '$(srcdir)/'`%SOURCE%
+?!GENERIC?     %VERBOSE-NODEP%%LTCOMPILE% %-c% -o %LTOBJ% %SOURCEFLAG%`test -f '%SOURCE%' || echo '$(srcdir)/'`%SOURCE%
 endif !%FASTDEP%
 endif %?LIBTOOL%
index d88656c..fd82838 100644 (file)
@@ -26,7 +26,7 @@ am__remove_distdir = \
   { test ! -d "$(distdir)" \
     || { find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \
          && rm -fr "$(distdir)"; }; }
-
+am__post_remove_distdir = $(am__remove_distdir)
 endif %?TOPDIR_P%
 
 if %?SUBDIRS%
@@ -328,6 +328,10 @@ endif %?TOPDIR_P%
 ## with tar 1.11.2).  We do not do anything specific w.r.t. this
 ## incompatibility since packages where empty directories need to be
 ## present in the archive are really unusual.
+##
+## We order DIST_TARGETS by expected duration of the compressors,
+## slowest first, for better parallelism in `make dist'.  Do not
+## reorder DIST_ARCHIVES, users may expect gzip to be first.
 
 if %?TOPDIR_P%
 
@@ -336,44 +340,59 @@ GZIP_ENV = --best
 .PHONY: dist-gzip
 dist-gzip: distdir
        tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz
-       $(am__remove_distdir)
+       $(am__post_remove_distdir)
 
 ?BZIP2?DIST_ARCHIVES += $(distdir).tar.bz2
 .PHONY: dist-bzip2
 dist-bzip2: distdir
        tardir=$(distdir) && $(am__tar) | bzip2 -9 -c >$(distdir).tar.bz2
-       $(am__remove_distdir)
+       $(am__post_remove_distdir)
+
+?LZIP?DIST_ARCHIVES += $(distdir).tar.lz
+.PHONY: dist-lzip
+dist-lzip: distdir
+       tardir=$(distdir) && $(am__tar) | lzip -9 -c >$(distdir).tar.lz
+       $(am__post_remove_distdir)
 
 ?LZMA?DIST_ARCHIVES += $(distdir).tar.lzma
 .PHONY: dist-lzma
 dist-lzma: distdir
        tardir=$(distdir) && $(am__tar) | lzma -9 -c >$(distdir).tar.lzma
-       $(am__remove_distdir)
+       $(am__post_remove_distdir)
 
 ?XZ?DIST_ARCHIVES += $(distdir).tar.xz
 .PHONY: dist-xz
 dist-xz: distdir
        tardir=$(distdir) && $(am__tar) | xz -9 -c >$(distdir).tar.xz
-       $(am__remove_distdir)
+       $(am__post_remove_distdir)
 
 ?COMPRESS?DIST_ARCHIVES += $(distdir).tar.Z
 .PHONY: dist-tarZ
 dist-tarZ: distdir
        tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z
-       $(am__remove_distdir)
+       $(am__post_remove_distdir)
 
 ?SHAR?DIST_ARCHIVES += $(distdir).shar.gz
 .PHONY: dist-shar
 dist-shar: distdir
        shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz
-       $(am__remove_distdir)
+       $(am__post_remove_distdir)
 
 ?ZIP?DIST_ARCHIVES += $(distdir).zip
 .PHONY: dist-zip
 dist-zip: distdir
        -rm -f $(distdir).zip
        zip -rq $(distdir).zip $(distdir)
-       $(am__remove_distdir)
+       $(am__post_remove_distdir)
+
+?LZMA?DIST_TARGETS += dist-lzma
+?LZIP?DIST_TARGETS += dist-lzip
+?XZ?DIST_TARGETS += dist-xz
+?SHAR?DIST_TARGETS += dist-shar
+?BZIP2?DIST_TARGETS += dist-bzip2
+?GZIP?DIST_TARGETS += dist-gzip
+?ZIP?DIST_TARGETS += dist-zip
+?COMPRESS?DIST_TARGETS += dist-tarZ
 
 endif %?TOPDIR_P%
 
@@ -393,16 +412,9 @@ if %?SUBDIRS%
 AM_RECURSIVE_TARGETS += dist dist-all
 endif %?SUBDIRS%
 
-dist dist-all: distdir
-?GZIP? tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz
-?BZIP2?        tardir=$(distdir) && $(am__tar) | bzip2 -9 -c >$(distdir).tar.bz2
-?LZMA? tardir=$(distdir) && $(am__tar) | lzma -9 -c >$(distdir).tar.lzma
-?XZ?   tardir=$(distdir) && $(am__tar) | xz -9 -c >$(distdir).tar.xz
-?COMPRESS?     tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z
-?SHAR? shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz
-?ZIP?  -rm -f $(distdir).zip
-?ZIP?  zip -rq $(distdir).zip $(distdir)
-       $(am__remove_distdir)
+dist dist-all:
+       $(MAKE) $(AM_MAKEFLAGS) $(DIST_TARGETS) am__post_remove_distdir='@:'
+       $(am__post_remove_distdir)
 
 endif %?TOPDIR_P%
 
@@ -429,6 +441,8 @@ distcheck: dist
          bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\
        *.tar.lzma*) \
          lzma -dc $(distdir).tar.lzma | $(am__untar) ;;\
+       *.tar.lz*) \
+         lzip -dc $(distdir).tar.lz | $(am__untar) ;;\
        *.tar.xz*) \
          xz -dc $(distdir).tar.xz | $(am__untar) ;;\
        *.tar.Z*) \
@@ -505,7 +519,7 @@ distcheck: dist
 ## Cater to parallel BSD make (see above).
          && cd "$$am__cwd" \
          || exit 1
-       $(am__remove_distdir)
+       $(am__post_remove_distdir)
        @(echo "$(distdir) archives ready for distribution: "; \
          list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \
          sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x'
index 7463e2f..7fa75c9 100644 (file)
@@ -134,6 +134,43 @@ GTAGS:
          && gtags -i $(GTAGS_ARGS) "$$here"
 
 
+## ------- ##
+## cscope  ##
+## ------- ##
+
+if %?TOPDIR_P%
+
+CSCOPE = cscope
+.PHONY: cscope clean-cscope
+AM_RECURSIVE_TARGETS += cscope
+
+cscope: cscope.files
+       test ! -s cscope.files \
+         || $(CSCOPE) -b -q $(AM_CSCOPEFLAGS) $(CSCOPEFLAGS) -i cscope.files $(CSCOPE_ARGS)
+
+clean-cscope:
+       -rm -f cscope.files
+
+cscope.files: clean-cscope %CSCOPEDIRS% cscopelist
+
+endif %?TOPDIR_P%
+
+.PHONY: cscopelist
+cscopelist: %CSCOPEDIRS% $(HEADERS) $(SOURCES) $(LISP)
+       list='$(SOURCES) $(HEADERS) $(LISP)'; \
+       case "$(srcdir)" in \
+         [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
+         *) sdir=$(subdir)/$(srcdir) ;; \
+       esac; \
+       for i in $$list; do \
+         if test -f "$$i"; then \
+           echo "$(subdir)/$$i"; \
+         else \
+           echo "$$sdir/$$i"; \
+         fi; \
+       done >> $(top_builddir)/cscope.files
+
+
 ## ---------- ##
 ## Cleaning.  ##
 ## ---------- ##
@@ -142,3 +179,6 @@ GTAGS:
 
 distclean-tags:
        -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
+if %?TOPDIR_P%
+       -rm -f cscope.out cscope.in.out cscope.po.out cscope.files
+endif %?TOPDIR_P%
index dca9ce1..4b1add7 100644 (file)
@@ -32,7 +32,7 @@
 ##    to fail, the info files are not removed.  (They are needed by the
 ##    developer while he writes documentation.)
 ## *.iNN files are used on DJGPP.  See the comments in install-info-am
-       restore=: && backupdir="$(am__leading_dot)am$$$$" && \
+       %AM_V_MAKEINFO%restore=: && backupdir="$(am__leading_dot)am$$$$" && \
 ?INSRC?        am__cwd=`pwd` && $(am__cd) $(srcdir) && \
        rm -rf $$backupdir && mkdir $$backupdir && \
 ## If makeinfo is not installed we must not backup the files so
@@ -62,23 +62,27 @@ INFO_DEPS += %DEST_INFO_PREFIX%%DEST_SUFFIX%
 
 ?GENERIC?%SOURCE_SUFFIX%.dvi:
 ?!GENERIC?%DEST_PREFIX%.dvi: %SOURCE% %DEPS% %DIRSTAMP%
-       TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
+       %AM_V_TEXI2DVI%TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
 ## Must set MAKEINFO like this so that version.texi will be found even
 ## if it is in srcdir (-I $(srcdir) is set in %MAKEINFOFLAGS%).
        MAKEINFO='$(MAKEINFO) $(AM_MAKEINFOFLAGS) $(MAKEINFOFLAGS) %MAKEINFOFLAGS%' \
 ## Do not use `-o' unless necessary: it is only supported since Texinfo 4.1.
-?GENERIC?      $(TEXI2DVI) %SOURCE%
-?!GENERIC?     $(TEXI2DVI) -o $@ `test -f '%SOURCE%' || echo '$(srcdir)/'`%SOURCE%
+## texi2dvi doesn't silence everything with -q, redirect to /dev/null instead.
+## We still want -q (%TEXIQUIET%) because it turns on batch mode.
+?GENERIC?      $(TEXI2DVI) %TEXIQUIET% %SOURCE% %TEXIDEVNULL%
+?!GENERIC?     $(TEXI2DVI) %TEXIQUIET% -o $@ `test -f '%SOURCE%' || echo '$(srcdir)/'`%SOURCE% %TEXIDEVNULL%
 
 ?GENERIC?%SOURCE_SUFFIX%.pdf:
 ?!GENERIC?%DEST_PREFIX%.pdf: %SOURCE% %DEPS% %DIRSTAMP%
-       TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
+       %AM_V_TEXI2PDF%TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
 ## Must set MAKEINFO like this so that version.texi will be found even
 ## if it is in srcdir (-I $(srcdir) is set in %MAKEINFOFLAGS%).
        MAKEINFO='$(MAKEINFO) $(AM_MAKEINFOFLAGS) $(MAKEINFOFLAGS) %MAKEINFOFLAGS%' \
 ## Do not use `-o' unless necessary: it is only supported since Texinfo 4.1.
-?GENERIC?      $(TEXI2PDF) %SOURCE%
-?!GENERIC?     $(TEXI2PDF) -o $@ `test -f '%SOURCE%' || echo '$(srcdir)/'`%SOURCE%
+## texi2pdf doesn't silence everything with -q, redirect to /dev/null instead.
+## We still want -q (%TEXIQUIET%) because it turns on batch mode.
+?GENERIC?      $(TEXI2PDF) %TEXIQUIET% %SOURCE% %TEXIDEVNULL%
+?!GENERIC?     $(TEXI2PDF) %TEXIQUIET% -o $@ `test -f '%SOURCE%' || echo '$(srcdir)/'`%SOURCE% %TEXIDEVNULL%
 
 ?GENERIC?%SOURCE_SUFFIX%.html:
 ?!GENERIC?%DEST_PREFIX%.html: %SOURCE% %DEPS% %DIRSTAMP%
@@ -88,8 +92,8 @@ INFO_DEPS += %DEST_INFO_PREFIX%%DEST_SUFFIX%
 ## in the manual change, it may leave unused pages.  Our fix
 ## is to build under a temporary name, and replace the target on
 ## success.
-       rm -rf $(@:.html=.htp)
-       if $(MAKEINFOHTML) $(AM_MAKEINFOHTMLFLAGS) $(MAKEINFOFLAGS) %MAKEINFOFLAGS% \
+       %AM_V_MAKEINFO%rm -rf $(@:.html=.htp)
+       %SILENT%if $(MAKEINFOHTML) $(AM_MAKEINFOHTMLFLAGS) $(MAKEINFOFLAGS) %MAKEINFOFLAGS% \
 ?GENERIC?       -o $(@:.html=.htp) %SOURCE%; \
 ?!GENERIC?      -o $(@:.html=.htp) `test -f '%SOURCE%' || echo '$(srcdir)/'`%SOURCE%; \
        then \
index c9dcd9d..bfde665 100644 (file)
@@ -55,8 +55,8 @@ endif %?LOCAL-TEXIS%
 if %?LOCAL-TEXIS%
 DVIPS = dvips
 .dvi.ps:
-       TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
-       $(DVIPS) -o $@ $<
+       %AM_V_DVIPS%TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
+       $(DVIPS) %TEXIQUIET% -o $@ $<
 endif %?LOCAL-TEXIS%
 
 .PHONY: dvi dvi-am html html-am info info-am pdf pdf-am ps ps-am
index 270ee91..313a188 100644 (file)
@@ -1,4 +1,4 @@
-# Makefile.in generated by automake 1.11 from Makefile.am.
+# Makefile.in generated by automake 1.11a from Makefile.am.
 # @configure_input@
 
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
@@ -58,14 +58,20 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/amversion.m4 \
        $(top_srcdir)/m4/install-sh.m4 $(top_srcdir)/m4/lead-dot.m4 \
        $(top_srcdir)/m4/missing.m4 $(top_srcdir)/m4/mkdirp.m4 \
        $(top_srcdir)/m4/options.m4 $(top_srcdir)/m4/runlog.m4 \
-       $(top_srcdir)/m4/sanity.m4 $(top_srcdir)/m4/strip.m4 \
-       $(top_srcdir)/m4/substnot.m4 $(top_srcdir)/m4/tar.m4 \
-       $(top_srcdir)/configure.ac
+       $(top_srcdir)/m4/sanity.m4 $(top_srcdir)/m4/silent.m4 \
+       $(top_srcdir)/m4/strip.m4 $(top_srcdir)/m4/substnot.m4 \
+       $(top_srcdir)/m4/tar.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
        $(ACLOCAL_M4)
 mkinstalldirs = $(SHELL) $(top_srcdir)/lib/mkinstalldirs
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN     " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
@@ -94,6 +100,7 @@ DATA = $(dist_m4data_DATA)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 APIVERSION = @APIVERSION@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -282,6 +289,8 @@ TAGS:
 ctags: CTAGS
 CTAGS:
 
+cscope cscopelist:
+
 
 distdir: $(DISTFILES)
        @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
index aae0c28..ff3a85e 100644 (file)
 # generated from the m4 files accompanying Automake X.Y.
 # (This private macro should not be called outside this file.)
 AC_DEFUN([AM_AUTOMAKE_VERSION],
-[am__api_version='1.11'
+[am__api_version='1.11a'
 dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
 dnl require some minimum version.  Point them to the right macro.
-m4_if([$1], [1.11], [],
+m4_if([$1], [1.11a], [],
       [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
 ])
 
@@ -31,7 +31,7 @@ m4_define([_AM_AUTOCONF_VERSION], [])
 # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
 # This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
 AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
-[AM_AUTOMAKE_VERSION([1.11])dnl
+[AM_AUTOMAKE_VERSION([1.11a])dnl
 m4_ifndef([AC_AUTOCONF_VERSION],
   [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
 _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
index efe8643..8304180 100644 (file)
@@ -1,12 +1,12 @@
 ##                                                          -*- Autoconf -*-
-# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2009
-# Free Software Foundation, Inc.
+# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2009,
+# 2010  Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 
-# serial 10
+# serial 11
 
 # There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
 # written in clear, in which case automake, when reading aclocal.m4,
@@ -175,8 +175,11 @@ AC_DEFUN([AM_DEP_TRACK],
 if test "x$enable_dependency_tracking" != xno; then
   am_depcomp="$ac_aux_dir/depcomp"
   AMDEPBACKSLASH='\'
+  am__nodep='_no'
 fi
 AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
 AC_SUBST([AMDEPBACKSLASH])dnl
 _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
+AC_SUBST([am__nodep])dnl
+_AM_SUBST_NOTMAKE([am__nodep])dnl
 ])
index 3c1f990..61b0783 100644 (file)
@@ -6,3 +6,4 @@ parallel-tests.am
 *.log
 *.log-t
 *-p.test
+*-p.test-t
index eb63337..f51ebd7 100644 (file)
@@ -26,13 +26,17 @@ txinfo5.test
 include $(srcdir)/parallel-tests.am
 
 $(srcdir)/parallel-tests.am: gen-parallel-tests Makefile.am
-       (cd $(srcdir) && $(SHELL) ./gen-parallel-tests) >$@
+       $(AM_V_GEN)(cd $(srcdir) && $(SHELL) ./gen-parallel-tests) >$@
 
-$(parallel_tests): $(parallel_tests:-p.test=.test) Makefile.am
-       input=`echo $@ | sed 's,.*/,,; s,-p.test$$,.test,'`; \
-       sed 's|^\. \./defs.*|parallel_tests=yes; &|' \
-         < $(srcdir)/$$input >$@
-       chmod a+rx $@
+$(parallel_tests): Makefile.am
+       $(AM_V_at)rm -f $@ $@-t
+       $(AM_V_GEN)input=`echo $@ | sed 's,.*/,,; s,-p.test$$,.test,'`; \
+       { echo '#!/bin/sh'; \
+         echo '# DO NOT EDIT! GENERATED AUTOMATICALLY!'; \
+         echo 'parallel_tests=yes'; \
+         echo ". '$(srcdir)/$$input'"; \
+       } > $@-t
+       $(AM_V_at)chmod a+rx $@-t && mv -f $@-t $@
 
 MAINTAINERCLEANFILES = $(parallel_tests)
 
@@ -111,6 +115,7 @@ badopt.test \
 badprog.test \
 block.test \
 bsource.test \
+candist.test \
 canon.test \
 canon2.test \
 canon3.test \
@@ -203,6 +208,7 @@ cond42.test \
 cond43.test \
 cond44.test \
 cond45.test \
+cond46.test \
 condd.test \
 condhook.test \
 condinc.test \
@@ -227,6 +233,9 @@ confsub.test \
 confvar.test \
 confvar2.test \
 copy.test \
+cscope.test \
+cscope2.test \
+cscope3.test \
 ctarget1.test \
 cxx.test \
 cxx2.test \
@@ -297,6 +306,7 @@ exeext4.test \
 exsource.test \
 ext.test \
 ext2.test \
+ext3.test \
 extra.test \
 extra2.test \
 extra3.test \
@@ -305,6 +315,7 @@ extra5.test \
 extra6.test \
 extra7.test \
 extra8.test \
+extra9.test \
 extra10.test \
 extra11.test \
 extra12.test \
@@ -425,6 +436,7 @@ link_fc.test \
 link_fccxx.test \
 link_fcxx.test \
 link_f_only.test \
+link_override.test \
 lisp2.test \
 lisp3.test \
 lisp4.test \
@@ -444,6 +456,7 @@ ltinstloc.test \
 ltlibobjs.test \
 ltlibsrc.test \
 ltorder.test \
+lzip.test \
 lzma.test \
 maintclean.test \
 make.test \
@@ -607,6 +620,8 @@ silent4.test \
 silent5.test \
 silent6.test \
 silent7.test \
+silent8.test \
+silent9.test \
 sinclude.test \
 srcsub.test \
 srcsub2.test \
@@ -662,6 +677,7 @@ subst.test \
 subst2.test \
 subst3.test \
 subst4.test \
+subst5.test \
 substref.test \
 substre2.test \
 substtarg.test \
index 58e7554..387af70 100644 (file)
@@ -1,4 +1,4 @@
-# Makefile.in generated by automake 1.11 from Makefile.am.
+# Makefile.in generated by automake 1.11a from Makefile.am.
 # @configure_input@
 
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
@@ -58,14 +58,20 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/amversion.m4 \
        $(top_srcdir)/m4/install-sh.m4 $(top_srcdir)/m4/lead-dot.m4 \
        $(top_srcdir)/m4/missing.m4 $(top_srcdir)/m4/mkdirp.m4 \
        $(top_srcdir)/m4/options.m4 $(top_srcdir)/m4/runlog.m4 \
-       $(top_srcdir)/m4/sanity.m4 $(top_srcdir)/m4/strip.m4 \
-       $(top_srcdir)/m4/substnot.m4 $(top_srcdir)/m4/tar.m4 \
-       $(top_srcdir)/configure.ac
+       $(top_srcdir)/m4/sanity.m4 $(top_srcdir)/m4/silent.m4 \
+       $(top_srcdir)/m4/strip.m4 $(top_srcdir)/m4/substnot.m4 \
+       $(top_srcdir)/m4/tar.m4 $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
        $(ACLOCAL_M4)
 mkinstalldirs = $(SHELL) $(top_srcdir)/lib/mkinstalldirs
 CONFIG_CLEAN_FILES = defs aclocal-${APIVERSION} automake-${APIVERSION}
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN     " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 DIST_SOURCES =
 # If stdout is a non-dumb tty, use colors.  If test -t is not supported,
@@ -155,6 +161,7 @@ TEST_LOGS_TMP = $(TEST_LOGS:.log=.log-t)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 APIVERSION = @APIVERSION@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -348,6 +355,7 @@ badopt.test \
 badprog.test \
 block.test \
 bsource.test \
+candist.test \
 canon.test \
 canon2.test \
 canon3.test \
@@ -440,6 +448,7 @@ cond42.test \
 cond43.test \
 cond44.test \
 cond45.test \
+cond46.test \
 condd.test \
 condhook.test \
 condinc.test \
@@ -464,6 +473,9 @@ confsub.test \
 confvar.test \
 confvar2.test \
 copy.test \
+cscope.test \
+cscope2.test \
+cscope3.test \
 ctarget1.test \
 cxx.test \
 cxx2.test \
@@ -534,6 +546,7 @@ exeext4.test \
 exsource.test \
 ext.test \
 ext2.test \
+ext3.test \
 extra.test \
 extra2.test \
 extra3.test \
@@ -542,6 +555,7 @@ extra5.test \
 extra6.test \
 extra7.test \
 extra8.test \
+extra9.test \
 extra10.test \
 extra11.test \
 extra12.test \
@@ -662,6 +676,7 @@ link_fc.test \
 link_fccxx.test \
 link_fcxx.test \
 link_f_only.test \
+link_override.test \
 lisp2.test \
 lisp3.test \
 lisp4.test \
@@ -681,6 +696,7 @@ ltinstloc.test \
 ltlibobjs.test \
 ltlibsrc.test \
 ltorder.test \
+lzip.test \
 lzma.test \
 maintclean.test \
 make.test \
@@ -844,6 +860,8 @@ silent4.test \
 silent5.test \
 silent6.test \
 silent7.test \
+silent8.test \
+silent9.test \
 sinclude.test \
 srcsub.test \
 srcsub2.test \
@@ -899,6 +917,7 @@ subst.test \
 subst2.test \
 subst3.test \
 subst4.test \
+subst5.test \
 substref.test \
 substre2.test \
 substtarg.test \
@@ -1049,6 +1068,8 @@ TAGS:
 ctags: CTAGS
 CTAGS:
 
+cscope cscopelist:
+
 
 # To be appended to the command running the test.  Handle the stdout
 # and stderr redirection, and catch the exit status.
@@ -1353,13 +1374,17 @@ uninstall-am:
 
 
 $(srcdir)/parallel-tests.am: gen-parallel-tests Makefile.am
-       (cd $(srcdir) && $(SHELL) ./gen-parallel-tests) >$@
-
-$(parallel_tests): $(parallel_tests:-p.test=.test) Makefile.am
-       input=`echo $@ | sed 's,.*/,,; s,-p.test$$,.test,'`; \
-       sed 's|^\. \./defs.*|parallel_tests=yes; &|' \
-         < $(srcdir)/$$input >$@
-       chmod a+rx $@
+       $(AM_V_GEN)(cd $(srcdir) && $(SHELL) ./gen-parallel-tests) >$@
+
+$(parallel_tests): Makefile.am
+       $(AM_V_at)rm -f $@ $@-t
+       $(AM_V_GEN)input=`echo $@ | sed 's,.*/,,; s,-p.test$$,.test,'`; \
+       { echo '#!/bin/sh'; \
+         echo '# DO NOT EDIT! GENERATED AUTOMATICALLY!'; \
+         echo 'parallel_tests=yes'; \
+         echo ". '$(srcdir)/$$input'"; \
+       } > $@-t
+       $(AM_V_at)chmod a+rx $@-t && mv -f $@-t $@
 
 clean-local: clean-local-check
 .PHONY: clean-local-check
index 095d176..c34bfd8 100644 (file)
@@ -5,15 +5,33 @@ User interface
 ==============
 
 
-Running all tests
+Running the tests
 -----------------
 
-  make check
+  To run all tests:
+
+    make -k check
 
   You can use `-jN' for faster completion (it even helps on a
   uniprocessor system, due to unavoidable sleep delays, as
   noted below).
 
+  To rerun only failed tests:
+
+    make -k recheck
+
+  To run only tests that are newer than their last results:
+
+    make -k check RECHECK_LOGS=
+
+  To run only selected tests:
+
+    make -k check TESTS="foo.test bar.test"
+
+  For non-GNU make, you might have to use this instead:
+
+    env TESTS="foo.test bar.test" make -e -k check
+
 
 Interpretation
 --------------
diff --git a/tests/candist.test b/tests/candist.test
new file mode 100755 (executable)
index 0000000..0a859dd
--- /dev/null
@@ -0,0 +1,34 @@
+#! /bin/sh
+# Copyright (C) 2009  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 3 of the License, 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/>.
+
+# Test to make sure things that cannot be dist_'ed are diagnosed.
+
+. ./defs || Exit 1
+
+set -e
+
+echo AC_OUTPUT >>configure.in
+
+cat > Makefile.am << 'END'
+dist_bin_PROGRAMS = foo
+dist_lib_LIBRARIES = libfoo.a
+END
+
+$ACLOCAL
+AUTOMAKE_fails
+test 2 -eq `grep -c 'dist.*forbidden' stderr`
+
+Exit 0
diff --git a/tests/cond46.test b/tests/cond46.test
new file mode 100755 (executable)
index 0000000..0b8696c
--- /dev/null
@@ -0,0 +1,110 @@
+#! /bin/sh
+# Copyright (C) 2009, 2010 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 3 of the License, 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/>.
+
+# Ensure the right condition is listed after `else' and `endif'.
+
+. ./defs || Exit 1
+
+set -e
+
+cat >> configure.in << 'END'
+AM_CONDITIONAL([USE_A],[test x = y])
+AM_CONDITIONAL([USE_B],[test x = z])
+AC_OUTPUT
+END
+
+$ACLOCAL
+
+cat > Makefile.am << 'END'
+if USE_A
+endif !USE_A
+END
+
+AUTOMAKE_fails
+grep 'endif.*incompatible with current conditional' stderr
+
+cat > Makefile.am << 'END'
+if USE_A
+endif USE_B
+END
+
+AUTOMAKE_fails
+grep 'endif.*incompatible with current conditional' stderr
+
+cat > Makefile.am << 'END'
+if USE_A
+else
+endif USE_A
+END
+
+AUTOMAKE_fails
+grep 'endif.*incompatible with current conditional' stderr
+
+cat > Makefile.am << 'END'
+if USE_A
+else
+endif !USE_A
+END
+
+$AUTOMAKE
+
+cat > Makefile.am << 'END'
+if USE_A
+if USE_B
+else
+endif !USE_A
+endif
+END
+
+AUTOMAKE_fails
+grep 'endif.*incompatible with current conditional' stderr
+
+cat > Makefile.am << 'END'
+if USE_A
+else USE_A
+endif
+END
+
+AUTOMAKE_fails
+grep 'else.*incompatible with current conditional' stderr
+
+cat > Makefile.am << 'END'
+if USE_A
+else USE_B
+endif
+END
+
+AUTOMAKE_fails
+grep 'else.*incompatible with current conditional' stderr
+
+cat > Makefile.am << 'END'
+if USE_A
+if USE_B
+else USE_A
+endif
+endif
+END
+
+AUTOMAKE_fails
+grep 'else.*incompatible with current conditional' stderr
+
+cat > Makefile.am << 'END'
+if USE_A
+else !USE_A
+endif
+END
+
+$AUTOMAKE
index 088fb55..69eff59 100755 (executable)
@@ -1,5 +1,6 @@
 #! /bin/sh
-# Copyright (C) 1999, 2001, 2002, 2003  Free Software Foundation, Inc.
+# Copyright (C) 1999, 2001, 2002, 2003, 2009  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
@@ -39,3 +40,23 @@ END
 $ACLOCAL
 AUTOMAKE_fails
 grep 'adjunct:3: too many conditionals closed' stderr
+
+cat > adjunct << 'END'
+if TOBE
+target: dependency
+       rule
+END
+
+AUTOMAKE_fails
+grep 'unterminated conditionals' stderr
+
+cat > adjunct << 'END'
+if TOBE
+target: dependency
+       rule
+endif
+END
+
+$AUTOMAKE
+
+Exit 0
diff --git a/tests/cscope.test b/tests/cscope.test
new file mode 100755 (executable)
index 0000000..e4a84a3
--- /dev/null
@@ -0,0 +1,109 @@
+#! /bin/sh
+# Copyright (C) 2009, 2010  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/>.
+
+# Test cscope functionality.
+
+required=
+. ./defs || Exit 1
+
+set -e
+
+cat >> configure.in << 'END'
+AC_CONFIG_FILES([sub/Makefile])
+AC_PROG_CC
+AC_PROG_CXX
+AC_PROG_FC
+AM_PROG_GCJ
+AM_PATH_LISPDIR
+AC_OUTPUT
+END
+
+mkdir sub sub/subsub
+
+cat >Makefile.am <<'END'
+SUBDIRS = sub
+bin_PROGRAMS = foo
+foo_SOURCES = foo.c bar.cpp baz.f90
+lisp_LISP = foo.el
+EXTRA_DIST = foo.el
+END
+
+cat >sub/Makefile.am <<'END'
+bin_PROGRAMS = bar
+bar_SOURCES = subsub/dist.c
+nodist_bar_SOURCES = subsub/gen.c
+subsub/gen.c:
+       $(MKDIR_P) subsub
+       echo 'int generated_subsub () { return 0; }' > $@
+CLEANFILES = subsub/gen.c
+END
+
+echo 'int foo_func () { return 0; }' > foo.c
+echo 'int main () { return 0; }' > bar.cpp
+cat > baz.f90 <<'END'
+      subroutine baz
+      end
+END
+: >foo.el
+echo 'int main () { return 0; }' > sub/subsub/dist.c
+
+$ACLOCAL
+$AUTOCONF
+$AUTOMAKE --add-missing
+
+mkdir build
+cd build
+../configure || Exit 77
+
+$MAKE -n cscope
+
+: ${CSCOPE=cscope}
+( $CSCOPE --version ) >/dev/null 2>&1 || Exit 77
+
+$MAKE cscope 2>stderr
+cat stderr >&2
+grep 'cannot find file' stderr && Exit 1
+
+test -f cscope.files
+$FGREP foo.c cscope.files
+$FGREP bar.cpp cscope.files
+$FGREP sub/subsub/dist.c cscope.files
+$FGREP sub/subsub/gen.c cscope.files
+
+cp cscope.files cscope.files1
+$MAKE cscope
+diff cscope.files cscope.files1
+
+$MAKE distclean
+test ! -f cscope.files
+test ! -f cscope.out
+test ! -f cscope.in.out
+test ! -f cscope.po.out
+
+
+`pwd`/../configure || Exit 77
+
+$MAKE cscope 2>stderr
+cat stderr >&2
+grep 'cannot find file' stderr && Exit 1
+$MAKE || Exit 77
+$MAKE distclean
+
+cd ..
+./configure
+$MAKE distcheck
+
+:
diff --git a/tests/cscope2.test b/tests/cscope2.test
new file mode 100755 (executable)
index 0000000..106b801
--- /dev/null
@@ -0,0 +1,36 @@
+#! /bin/sh
+# Copyright (C) 2009  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/>.
+
+# The `cscope' target should not fail if there are no sources.
+
+required=
+. ./defs || Exit 1
+
+set -e
+
+cat >> configure.in << 'END'
+AC_OUTPUT
+END
+: >Makefile.am
+
+$ACLOCAL
+$AUTOCONF
+$AUTOMAKE
+
+./configure
+$MAKE cscope
+
+:
diff --git a/tests/cscope3.test b/tests/cscope3.test
new file mode 100755 (executable)
index 0000000..03e1d47
--- /dev/null
@@ -0,0 +1,41 @@
+#! /bin/sh
+# Copyright (C) 2009  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/>.
+
+# The `cscope' target should not fail if there are no sources in a subdir.
+# In practice this means `cscope' should not be invoked if cscope.files
+# is empty.
+
+required=cscope
+. ./defs || Exit 1
+
+set -e
+
+cat >> configure.in << 'END'
+AC_CONFIG_FILES([sub/Makefile])
+AC_OUTPUT
+END
+mkdir sub
+echo 'SUBDIRS = sub' >Makefile.am
+: >sub/Makefile.am
+
+$ACLOCAL
+$AUTOCONF
+$AUTOMAKE
+
+./configure
+$MAKE cscope
+
+:
index 18f2aeb..497b57f 100644 (file)
@@ -170,6 +170,10 @@ do
       rm -f $priv_check_temp
       test $overwrite_status = 0 && exit 77
       ;;
+    perl-threads)
+      # Skip with Devel::Cover: it cannot cope with threads.
+      test "$WANT_NO_THREADS" = yes && exit 77
+      ;;
     python)
       # Python doesn't support --version, it has -V
       echo "$me: running python -V"
diff --git a/tests/ext3.test b/tests/ext3.test
new file mode 100755 (executable)
index 0000000..0a691c5
--- /dev/null
@@ -0,0 +1,41 @@
+#! /bin/sh
+# Copyright (C) 2009 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 3 of the License, 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/>.
+
+# Cover corner cases of derive_suffix wrt. file extensions:
+# - extension declared with SUFFIXES but with no suffix rule for it
+# - extension with a suffix rule but none that leads us to $(OBJEXT)
+# In both cases, we don't try to create a rule; but we shouldn't
+# fail either, because magic might be happening behind our back.
+
+. ./defs || Exit 1
+
+set -e
+
+cat >> configure.in << 'END'
+END
+
+cat > Makefile.am << 'END'
+bin_PROGRAMS = foo bar
+foo_SOURCES = foo.goo
+SUFFIXES = .goo
+bar_SOURCES = bar.woo
+.woo.zoo: ; making a zoo $@ from a woo $<
+END
+
+$ACLOCAL
+$AUTOMAKE
+
+Exit 0
diff --git a/tests/extra9.test b/tests/extra9.test
new file mode 100755 (executable)
index 0000000..fefd385
--- /dev/null
@@ -0,0 +1,46 @@
+#!/bin/sh
+# Copyright (C) 2009  Free Software Foundation, Inc.
+#
+# This file is part of GNU Automake.
+#
+# GNU Automake 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 3 of the License, or
+# (at your option) any later version.
+#
+# GNU Automake 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 Automake; see the file COPYING.  If not, write to
+# the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+# Boston, MA 02110-1301, USA.
+
+# Ensure we warn about substitutions in bin_PROGRAMS if EXTRA_PROGRAMS
+# are missing; but only if the former is not AC_SUBSTed itself
+# (lib_LIBRARIES is in the same boat here).
+
+. ./defs || Exit 1
+
+set -e
+
+cat >>configure.in <<'END'
+AC_PROG_CC
+AC_PROG_RANLIB
+AC_SUBST([lib_LIBRARIES])
+AC_SUBST([bins])
+AC_OUTPUT
+END
+
+cat >Makefile.am <<'END'
+bin_PROGRAMS = @bins@
+END
+
+$ACLOCAL
+AUTOMAKE_fails
+grep 'bin_PROGRAMS.*contains configure substitution' stderr
+grep 'lib_LIBRARIES.*contains configure substitution' stderr && Exit 1
+
+Exit 0
diff --git a/tests/link_override.test b/tests/link_override.test
new file mode 100755 (executable)
index 0000000..41788a1
--- /dev/null
@@ -0,0 +1,46 @@
+#! /bin/sh
+# Copyright (C) 2009 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 3 of the License, 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/>.
+
+# Test to make sure _LINK variables are detected and used as documented.
+
+. ./defs || Exit 1
+
+set -e
+
+cat >> configure.in << 'END'
+AC_PROG_CC
+END
+
+cat > Makefile.am << 'END'
+bin_PROGRAMS = foo bar baz boo
+foo_LINK = $(LINK)
+bar_LINK = $(LINK)
+bar_LDFLAGS = $(AM_LDFLAGS)
+END
+
+$ACLOCAL
+$AUTOMAKE -a
+
+# We should use foo_LINK not LINK.
+grep '.\$(foo_LINK)' Makefile.in
+grep '.\$(LINK).*foo' Makefile.in && Exit 1
+
+# We should not override the user definition of bar_LINK.
+# IOW, bar_LDFLAGS is useless unless bar_LINK refers to it.
+grep '^ *bar_LINK *=.*bar_LDFLAGS' Makefile.in && Exit 1
+grep '.\$(bar_LINK).*bar' Makefile.in
+
+Exit 0
diff --git a/tests/lzip.test b/tests/lzip.test
new file mode 100755 (executable)
index 0000000..fecbc83
--- /dev/null
@@ -0,0 +1,41 @@
+#! /bin/sh
+# Copyright (C) 2010  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 support for no-dist-gzip with lzip
+
+required=lzip
+. ./defs || Exit 1
+
+set -e
+
+cat > configure.in << 'END'
+AC_INIT([lzip], [1.0])
+AM_INIT_AUTOMAKE([no-dist-gzip dist-lzip])
+AC_CONFIG_FILES([Makefile])
+AC_OUTPUT
+END
+
+cat > Makefile.am << 'END'
+test: distcheck
+       test $(DIST_ARCHIVES) = lzip-1.0.tar.lz
+       test -f $(DIST_ARCHIVES)
+END
+
+$ACLOCAL
+$AUTOCONF
+$AUTOMAKE
+./configure
+$MAKE test
index 4aef628..c46377b 100755 (executable)
@@ -1,5 +1,5 @@
 #! /bin/sh
-# Copyright (C) 2008  Free Software Foundation, Inc.
+# Copyright (C) 2008, 2009  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
@@ -35,6 +35,7 @@
 #
 # This test checks (0), (1), and (2).  See sister tests for further coverage.
 
+required=perl-threads
 . ./defs || Exit 1
 
 set -e
index 20225a0..d929740 100755 (executable)
@@ -1,5 +1,5 @@
 #! /bin/sh
-# Copyright (C) 2008  Free Software Foundation, Inc.
+# Copyright (C) 2008, 2009  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
@@ -20,6 +20,7 @@
 # 4) warning and normal error output should be identical, in that duplicate
 #    warnings should be omitted in the same way as without threads,
 
+required=perl-threads
 . ./defs || Exit 1
 
 set -e
index 5db9c67..104376a 100755 (executable)
@@ -1,5 +1,5 @@
 #! /bin/sh
-# Copyright (C) 2008  Free Software Foundation, Inc.
+# Copyright (C) 2008, 2009  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
@@ -21,6 +21,7 @@
 #    with --add-missing, even with concurrent file requirements, and the
 #    installation of aux files should be race-free,
 
+required=perl-threads
 . ./defs || Exit 1
 
 set -e
index 37e690c..3fd9f65 100755 (executable)
@@ -1,5 +1,5 @@
 #!/bin/sh
-# Copyright (C) 2009  Free Software Foundation, Inc.
+# Copyright (C) 2009, 2010  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
@@ -17,7 +17,7 @@
 # Check silent-rules mode, with libtool, non-fastdep case
 # (so that, with GCC, we also cover the other code paths in depend2).
 
-# Please keep this file in sync with silent3.test.
+# Please keep this file in sync with silent3.test and silent9.test.
 
 required="libtoolize gcc"
 . ./defs
index 8d517be..1f06cf0 100755 (executable)
@@ -1,5 +1,5 @@
 #!/bin/sh
-# Copyright (C) 2009  Free Software Foundation, Inc.
+# Copyright (C) 2009, 2010  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
@@ -37,9 +37,13 @@ EOF
 
 cat > Makefile.am <<'EOF'
 # Need generic and non-generic rules.
-bin_PROGRAMS = foo bar
+bin_PROGRAMS = foo bar fo2
 bar_CFLAGS = $(AM_CFLAGS)
 foo_SOURCES = foo1.cpp foo2.f90 foo3.f foo5.l foo6.y
+fo2_SOURCES = $(foo_SOURCES)
+fo2_CPPFLAGS = $(AM_CPPFLAGS)
+fo2_FFLAGS = $(AM_FFLAGS)
+fo2_FCFLAGS = $(AM_FCFLAGS)
 SUBDIRS = sub
 AM_YFLAGS = -d
 LDADD = $(LEXLIB)
@@ -49,9 +53,13 @@ EOF
 cat > sub/Makefile.am <<'EOF'
 AUTOMAKE_OPTIONS = subdir-objects
 # Need generic and non-generic rules.
-bin_PROGRAMS = baz bla
+bin_PROGRAMS = baz bla ba2
 bla_CFLAGS = $(AM_CFLAGS)
 baz_SOURCES = baz1.cpp baz2.f90 baz3.f baz5.l baz6.y
+ba2_SOURCES = $(baz_SOURCES)
+ba2_CPPFLAGS = $(AM_CPPFLAGS)
+ba2_FFLAGS = $(AM_FFLAGS)
+ba2_FCFLAGS = $(AM_FCFLAGS)
 AM_YFLAGS = -d
 LDADD = $(LEXLIB)
 BUILT_SOURCES = baz6.h
@@ -100,8 +108,9 @@ $ACLOCAL
 $AUTOMAKE --add-missing
 $AUTOCONF
 
-# configure once for fastdep, once for non-fastdep
-for config_args in '' am_cv_CC_dependencies_compiler_type=gcc
+# configure once for fastdep, once for non-fastdep, once for nodep
+for config_args in '' am_cv_CC_dependencies_compiler_type=gcc \
+  --disable-dependency-tracking
 do
   ./configure $config_args --enable-silent-rules
   $MAKE >stdout || { cat stdout; Exit 1; }
diff --git a/tests/silent8.test b/tests/silent8.test
new file mode 100755 (executable)
index 0000000..2546775
--- /dev/null
@@ -0,0 +1,66 @@
+#!/bin/sh
+# Copyright (C) 2009  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 texinfo rules in silent-rules mode.
+
+required='makeinfo-html tex texi2dvi-o dvips'
+. ./defs
+
+set -e
+
+cat >>configure.in <<'EOF'
+AM_SILENT_RULES
+AC_OUTPUT
+EOF
+
+cat > Makefile.am <<'EOF'
+info_TEXINFOS = foo.texi
+EOF
+
+cat > foo.texi <<'EOF'
+\input texinfo
+@c %**start of header
+@setfilename foo.info
+@settitle foo manual
+@c %**end of header
+@bye
+EOF
+
+$ACLOCAL
+$AUTOMAKE --add-missing
+$AUTOCONF
+
+./configure --disable-silent-rules
+
+# Make sure that all labels work in silent-mode
+$MAKE V=0 dvi html info ps pdf >stdout || { cat stdout; Exit 1; }
+cat stdout
+grep 'DVIPS    foo.ps' stdout || Exit 1
+grep 'MAKEINFO foo.html' stdout || Exit 1
+grep 'MAKEINFO foo.info' stdout || Exit 1
+grep 'TEXI2DVI foo.dvi' stdout || Exit 1
+grep 'TEXI2PDF foo.pdf' stdout || Exit 1
+
+# Now make sure the labels don't appear in verbose mode.
+$MAKE clean || Exit 1
+$MAKE V=1 dvi html info ps pdf >stdout || { cat stdout; Exit 1; }
+grep 'DVIPS    foo.ps' stdout && Exit 1
+grep 'MAKEINFO foo.html' stdout && Exit 1
+grep 'MAKEINFO foo.info' stdout && Exit 1
+grep 'TEXI2DVI foo.dvi' stdout && Exit 1
+grep 'TEXI2PDF foo.pdf' stdout && Exit 1
+
+:
diff --git a/tests/silent9.test b/tests/silent9.test
new file mode 100755 (executable)
index 0000000..6be0f98
--- /dev/null
@@ -0,0 +1,97 @@
+#!/bin/sh
+# Copyright (C) 2009, 2010  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, with libtool, nodep case.
+
+# Please keep this file in sync with silent3.test and silent4.test.
+
+required="libtoolize"
+. ./defs
+
+set -e
+
+mkdir sub
+
+cat >>configure.in <<'EOF'
+AM_SILENT_RULES
+AC_CONFIG_FILES([sub/Makefile])
+AC_PROG_CC
+AM_PROG_CC_C_O
+AC_PROG_LIBTOOL
+AC_OUTPUT
+EOF
+
+cat > Makefile.am <<'EOF'
+# Need generic and non-generic rules.
+lib_LTLIBRARIES = libfoo.la libbar.la
+libbar_la_CFLAGS = $(AM_CFLAGS)
+SUBDIRS = sub
+EOF
+
+cat > sub/Makefile.am <<'EOF'
+AUTOMAKE_OPTIONS = subdir-objects
+# Need generic and non-generic rules.
+lib_LTLIBRARIES = libbaz.la libbla.la
+libbla_la_CFLAGS = $(AM_CFLAGS)
+EOF
+
+cat > libfoo.c <<'EOF'
+int main ()
+{
+  return 0;
+}
+EOF
+cp libfoo.c libbar.c
+cp libfoo.c sub/libbaz.c
+cp libfoo.c sub/libbla.c
+
+libtoolize
+$ACLOCAL
+$AUTOMAKE --add-missing
+$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
+grep mv stdout && Exit 1
+grep ' CC .*foo\.' stdout
+grep ' CC .*bar\.' stdout
+grep ' CC .*baz\.' stdout
+grep ' CC .*bla\.' stdout
+grep ' CCLD .*foo' stdout
+grep ' CCLD .*bar' stdout
+grep ' CCLD .*baz' stdout
+grep ' CCLD .*bla' stdout
+
+$MAKE clean
+$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
+
+$MAKE distclean
+
+:
diff --git a/tests/subst5.test b/tests/subst5.test
new file mode 100755 (executable)
index 0000000..7ffa1ad
--- /dev/null
@@ -0,0 +1,42 @@
+#! /bin/sh
+# Copyright (C) 2009 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 3 of the License, 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/>.
+
+# Complain about configure substitutions in EXTRA_PRIMARY variables.
+# Rationale: we need to know the literal values of, say, PROGRAMS.
+# Thus, we allow substitutions in bin_PROGRAMS, but then EXTRA_PROGRAMS
+# needs to list possible values of that substitution, literally.
+
+. ./defs || Exit 1
+
+set -e
+
+cat >>configure.in <<'END'
+AC_PROG_CC
+AC_SUBST([substed1])
+AC_SUBST([substed2])
+END
+
+cat > Makefile.am <<'END'
+bin_PROGRAMS = @substed1@
+EXTRA_PROGRAMS = @substed2@
+END
+
+$ACLOCAL
+AUTOMAKE_fails
+grep 'bin_PROGRAMS.*contains configure substitution' stderr && Exit 1
+grep 'EXTRA_PROGRAMS.*contains configure substitution' stderr
+
+Exit 0