[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Automake-commit] [SCM] GNU Automake branch, branch-1.11, updated. v1.11
From: |
Ralf Wildenhues |
Subject: |
[Automake-commit] [SCM] GNU Automake branch, branch-1.11, updated. v1.11.1-455-gd5c4481 |
Date: |
Wed, 20 Jul 2011 21:40:51 +0000 |
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU Automake".
http://git.sv.gnu.org/gitweb/?p=automake.git;a=commitdiff;h=d5c4481349df1228ed0affda63a8939fb41f7487
The branch, branch-1.11 has been updated
via d5c4481349df1228ed0affda63a8939fb41f7487 (commit)
via 158e1d9b450600f15226eefc5b7a026478e1500b (commit)
via edee35da30481a0fa26800bd514bb177416f7e83 (commit)
via 9d1a3a28e52edf568f5edd598446d00c6deebec4 (commit)
via b01fc0873d749b73fcd54378772d36c05ce81bf2 (commit)
via 76cfe59c148e8ba4299fbd2ee9f29ede6198698e (commit)
via 8285d525bfa39018781f5c49b5caa3a44960b8b1 (commit)
via 839b1e34dce6a7038573157a10a4000488926f8d (commit)
via fae45c77d9dfd2b566730bf80fc17d91d61a6931 (commit)
via e58e5f493fa0856d6782549d978c3f1d5f24de8f (commit)
via 8c7c3b592e8fe01e263ade96eddbc85f2619943c (commit)
via 044035ce85d089a9bbdfd6fa99c31dd22b74e7db (commit)
via f8cb365330f9b00aa821b5d64239c94d7b4284c1 (commit)
via a44667dce47afd200d990910f8e8a966276be756 (commit)
via e7a6300b022c251e067dd75229d5c02b658c49d2 (commit)
via c9e39919f0afea01e55795050d4978f530e086e2 (commit)
via 404882ab2ac0a9447f6eccb2fa218df70582f488 (commit)
via 9667c39a2cd9c1af4be172169031975febe78657 (commit)
via 5755b7bcbd3892eb6aa31542fc7e2435a0de11ab (commit)
via c1040a74c10a9a011a04ad0d347b61465c5ee194 (commit)
via 9478566087f83d1fac2c9a7629898a3d39a05fdd (commit)
via 72d36af268fa7bee24466e21d2d543d8d1ce7b1c (commit)
via 1c3614c6d47b4428c39a784dda7f2641cfc8f6d6 (commit)
via 42a9c4db8dc4624dc2b59d1f9a3efb45e359c12e (commit)
via 9b61494445c234e505a2efea8e1c0384591edd2f (commit)
via b8c2b69913b652bcfd4665b041f11d8b5316da2b (commit)
via 60cd9bc070d62bb9046298792bf344d233620a14 (commit)
via 98fab1246b31bc4eb5d83ac7524d1fd126d0e416 (commit)
via f541f9a4c8a5016ed4d77e54f4a3d707a863feaa (commit)
via d30f97d1b62026c962240887d76355f89175b755 (commit)
via 474aad06941498f4c4363b6023eb2f0045b73397 (commit)
via e8bcc4800b17c3fd64b951e0136e7769693edbc8 (commit)
via 5cfe77c655c8c9a82c1cc1686c5da4c9cdd05c45 (commit)
via fefc6a0618c9cdace8b9aa97e1404b0a56abf7dc (commit)
via 5aad6b2552953fbf15f7df672538281b513beff9 (commit)
via 66249f441c572f7f950ae0ab88305fba73eb5a25 (commit)
via 73f8daa0b9d0734153d19f9bb44d9c679df5d9c1 (commit)
via ed078daae2110f79322c79826be567645ef62ea4 (commit)
via 9ca632642b006ac6b0fc4ce0ae5b34023faa8cbf (commit)
via 4e9474e6e9b18723d3fb02858824682dbd0e03f0 (commit)
via f84f54f530c8aa0fd3dcd7a31506eef169958a0a (commit)
via 976003923e43d17985a776f82cf8168e8741f7de (commit)
via f4599943df5b596bad2687cd69d7fe5ce03bcb27 (commit)
via 5b7c6b4ce170477dc3a25a5ca669d117bfb40aa8 (commit)
via e4a70cff310e29066e388aa18aeb07242e003eec (commit)
via 24b9022b753b129d9a2832904fbd9b7a7bbb17d6 (commit)
via 67ca6940688ed14d84642b34df4f28a07b9d9f00 (commit)
via d235db335eaae0934ede72698395f8591d115f9a (commit)
via 8a8890a9152528a4fc348bb15b27ebb2a4c3b7cb (commit)
via bee9871d6a8743b7f01789f196c214354e7f612a (commit)
via aa6883fdcf1e7f21ea81fe4745c0018a9398d43f (commit)
via f31a38aed9c8ffbd33d797aa2df5b5864860bb17 (commit)
via 5c237a6208c74eb445613e5237b4749d62f18b28 (commit)
via 82fc4d353ce941f09f16738a31fb8958d0320be2 (commit)
via 3352b4e8e52d48fd98cda77750d21a819f5cfd47 (commit)
via 0f53bd10322ac70691d8bed06533424eef8db0e6 (commit)
via 2fec9f098ac951e1f7725bce5894c3c7355c59ba (commit)
via daa946a431442335bdf965e27b6f81f6c109fddc (commit)
via a9eef973b5ea47cc3495f1a8307d4f7b85aea46f (commit)
via 42a465249b6d3425efbf23df8f2b62fc0e088cfb (commit)
via a370e2f5cd098af9b95314cdd49b0fbee6588a82 (commit)
via 293b93fcbe264c701ebb88bee5eee0dcf685ac38 (commit)
via 1ada3973ce2ece03695b068477e08253f8d18b5f (commit)
via 78ea595f035fff5e382df79c95bcf639f53fd12b (commit)
via 8b3470c0ed6070f6b8d7ce7878284aa0c08aac13 (commit)
via 305f9120306aab1343da724696aaa88c7f0dd0ab (commit)
via d8f365af42b559f1ae46544c2238febfca664f3a (commit)
via e9bb4e913957b0388182de7350e198d6fe74bf02 (commit)
via 214bafdb4f7b97e8897cf8668867a2bbcfc804b2 (commit)
via d53f5cd99c0946f77ff473e44db13514cc062837 (commit)
via 5d1f3f0c14af19df45406386b514008916f7d80b (commit)
via 9b5a8552fec112499a527a8af8577a9b76144435 (commit)
via 3b64c7d208952e94c4b6a317cf34e5e650e77fe6 (commit)
via 9e7c4339cefd512255d30446053a9d84bdb619b1 (commit)
via 5e5919991ae3992dccc7851cb4af504bba0cc26d (commit)
from 5608a8a3124f7742f8d85310c63304c7efbefacd (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit d5c4481349df1228ed0affda63a8939fb41f7487
Merge: 5608a8a 158e1d9
Author: Ralf Wildenhues <address@hidden>
Date: Wed Jul 20 23:38:43 2011 +0200
Merge branch 'maint' into branch-1.11
-----------------------------------------------------------------------
Summary of changes:
ChangeLog | 617 +++++++++++++++++++-
HACKING | 7 +-
Makefile.am | 75 ++-
Makefile.in | 60 ++-
NEWS | 26 +
THANKS | 2 +
aclocal.in | 2 +-
automake.in | 113 ++--
configure | 12 +-
configure.ac | 6 +-
doc/Makefile.am | 10 +-
doc/Makefile.in | 13 +-
doc/automake.texi | 577 ++++++++++++++-----
lib/Automake/Makefile.in | 3 +
lib/Automake/Options.pm | 4 +
lib/Automake/tests/Makefile.in | 34 +-
lib/INSTALL | 9 +-
lib/Makefile.in | 3 +
lib/am/Makefile.in | 3 +
lib/am/check.am | 46 +-
lib/am/configure.am | 9 +-
lib/am/distdir.am | 4 +-
lib/config-ml.in | 15 +-
lib/config.guess | 217 ++++----
lib/config.sub | 111 ++--
lib/texinfo.tex | 536 ++++++++++++-----
m4/Makefile.in | 3 +
m4/protos.m4 | 2 +
tests/Makefile.am | 37 ++-
tests/Makefile.in | 77 ++-
tests/README | 33 +-
...{autodist-acconfig.test => amhello-binpkg.test} | 37 +-
tests/amhello-cflags.test | 51 ++
tests/amhello-cross-compile.test | 54 ++
tests/ansi.test | 4 +-
tests/ansi10.test | 4 +-
tests/ansi2.test | 2 +-
tests/ansi2knr-deprecation.test | 69 +++
tests/ansi3.test | 4 +-
tests/ansi3b.test | 4 +-
tests/ansi4.test | 2 +-
tests/ansi5.test | 4 +-
tests/ansi6.test | 4 +-
tests/ansi7.test | 4 +-
tests/ansi8.test | 2 +-
tests/ansi9.test | 4 +-
tests/autodist-no-duplicate.test | 52 ++
tests/autodist-subdir.test | 27 +-
tests/autodist.test | 31 +-
tests/check-tests-in-builddir.test | 19 +-
tests/cxxansi.test | 2 +-
tests/defs.in | 138 ++++-
tests/depcomp8a.test | 14 +-
tests/depcomp8b.test | 12 +-
tests/distcheck-configure-flags-am.test | 68 +++
tests/distcheck-configure-flags-subpkg.test | 83 +++
tests/distcheck-configure-flags.test | 56 ++
...{autodist-acconfig.test => distcheck-hook.test} | 31 +-
tests/{subpkg3.test => distcheck-hook2.test} | 52 ++-
tests/gen-parallel-tests | 11 +-
tests/interp.test | 18 +-
tests/java3.test | 26 +-
tests/libobj8.test | 2 +-
tests/maintclean-vpath.test | 2 +-
tests/mclean.test | 31 -
tests/parallel-tests-harderror.test | 98 +++
tests/parallel-tests-log-compiler-example.test | 71 +++
tests/parallel-tests-log-override-1.test | 112 ++++
tests/parallel-tests-log-override-2.test | 88 +++
tests/parallel-tests-log-override-recheck.test | 92 +++
tests/parallel-tests.test | 18 +-
tests/pr401.test | 1 +
tests/pr401b.test | 1 +
tests/pr401c.test | 1 +
tests/primary-prefix-couples-documented-valid.test | 88 +++
tests/primary-prefix-couples-force-valid.test | 88 +++
tests/primary-prefix-invalid-couples.test | 187 ++++++
tests/primary-prefix-valid-couples.test | 90 +++
.../{gcj6.test => remake-subdir-from-subdir.test} | 43 +-
tests/remake-subdir-gnu.test | 80 +++
tests/remake-subdir-long-time.test | 116 ++++
...-acconfig-no-subdir.test => remake-subdir.test} | 65 ++-
tests/remake-subdir2.test | 82 +++
...dirforbid.test => self-check-env-sanitize.test} | 30 +-
tests/self-check-report.test | 47 ++
tests/silent-configsite.test | 86 +++
tests/specflg8.test | 35 +-
...ment.test => tests-environment-backcompat.test} | 32 +-
tests/txinfo21.test | 8 +-
89 files changed, 4197 insertions(+), 952 deletions(-)
copy tests/{autodist-acconfig.test => amhello-binpkg.test} (57%)
create mode 100755 tests/amhello-cflags.test
create mode 100755 tests/amhello-cross-compile.test
create mode 100755 tests/ansi2knr-deprecation.test
create mode 100755 tests/autodist-no-duplicate.test
create mode 100755 tests/distcheck-configure-flags-am.test
create mode 100755 tests/distcheck-configure-flags-subpkg.test
create mode 100755 tests/distcheck-configure-flags.test
copy tests/{autodist-acconfig.test => distcheck-hook.test} (64%)
copy tests/{subpkg3.test => distcheck-hook2.test} (51%)
delete mode 100755 tests/mclean.test
create mode 100755 tests/parallel-tests-harderror.test
create mode 100755 tests/parallel-tests-log-compiler-example.test
create mode 100755 tests/parallel-tests-log-override-1.test
create mode 100755 tests/parallel-tests-log-override-2.test
create mode 100755 tests/parallel-tests-log-override-recheck.test
create mode 100755 tests/primary-prefix-couples-documented-valid.test
create mode 100755 tests/primary-prefix-couples-force-valid.test
create mode 100755 tests/primary-prefix-invalid-couples.test
create mode 100755 tests/primary-prefix-valid-couples.test
copy tests/{gcj6.test => remake-subdir-from-subdir.test} (58%)
create mode 100755 tests/remake-subdir-gnu.test
create mode 100755 tests/remake-subdir-long-time.test
copy tests/{autodist-acconfig-no-subdir.test => remake-subdir.test} (51%)
create mode 100755 tests/remake-subdir2.test
rename tests/{dirforbid.test => self-check-env-sanitize.test} (57%)
create mode 100755 tests/self-check-report.test
create mode 100755 tests/silent-configsite.test
copy tests/{check-tests_environment.test => tests-environment-backcompat.test}
(53%)
diff --git a/ChangeLog b/ChangeLog
index 66326f5..4ab2a75 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,574 @@
+2011-07-20 Ralf Wildenhues <address@hidden>
+
+ Sync auxiliary files from upstream.
+ * INSTALL, lib/INSTALL, lib/config.guess, lib/config.sub,
+ lib/texinfo.tex: Sync from upstream.
+
+2011-07-08 Stefano Lattarini <address@hidden>
+
+ tests: fix weakness in 'tests-environment-backcompat.test'
+ * tests/tests-environment-backcompat.test: Do not override the
+ content of xfailing test `baz.test' with a "weaker" version that
+ fails unconditionally: the test must fail only when the 'strict'
+ pragma is in use, in order not to reduce coverage.
+
+2011-07-08 Stefano Lattarini <address@hidden>
+
+ docs, tests: synchronize examples on silent-rules from config.site
+ * doc/automake.texi (Automake silent-rules Option): Reference test
+ 'silent-configsite.test' in comments.
+
+2011-07-08 Stefano Lattarini <address@hidden>
+
+ tests: portability fixes in tests on amhello examples
+ * tests/amhello-binpkg.test: Don't use "tar xzf too.tag.gz" to
+ extract a gzip-compressed tarball, that's unportable to some
+ tar implementations; use the "gzip -dc fo.tar.gz | tar xf -"
+ idiom instead.
+ * tests/amhello-cflags.test: Likewise.
+ * tests/amhello-cross-compile.test: Likewise.
+ Suggestion from Ralf Wildenhues.
+
+2011-07-04 Stefano Lattarini <address@hidden>
+
+ remake: add test ensuring that slower remakes don't hang
+ * tests/remake-subdir-long-time.test: New test.
+ * tests/Makefile.am (TESTS): Update.
+ Suggestion by Ralf Wildenhues.
+
+2011-07-04 Stefano Lattarini <address@hidden>
+
+ remake: fix outdated comment in configure.am
+ * lib/am/configure.am: Fix comment falsified by changes in
+ commit `v1.11-366-gbee9871'.
+ Suggestion by Ralf Wildenhues.
+
+2011-07-01 Stefano Lattarini <address@hidden>
+
+ docs, tests: synchronize examples from docs to tests
+ * tests/README (Writing test cases): Give suggestions on how to
+ keep test cases and examples in the documentation synchronized.
+ * doc/automake.texi: Improve or fix existing testcase-referencing
+ comments, and add many new ones.
+ * HACKING (Administrivia): Suggest to test complex examples and
+ idioms from the manual.
+ * tests/specflg8.test: Improve synchronization with the example
+ in the manual.
+ * tests/output11.test:Likewise.
+ * tests/txinfo21.test:Likewise.
+ * tests/interp.test: Likewise. Since we are at it, and enable
+ the `errexit' shell flag, do related changes, and add trailing
+ `:'command.
+ * tests/amhello-cflags.test: New test.
+ * tests/amhello-cross-compile.test: Likewise.
+ * tests/amhello-binpkg.test: Likewise.
+ * tests/tests-environment-backcompat.test: Likewise.
+ * tests/parallel-tests-log-compiler-example.test: Likewise.
+ * tests/Makefile.am (TESTS): Update.
+
+2011-06-23 Stefano Lattarini <address@hidden>
+
+ docs: avoid a footnote, some related rewordings and improvements
+ * doc/automake.texi (Dist): Reword the part about automatically
+ distributed files to avoid a footnote. Since we are at it, extend
+ a bit, and add an example and a reference to a relevant test case.
+
+2011-06-23 Stefano Lattarini <address@hidden>
+
+ docs: minor cosmetic fixes
+ * doc/automake.texi: Break few overly long lines, throughout the
+ file.
+ ("Simple Tests"): Move @vindex for XFAIL_TESTS to the correct
+ position, i.e., before and not after the paragraph where it is
+ introduced.
+ ("Options" @item ansi2knr): Use @pxref instead of @xref. This
+ fixes a texinfo warning.
+ ("Other things Automake recognizes" @item AM_C_PROTOTYPES): Use
+ @pxref instead of @ref.
+
+2011-06-23 Stefano Lattarini <address@hidden>
+
+ help: improve text about automatically-distributed files
+ This change fixes automake bug#7819.
+ * automake.in (usage): Distinguish between files that are always
+ automatically distributed when found, and those which are only
+ "under certain conditions".
+ * doc/automake.texi (Basics of Distribution): Update accordingly.
+ * tests/autodist-subdir.test: Update.
+ * tests/autodist-no-duplicate.test: Likewise.
+ * tests/autodist.test: Likewise.
+ (configure.in): Remove useless call to AM_MAINTAINER_MODE.
+
+2011-06-23 Stefano Lattarini <address@hidden>
+
+ refactor: split 'usage' subroutine in automake
+ This change is related to automake bug#7819.
+ * automake.in (print_autodist_files): New subroutine,
+ extracted from ...
+ (usage): ... this, which now uses it.
+ * tests/autodist-no-duplicate.test: New test.
+ * tests/Makefile.am (TESTS): Update.
+
+2011-06-23 Stefano Lattarini <address@hidden>
+
+ tests: fix bug in 'autodist.test'
+ * tests/autodist.test: Avoid spurious failure due to no
+ `defs-static' file being found in the parent directory.
+
+2011-06-21 Stefano Lattarini <address@hidden>
+
+ maintcheck: extend 'sc_tests_plain_*' checks
+ * Makefile.am (sc_tests_plain_autom4te): New check.
+ (sc_tests_plain_autoreconf): Likewise.
+ (sc_tests_plain_autoheader): Likewise.
+ (syntax_check_rules): Update.
+
+2011-06-20 Stefano Lattarini <address@hidden>
+
+ maintcheck: avoid few spurious failures
+ * Makefile.am (sc_tests_plain_aclocal, sc_tests_plain_perl,
+ sc_tests_plain_autoconf, sc_tests_plain_automake,
+ sc_tests_plain_autoupate): Be stricter in matching an erroneous
+ literal command, i.e., `aclocal', `automake', `perl', etc.
+
+2011-06-20 Bert Wesarg <address@hidden> (tiny change)
+
+ check: don't use multi-line coloring for the report
+ "less -R" can't handle multi-line coloring as it is done for the
+ check reports of the serial and parallel testsuite, because of
+ performance reasons. Thus, color each line of the check report
+ by its own.
+ * lib/am/check.am (am__text_box): Accept colors for lines, and
+ color each line by its own.
+ [%?PARALLEL_TESTS%] $(TEST_SUITE_LOG): Let am__text_box handle
+ the line coloring.
+ [!%?PARALLEL_TESTS%] $(check-TESTS): Color each report line by
+ its own.
+ * THANKS: Update.
+
+2011-06-18 Stefano Lattarini <address@hidden>
+
+ docs: AM_DISTCHECK_CONFIGURE_FLAGS is for corner cases
+ * doc/automake.texi (Checking the Distribution): Explain that the
+ developers should take care of making their code buildable without
+ requiring any special configure options, so that in general
+ AM_DISTCHECK_CONFIGURE_FLAGS shouldn't be used. Give an example
+ of where its use is legitimate.
+ Suggestions from Ralf Wildenhues and Eric Blake.
+
+2011-06-14 Stefano Lattarini <address@hidden>
+
+ ansi2knr: deprecate, it will go away in the next major release
+ * doc/automake.texi: Loudly and repeatedly state that the old
+ de-ANSI-fication features are now deprecated and will be removed
+ in the next major Automake release. Other related adjustments.
+ * lib/Automake/Options.pm (_process_option_list ): Give a warning
+ in the `obsolete' category when the `ansi2knr' option is used.
+ * m4/protos.m4 (AM_C_PROTOTYPES): Deprecate this macro: a warning
+ in the `obsolete' category will be emitted it if is used.
+ * tests/ansi2knr-deprecation.test: New test.
+ * tests/Makefile.am (TESTS): Update.
+ * tests/ansi.test: Adjust, by calling autoconf and/or automake
+ with the `-Wno-obsolete' flag.
+ * tests/ansi10.test: Likewise.
+ * tests/ansi2.test: Likewise.
+ * tests/ansi3.test: Likewise.
+ * tests/ansi3b.test: Likewise.
+ * tests/ansi4.test: Likewise.
+ * tests/ansi5.test: Likewise.
+ * tests/ansi6.test: Likewise.
+ * tests/ansi7.test: Likewise.
+ * tests/ansi8.test: Likewise.
+ * tests/ansi9.test: Likewise.
+ * tests/cxxansi.test: Likewise.
+ * tests/libobj8.test: Likewise.
+ * NEWS: Update about the future planned backward-incompatibility
+ due to the removal of de-ANSI-fication feature.
+
+2011-06-19 Stefano Lattarini <address@hidden>
+
+ docs: primary/prefix combination "pkglib_PROGRAMS" is now invalid
+ * doc/automake.texi (Program Sources): pkglib_PROGRAMS is not a
+ valid combination anymore, so don't document it. Inconsistency
+ introduced in commit `v1.11-373-g9ca6326'.
+
+2011-06-19 Jim Meyering <address@hidden>
+
+ docs: replace obsolete @vindex entry with a useful one
+ * doc/automake.texi (Program Sources): Do not index obsolete
+ pkglib_PROGRAMS here. Do index pkglibexec_PROGRAMS.
+
+2011-06-13 Stefano Lattarini <address@hidden>
+
+ tests: optimize tests on primary/prefix mismatch for speed
+ * tests/primary-prefix-invalid-couples.test: Partial rewrite, in
+ order to use just a single automake invocation rather than one
+ invocation for each invalid primary/prefix couple. This improves
+ the test script execution time by an order of magnitude.
+ Since we are at it, throw in some other improvements to avoid
+ unrelated automake warnings and failures that could potentially
+ cause false positives w.r.t. the automake exit status.
+
+2011-06-13 Stefano Lattarini <address@hidden>
+
+ news: update w.r.t. introduction of AM_DISTCHECK_CONFIGURE_FLAGS
+ * NEWS (Miscellaneous changes): Update.
+
+2011-06-10 Stefano Lattarini <address@hidden>
+
+ maintcheck: DISTCHECK_CONFIGURE_FLAGS can be defined on make cmdline
+ * Makefile.am (sc_tests_overriding_macros_on_cmdline): It's now
+ acceptable that the test scripts override DISTCHECK_CONFIGURE_FLAGS
+ on the make command line. Update comments accordingly. Since we
+ are at it, make the relevant grepping rules slightly tighter.
+
+2011-06-10 Stefano Lattarini <address@hidden>
+
+ distcheck: add support for AM_DISTCHECK_CONFIGURE_FLAGS
+ * doc/automake.texi (Checking the Distribution): Suggest to use
+ AM_DISTCHECK_CONFIGURE_FLAGS, not DISTCHECK_CONFIGURE_FLAGS, to
+ define (in the top-level Makefile.am) extra flags to be passed
+ to configure at "make distcheck" time; DISTCHECK_CONFIGURE_FLAGS
+ should be reserved for the user. Add proper address@hidden' directive.
+ Document that AM_DISTCHECK_CONFIGURE_FLAGS is not honoured in a
+ subpackage Makefile.am, but the flags in it are passed down to
+ the configure script of the subpackage.
+ * lib/am/distdir.am (distcheck): Also pass the flags in
+ $(AM_DISTCHECK_CONFIGURE_FLAGS) to the configure invocation.
+ Update comments.
+ * tests/defs.in.test (AM_DISTCHECK_CONFIGURE_FLAGS,
+ DISTCHECK_CONFIGURE_FLAGS): Unset in case they are exported in
+ the environment, they might improperly influence our testsuite.
+ * tests/distcheck-configure-flags.test: New test.
+ * tests/distcheck-configure-flags-am.test: Likewise.
+ * tests/distcheck-configure-flags-subpkg.test: Likewise.
+ * distcheck-hook.test: Likewise.
+ * distcheck-hook2.test: Likewise.
+ * tests/Makefile.am (TESTS): Update.
+ Closes automake bug#8784.
+
+2010-06-09 Stefano Lattarini <address@hidden>
+
+ docs: better documentation for silent make rules
+ * doc/automake.texi (Options): Detailed description of the
+ automake option `silent-rules' moved from here ...
+ (Silent Make): ... into this new chapter, expanded, improved,
+ and subdivided into ...
+ (Make verbosity, Tricks For Silencing Make,
+ Automake silent-rules Option): ... these new sections.
+ (@menu, @detailmenu): Update.
+ * tests/silent-configsite.test: New test, checking that the
+ user can control default mode of silent-rules from config.site,
+ as is documented in the manual.
+ * tests/Makefile.am (TESTS): Updated.
+
+2011-06-11 Stefano Lattarini <address@hidden>
+
+ Warnings about primary/prefix mismatch fixed and extended.
+ * automake.in (%standard_prefix): Add `doc' and `locale'.
+ Rename `pkgdatadir' to `pkgdata'. Similarly for`pkglibdir',
+ `pkgincludedir' and `pkglibexecdir'.
+ (handle_programs): List `pkglibexec', not `pkglib', among the
+ prefixes valid for the `PROGRAMS' primary.
+ (handle_data): List also `doc' among the prefixes valid for
+ the `DATA' primary. This is required by automake's own build
+ system.
+ * tests/dirforbid.test: Test removed, superseded by ...
+ * tests/primary-prefix-invalid-couples.test: ... this new test.
+ * tests/primary-prefix-valid-couples.test: New test.
+ * tests/primary-prefix-couples-documented-valid.test: Likewise.
+ * tests/primary-prefix-couples-force-valid.test: Likewise.
+ * tests/java3.test: Adjusted, and extended a bit.
+ * tests/Makefile.am (TESTS): Updated.
+ * NEWS: Updated.
+ From a report by Eric Blake.
+
+2011-06-08 Stefano Lattarini <address@hidden>
+
+ test defs: new function 'fatal_', for hard errors
+ Before this patch, the only way offered by tests/defs to
+ properly signal a hard error was the `framework_failure_'
+ function. But the error message issued by that function,
+ as its name would suggest, refers to a set-up failure in the
+ testsuite, while hard errors can obviously also be due to
+ other reasons. The best way to fix this inconsistency is to
+ introduce a new function with a more general error message.
+ Inspired by a recent similar change to Gnulib's tests/init.sh.
+ * tests/defs.in (fatal_): New function.
+ * tests/README (Section "Writing test cases" subsection "Do"):
+ Suggest the use of `fatal_', not of `framework_failure_', for
+ generic hard errors. The latter should be reserved for "real"
+ set-up failures.
+
+2011-06-02 Stefano Lattarini <address@hidden>
+
+ maintcheck: fix some failures, extend some checks
+ * Makefile.am (sc_diff_automake_in_automake): Update, as we
+ now expect 9 lines, not 8, to be changed from `automake.in'
+ to `automake'.
+ (sc_diff_aclocal_in_aclocal): New maintainer check, similar to
+ the above, and checking that only 10 lines are changed from
+ `aclocal.in' to `aclocal'.
+ (syntax_check_rules): Update.
+ (sc_tests_Exit_not_exit): Exempt self tests `self-check-*.test'
+ from this check, as they can legitimately use the bare `exit'
+ builtin in various places.
+ * doc/automake.texi (Python): Remove stray `@' from the end of
+ a line. Typo introduced in commit `v1.11-312-g5bf7af6'.
+ * tests/depcomp8a.test: Pass DISTCHECK_CONFIGURE_FLAGS to make
+ from the environment rather than from the command line, to
+ pacify the `sc_tests_overriding_macros_on_cmdline' maintainer
+ check.
+ * tests/depcomp8b.test: Likewise.
+
+2011-05-29 Stefano Lattarini <address@hidden>
+
+ remake: behave better with non-GNU make in subdirectories
+ Currently, with every decent make program, it is possible to
+ rebuild out-of-date autotools-generated files with a simple
+ "make Makefile" -- but for this to work reliably with non-GNU
+ make implementations, the command must be issued from the
+ top-level directory. This patch removes such limitation.
+ * lib/am/configure.am (am--refresh): Depend on `%MAKEFILE%'.
+ * tests/defs.in (using_gmake): New function, backported from the
+ `master' branch (and simplified).
+ * tests/remake-subdir.test: New test.
+ * tests/remake-subdir2.test: Likewise.
+ * tests/remake-subdir-gnu.test: Likewise.
+ * tests/remake-subdir-from-subdir.test: Likewise.
+ * tests/Makefile.am (TESTS): Update.
+
+2011-05-29 Stefano Lattarini <address@hidden>
+
+ automake, aclocal: honour configure-time AUTOCONF and AUTOM4TE
+ Currently, the Automake's own configure script allow definition
+ of AUTOCONF and AUTOM4TE, expected to point respectively to an
+ autoconf and autom4te programs. But while these definitions are
+ honoured in the Automake's build systems and test suite, they
+ were *not* honoured in the generated `automake' and `aclocal'
+ scripts. This behaviour, apart from being wrong in that it does
+ not allow the user enough freedom in choosing his tools, also
+ caused inconsistencies in the test suite, brining to spurious
+ failures.
+ Problem reported by Graham Reitz on the automake list; see thread:
+ <http://lists.gnu.org/archive/html/automake/2011-05/msg00022.html>
+ * automake.in ($traces): Use address@hidden', not simply `autoconf'.
+ * aclocal.in ($traces): Use address@hidden', not simply `autom4te'.
+ * Makefile.am (do_subst): Substitute also address@hidden' and
+ address@hidden'.
+ * NEWS: Update.
+ * THANKS: Update.
+
+2011-05-29 Stefano Lattarini <address@hidden>
+
+ build: the user can override AUTOM4TE, AUTORECONF and AUTOUPDATE too
+ Our build system allows the user to override AUTOCONF and AUTOHEADER
+ at configure time, and honours these overrides in our testsuite.
+ But it didn't do the same with AUTOM4TE, AUTORECONF and AUTOUPDATE.
+ This change fixes that inconsistency.
+ * configure.ac (am_AUTOM4TE, am_AUTOUPDATE, am_AUTORECONF): New
+ AC_SUBSTitutions. Update comments.
+ * tests/defs.in ($AUTOUPDATE): Default to address@hidden@' now.
+ ($AUTOM4TE): New variable, defaulting to address@hidden@'.
+ ($AUTORECONF): New variable, defaulting to address@hidden@'.
+ * doc/Makefile.am ($(srcdir)/amhello-1.0.tar.gz): Update.
+
+2011-05-22 Ralf Wildenhues <address@hidden>
+ Stefano Lattarini <address@hidden>
+
+ tests/README: fix example about `make -e' usage
+ * tests/README (Section "Writing test cases" subsection "Do"): When
+ some variable is never initialized in the Makefile, `-e' is not
+ necessary in order to override it. DESTDIR is such a variable: we
+ ensure that we do not ever initialize it. And as such, it is quite
+ portable to use:
+ $ make DESTDIR=/foo/bar install
+ and in fact, quite widely used.
+ So our example about when `make -e' is required, which references
+ the `DESTDIR' variable, is poorly chosen, if not downright wrong.
+ Rewrite it to use `prefix' as the overridden variable instead.
+
+2011-05-22 Stefano Lattarini <address@hidden>
+
+ parallel-tests: stricter checks on DISABLE_HARD_ERRORS support
+ * tests/parallel-tests-harderror.test: New test, doing more
+ in-depth checks on DISABLE_HARD_ERRORS.
+ * tests/parallel-tests.test: Remove tests on DISABLE_HARD_ERRORS,
+ now redundant.
+ * tests/Makefile.am (TESTS): Update.
+
+2011-05-20 Stefano Lattarini <address@hidden>
+
+ testsuite: avoid re-running few tests with 'parallel-tests' option
+ Some tests in our testsuite use the 'simple-tests' driver only
+ marginally, or simply as a mean to conveniently check unrelated
+ invariants. It makes little sense to force these tests to also
+ run with the 'parallel-tests' Automake option active, as doing so
+ offers no real gain in coverage, while often causing a measurable
+ overhead in execution time (for an already too-slow testsuite).
+ * tests/pr401.test (parallel_tests): Define to "no", to prevent
+ the generation of a sibling test script using the 'parallel-tests'
+ driver.
+ * tests/pr401b.test: Likewise.
+ * tests/pr401c.test: Likewise.
+
+2011-05-20 Stefano Lattarini <address@hidden>
+
+ testsuite: allow tests to avoid the use of 'parallel-tests' option
+ * tests/gen-parallel-tests: Do not generate "siblings" for tests
+ that explicitly define the `parallel_tests', whether to "yes" or
+ to any other value. Extend heading comments to give a rationale
+ for this behaviour.
+ * tests/README: Update.
+
+2011-05-20 Stefano Lattarini <address@hidden>
+
+ tests/README: update obsoleted advice
+ * tests/README (Section "Writing test cases" subsection "Do"):
+ Do not suggest to use the `*-p.test' pattern for the names of
+ hand-written tests which use the `parallel-tests' Automake option.
+ Not only is this not respected by the existing tests, but it is
+ more likely to cause conflicts with auto-generated tests.
+ So, suggest to *avoid* using the `*-p.test' pattern in names
+ of hand-written tests instead.
+ (Section "Writing test cases" subsection "Do not"): When
+ suggesting not to override Makefile variables using command
+ line arguments, do not use the badly outdated variables `U'
+ and 'ANSI2KNR' in the example; instead, use the more common
+ and typical `DESTDIR'.
+
+2011-05-19 Stefano Lattarini <address@hidden>
+
+ test defs: rename requirement 'non-cross' -> 'native'
+ * tests/defs.in (non-cross): Rename requirement ...
+ (native): ... to this, which is clearer and fits the
+ existing lingo better.
+ Suggestion by Ralf Wildenhues.
+
+2011-05-15 Stefano Lattarini <address@hidden>
+
+ testsuite: be more cross-compile friendly
+ * tests/defs.in (cross_compiling): New subroutine.
+ (am__tool_prefix): New internal variable.
+ (gcc, g++, gcj): Force the use of the correct "tool prefix"
+ when cross compiling.
+ (gfortran, g77, non-cross): New requirements.
+
+2011-05-11 Stefano Lattarini <address@hidden>
+
+ check: document and test $(TEST_SUITE_LOG) overriding
+ * doc/automake.texi (Simple Tests using parallel-tests): Explain
+ how and why TEST_SUITE_LOG can be overridden at runtime.
+ * tests/parallel-tests-log-override-1.test: New test, check that
+ the newly documented idiom and similar usages are truly supported.
+ * tests/parallel-tests-log-override-2.test: Likewise.
+ * tests/parallel-tests-log-override-recheck.test: Likewise.
+ * tests/Makefile.am (TESTS): Update.
+
+2011-05-07 Stefano Lattarini <address@hidden>
+
+ tests: fix spurious failure of txinfo21.test on FreeBSD
+ * tests/txinfo21.test: Use the `is_newest' subroutine instead of
+ the `ls -t' hack to to determine whether a file has been updated.
+ This is required because at least FreeBSD `ls' do not sort files
+ with the same timestamp in alphabetical order when using the `-t'
+ option.
+
+2011-05-04 Stefano Lattarini <address@hidden>
+
+ tests defs: allow requirements for compilers (mostly dummy)
+ Most of the new requirements that are now accepted in `$required'
+ as consequence of this patch are still dummy. They are planned
+ to be implemented only in master (or in some derived branch), but
+ having them here (even just as no-op) will allow for an easier
+ integration/backporting of potential new testcases.
+ * tests/defs.in (cc, c++, fortran, fortran77): New requirements,
+ still dummy.
+ (flex): New requirement, picking LEX for configure.
+ (lex): New requirement, alias for `flex'. A more appropriate
+ implementation, looking for a generic `lex' program, will follow
+ in the future.
+ (yacc): New requirement, alias for `bison'. A more appropriate
+ implementation, looking for a generic `yacc' program, will follow
+ in the future.
+
+2011-04-24 Stefano Lattarini <address@hidden>
+
+ tests: fix spurious failure in a test on TESTS (VPATH-related)
+ * tests/check-tests-in-builddir.test: When not using the
+ parallel-tests option, do not check that VPATH components are
+ not present in the displayed test name, since the simple-tests
+ driver do not try to strip them.
+
+2011-04-23 Stefano Lattarini <address@hidden>
+
+ test: self check subroutines for skipping/failing of tests
+ * tests/self-check-report.test: New test.
+ * tests/Makefile.am (TESTS): Update.
+
+2011-04-23 Jim Meyering <address@hidden>
+ Stefano Lattarini <address@hidden>
+
+ test defs: new subroutines for test skipping/failing
+ * tests/defs.in (Exit): Move definition of this function earlier.
+ (warn_, skip_, fail_, framework_failure_): New functions, inspired
+ to the homonyms in gnulib's tests/init.sh.
+ ($stderr_fileno_): New global variable, used by the new functions
+ above.
+ * tests/README: Updated.
+ From a suggestion by Ralf Wildenhues.
+
+2011-04-23 Stefano Lattarini <address@hidden>
+
+ tests: fix typo (copy & paste blunder) in heading comment
+ * tests/maintclean-vpath.test: Correctly refer to the sister test
+ as `maintclean.test', not as `maintclean-vpath.test'.
+
+2011-04-23 Stefano Lattarini <address@hidden>
+
+ tests: remove redundant test `mclean.test'
+ * tests/mclean.test: Remove, it's a weak grepping test completely
+ superseded by the much more complete `maintclean.test'.
+ * tests/Makefile.am (TESTS): Update.
+
+2011-04-22 Stefano Lattarini <address@hidden>
+
+ testsuite: more environment sanitization
+ * tests/defs.in: Sanity check: abort if any of `parallel_tests'
+ or `required' is in the environment.
+ ($sed_unindent_prog): Initialize to empty, to avoid interferences
+ from the environment.
+ * tests/self-check-me-in-env.test: Renamed to ...
+ * tests/self-check-env-sanitize.test: ... this, and extended.
+ * tests/Makefile.am (TESTS): Update.
+ (TESTS_ENVIRONMENT): Unset variables `parallel_tests' and
+ `required'. Adjust comments.
+
+2011-04-18 Stefano Lattarini <address@hidden>
+
+ tests: don't allow `$me' to be overridden from the environment
+ * tests/defs.in: Sanity check: abort if $me is in the environment.
+ * tests/self-check-me-in-env.test: New test.
+ * tests/Makefile.am (TESTS_ENVIRONMENT): Unset variable `me'.
+ (TESTS): Update.
+ Suggestion by Ralf Wildenhues.
+
+2011-04-17 Stefano Lattarini <address@hidden>
+
+ test defs: allow overriding of `$me'
+ * tests/defs.in ($me): Allow overriding by the including test
+ script. Add some explicative comments.
+
+2011-04-17 Stefano Lattarini <address@hidden>
+
+ depcomp tests: don't reject slower dependency extractors
+ * tests/depcomp8b.test: Add the `--enable-dependency-tracking'
+ option to `configure' invocations, so that slower dependency
+ extractors are not rejected.
+ * tests/depcomp8a.test: Likewise. Also ...
+ (foo.c): ... since we are at it, fix spacing to be consistent
+ with GNU coding standards.
+
2011-04-17 Stefano Lattarini <address@hidden>
m4: add missing serial numbers to a few files
@@ -253,11 +824,11 @@
suggest the use of this latter macro instead.
* lib/Automake/Variable.pm (%_am_macro_for_var): Pair 'LIBTOOL'
with 'LT_INIT', not with 'AC_PROG_LIBTOOL'.
- * libtool4.test: Adjust and extend. Also, add a call to macro
- AC_PROG_CC in configure.in, to help ensuring that automake does
- not fail for the wrong reasons.
- * ltinit.test: New test, ensure that automake's libtool support
- works with LT_INIT-based interface.
+ * tests/libtool4.test: Adjust and extend. Also, add a call to
+ macro AC_PROG_CC in configure.in, to help ensuring that automake
+ does not fail for the wrong reasons.
+ * tests/ltinit.test: New test, ensure that automake's libtool
+ support works with LT_INIT-based interface.
Thanks to Jack Kelly for the suggestion.
2011-02-20 Stefano Lattarini <address@hidden>
@@ -483,7 +1054,7 @@
* tests/flibs.test: Likewise.
* tests/fort4.test: Use $AUTOMAKE -a for installing files.
-2011-01-12 Stefano Lattarini <address@hidden>
+2011-01-12 Stefano Lattarini <address@hidden>
docs: clustered '-d' not recognized in YFLAGS
This change fixes automake bug#7828.
@@ -492,7 +1063,7 @@
other options.
From a report by ЮÑий ÐÑÑ
алÑÑкий.
-2011-01-10 Stefano Lattarini <address@hidden>
+2011-01-10 Stefano Lattarini <address@hidden>
tests: add checks on automatically-distributed files
Related to automake bug#7819.
@@ -580,7 +1151,7 @@
Fix another typo in Rule.pm comment.
* lib/Automake/Rule.pm: Fix typo.
-2011-01-09 Stefano Lattarini <address@hidden>
+2011-01-09 Stefano Lattarini <address@hidden>
cosmetics: remove trailing whitespaces
* doc/automake.texi: Remove trailing whitespaces.
@@ -620,12 +1191,12 @@
manual for how to convert directory values into macros.
(Optional): Fix grammar nit.
-2011-01-02 Stefano Lattarini <address@hidden>
+2011-01-02 Stefano Lattarini <address@hidden>
* NEWS: Fix typo (forgotten word).
-2011-01-02 Stefano Lattarini <address@hidden>
- Ralf Wildenhues <address@hidden>
+2011-01-02 Stefano Lattarini <address@hidden>
+ Ralf Wildenhues <address@hidden>
docs: how to work around checks on invalid primary/directory couples
* doc/automake.texi (Uniform): Document the blessed idiom which can
@@ -748,18 +1319,18 @@
compilers were used. So we are now careful to require GCC in
tests that force gcc depmode.
From reports by Ralf Wildenhues.
- * silent5.test: Test removed, its content split into ...
- * silent-many-generic.test, silent-many-gcc.test: ... these new
- sister tests, the latter of which forces gcc depmode and lists
- "gcc" in $required.
- * silentlex.test: Test removed, its content split into ...
- * silent-lex-generic.test, silent-lex-gcc.test: ... these new
- sister tests, the latter of which forces gcc depmode and lists
- "gcc" in $required.
- * silentyacc.test: Test removed, its content split into ...
- * silent-yacc-generic.test, silent-yacc-gcc.test: ... these new
- sister tests, the latter of which forces gcc depmode and lists
- "gcc" in $required.
+ * tests/silent5.test: Test removed, its content split into ...
+ * tests/silent-many-generic.test, tests/silent-many-gcc.test: ...
+ these new sister tests, the latter of which forces gcc depmode
+ and lists "gcc" in $required.
+ * tests/silentlex.test: Test removed, its content split into ...
+ * tests/silent-lex-generic.test, tests/silent-lex-gcc.test: ...
+ these new sister tests, the latter of which forces gcc depmode
+ and lists "gcc" in $required.
+ * tests/silentyacc.test: Test removed, its content split into ...
+ * tests/silent-yacc-generic.test, tests/silent-yacc-gcc.test: ...
+ these new sister tests, the latter of which forces gcc depmode and
+ lists "gcc" in $required.
* tests/Makefile.am (TESTS): Updated.
2010-11-21 Stefano Lattarini <address@hidden>
diff --git a/HACKING b/HACKING
index a3e37f0..334d74c 100644
--- a/HACKING
+++ b/HACKING
@@ -20,6 +20,10 @@
* If somebody reports a new bug, mention his name in the ChangeLog entry
and in the test case you write. Put him into THANKS.
+* When documenting a non-trivial idiom or example in the manual, be
+ sure to add a test case for it, and to reference such test case from
+ a proper Texinfo comment.
+
* The correct response to most actual bugs is to write a new test case
which demonstrates the bug. Then fix the bug, re-run the test suite,
and check everything in.
@@ -240,7 +244,8 @@
-----
-Copyright (C) 2003, 2007, 2008, 2010 Free Software Foundation, Inc.
+Copyright (C) 2003, 2007, 2008, 2010, 2011 Free Software Foundation,
+Inc.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
diff --git a/Makefile.am b/Makefile.am
index 6e8b7df..835f00a 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -3,7 +3,8 @@
## Makefile for Automake.
# Copyright (C) 1995, 1996, 1997, 1998, 1999, 2001, 2002, 2003, 2004,
-# 2005, 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc.
+# 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software Foundation,
+# Inc.
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -76,6 +77,8 @@ do_subst = sed \
-e 's,address@hidden@],$(PERL),g' \
-e 's,address@hidden@],$(PERL_THREADS),g' \
-e 's,address@hidden@],$(SHELL),g' \
+ -e 's,address@hidden@],$(am_AUTOCONF),g' \
+ -e 's,address@hidden@],$(am_AUTOM4TE),g' \
-e 's,address@hidden@],$(VERSION),g' \
-e 's,address@hidden@],Generated from address@hidden; do not edit by
hand.,g' \
-e 's,address@hidden@],$(datadir),g'
@@ -113,6 +116,7 @@ dist-hook:
syntax_check_rules = \
sc_test_names \
sc_diff_automake_in_automake \
+sc_diff_aclocal_in_automake \
sc_perl_syntax \
sc_no_brace_variable_expansions \
sc_rm_minus_f \
@@ -132,6 +136,9 @@ sc_tests_plain_make \
sc_tests_plain_autoconf \
sc_tests_plain_autoupdate \
sc_tests_plain_automake \
+sc_tests_plain_autom4te \
+sc_tests_plain_autoheader \
+sc_tests_plain_autoreconf \
sc_tests_here_document_format \
sc_tests_Exit_not_exit \
sc_tests_automake_fails \
@@ -212,15 +219,22 @@ sc_test_names:
exit 1; \
fi
-## This check avoids accidental configure substitutions in the source.
-## There are exactly 8 lines that should be modified. This works out
-## to 28 lines of diffs.
+## These check avoids accidental configure substitutions in the source.
+## There are exactly 9 lines that should be modified from automake.in to
+## automake, and 10 lines that should be modified from aclocal.in to
+## aclocal; these wors out to 32 and 34 lines of diffs, respectively.
sc_diff_automake_in_automake:
- @if test `diff $(srcdir)/automake.in automake | wc -l` -ne 28; then \
+ @if test `diff $(srcdir)/automake.in automake | wc -l` -ne 32; then \
echo "found too many diffs between automake.in and automake" 1>&2; \
diff -c $(srcdir)/automake.in automake; \
exit 1; \
fi
+sc_diff_aclocal_in_aclocal:
+ @if test `diff $(srcdir)/aclocal.in aclocal | wc -l` -ne 34; then \
+ echo "found too many diffs between aclocal.in and aclocal" 1>&2; \
+ diff -c $(srcdir)/aclocal.in aclocal; \
+ exit 1; \
+ fi
## Syntax check with default Perl (on my machine, Perl 5).
sc_perl_syntax:
@@ -355,25 +369,46 @@ sc_tests_plain_make:
## Tests should never call autoconf directly.
sc_tests_plain_autoconf:
- @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[ ]*autoconf';
then \
+ @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[ ]*autoconf\>';
then \
echo 'Do not run "autoconf" in the above tests. Use "$$AUTOCONF"
instead.' 1>&2; \
exit 1; \
fi
## Tests should never call autoupdate directly.
sc_tests_plain_autoupdate:
- @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[ ]*autoupdate';
then \
+ @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[
]*autoupdate\>'; then \
echo 'Do not run "autoupdate" in the above tests. Use "$$AUTOUPDATE"
instead.' 1>&2; \
exit 1; \
fi
## Tests should never call automake directly.
sc_tests_plain_automake:
- @if grep -v '^#' $(srcdir)/tests/*.test | grep -E ':[
]*automake([^:]|$$)'; then \
+ @if grep -v '^#' $(srcdir)/tests/*.test | grep -E ':[
]*automake\>([^:]|$$)'; then \
echo 'Do not run "automake" in the above tests. Use "$$AUTOMAKE"
instead.' 1>&2; \
exit 1; \
fi
+## Tests should never call autoheader directly.
+sc_tests_plain_autoheader:
+ @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[
]*autoheader\>'; then \
+ echo 'Do not run "automake" in the above tests. Use "$$AUTOHEADER"
instead.' 1>&2; \
+ exit 1; \
+ fi
+
+## Tests should never call autoreconf directly.
+sc_tests_plain_autoreconf:
+ @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[
]*autoreconf\>'; then \
+ echo 'Do not run "automake" in the above tests. Use "$$AUTORECONF"
instead.' 1>&2; \
+ exit 1; \
+ fi
+
+## Tests should never call autom4te directly.
+sc_tests_plain_autom4te:
+ @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[ ]*autom4te\>';
then \
+ echo 'Do not run "automake" in the above tests. Use "$$AUTOM4TE"
instead.' 1>&2; \
+ exit 1; \
+ fi
+
## Tests should only use END and EOF for here documents
## (so that the next test is effective).
sc_tests_here_document_format:
@@ -384,9 +419,10 @@ sc_tests_here_document_format:
## Tests should never call exit directly, but use Exit.
## This is so that the exit status is transported correctly across the 0 trap.
-## Ignore comments, and ignore one perl line in ext2.test.
+## Ignore comments, testsuite self tests, and one perl line in ext2.test.
sc_tests_Exit_not_exit:
@found=false; for file in $(srcdir)/tests/*.test; do \
+ case $$file in */self-check-*.test) continue;; esac; \
res=`sed -n -e '/^#/d; /^\$$PERL/d' -e '/<<.*END/,/^END/b' \
-e '/<<.*EOF/,/^EOF/b' -e '/exit [$$0-9]/p' $$file`; \
if test -n "$$res"; then \
@@ -408,14 +444,14 @@ sc_tests_automake_fails:
## Tests should never call aclocal directly.
sc_tests_plain_aclocal:
- @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[ ]*aclocal';
then \
+ @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[ ]*aclocal\>';
then \
echo 'Do not run "aclocal" in the above tests. Use "$$ACLOCAL"
instead.' 1>&2; \
exit 1; \
fi
## Tests should never call perl directly.
sc_tests_plain_perl:
- @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[ ]*perl'; then \
+ @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[ ]*perl\>'; then
\
echo 'Do not run "perl" in the above tests. Use "$$PERL" instead.'
1>&2; \
exit 1; \
fi
@@ -430,17 +466,24 @@ sc_tests_required_after_defs:
done
## Overriding a Makefile macro on the command line is not portable when
-## recursive targets are used. Better use an envvar. SHELL is an exception,
-## POSIX says it can't come from the environment. V and DESTDIRS are
exceptions,
-## too, as package authors are urged not to initialize them anywhere.
+## recursive targets are used. Better use an envvar. SHELL is an
+## exception, POSIX says it can't come from the environment. DESTDIR and
+## DISTCHECK_CONFIGURE_FLAGS and V are exceptions, too, as package authors
+## are urged not to initialize them anywhere.
sc_tests_overriding_macros_on_cmdline:
@if grep -E '\$$MAKE .*(SHELL=.*=|=.*SHELL=)' $(srcdir)/tests/*.test;
then \
echo 'Rewrite "$$MAKE foo=bar SHELL=$$SHELL" as "foo=bar $$MAKE -e
SHELL=$$SHELL"' 1>&2; \
echo ' in the above lines, it is more portable.' 1>&2; \
exit 1; \
fi
- @if sed 's/DESTDIR=[^ ]*//; s/SHELL=[^ ]*//; s/V=[^ ]*//'
$(srcdir)/tests/*.test | \
- grep '\$$MAKE .*=' ; then \
+ @if sed -e 's/ DESTDIR=[^ ]*/ /' -e 's/ SHELL=[^ ]*/ /' \
+ -e 's/ V=[^ ]*/ /' -e 's///' \
+## DISTCHECK_CONFIGURE_FLAGS is allowed to contain whitespace in its
+## definition, so the more complex substitutions below.
+ -e "s/ DISTCHECK_CONFIGURE_FLAGS='[^']*'/ /" \
+ -e 's/ DISTCHECK_CONFIGURE_FLAGS="[^"]*"/ /' \
+ -e 's/ DISTCHECK_CONFIGURE_FLAGS=[^ ]/ /' \
+ $(srcdir)/tests/*.test | grep '\$$MAKE .*='; then \
echo 'Rewrite "$$MAKE foo=bar" as "foo=bar $$MAKE -e" in the above
lines,' 1>&2; \
echo 'it is more portable.' 1>&2; \
exit 1; \
diff --git a/Makefile.in b/Makefile.in
index a2d8b09..717853a 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -16,7 +16,8 @@
@SET_MAKE@
# Copyright (C) 1995, 1996, 1997, 1998, 1999, 2001, 2002, 2003, 2004,
-# 2005, 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc.
+# 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software Foundation,
+# Inc.
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -194,6 +195,9 @@ abs_top_builddir = @abs_top_builddir@
abs_top_srcdir = @abs_top_srcdir@
am_AUTOCONF = @am_AUTOCONF@
am_AUTOHEADER = @am_AUTOHEADER@
+am_AUTOM4TE = @am_AUTOM4TE@
+am_AUTORECONF = @am_AUTORECONF@
+am_AUTOUPDATE = @am_AUTOUPDATE@
am__leading_dot = @am__leading_dot@
am__tar = @am__tar@
am__untar = @am__untar@
@@ -261,6 +265,8 @@ do_subst = sed \
-e 's,address@hidden@],$(PERL),g' \
-e 's,address@hidden@],$(PERL_THREADS),g' \
-e 's,address@hidden@],$(SHELL),g' \
+ -e 's,address@hidden@],$(am_AUTOCONF),g' \
+ -e 's,address@hidden@],$(am_AUTOM4TE),g' \
-e 's,address@hidden@],$(VERSION),g' \
-e 's,address@hidden@],Generated from address@hidden; do not edit by
hand.,g' \
-e 's,address@hidden@],$(datadir),g'
@@ -271,6 +277,7 @@ do_subst = sed \
syntax_check_rules = \
sc_test_names \
sc_diff_automake_in_automake \
+sc_diff_aclocal_in_automake \
sc_perl_syntax \
sc_no_brace_variable_expansions \
sc_rm_minus_f \
@@ -290,6 +297,9 @@ sc_tests_plain_make \
sc_tests_plain_autoconf \
sc_tests_plain_autoupdate \
sc_tests_plain_automake \
+sc_tests_plain_autom4te \
+sc_tests_plain_autoheader \
+sc_tests_plain_autoreconf \
sc_tests_here_document_format \
sc_tests_Exit_not_exit \
sc_tests_automake_fails \
@@ -372,7 +382,7 @@ texinfo.tex
all: all-recursive
.SUFFIXES:
-am--refresh:
+am--refresh: Makefile
@:
$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
@for dep in $?; do \
@@ -714,6 +724,7 @@ distcheck: dist
&& am__cwd=`pwd` \
&& $(am__cd) $(distdir)/_build \
&& ../configure --srcdir=.. --prefix="$$dc_install_base" \
+ $(AM_DISTCHECK_CONFIGURE_FLAGS) \
$(DISTCHECK_CONFIGURE_FLAGS) \
&& $(MAKE) $(AM_MAKEFLAGS) \
&& $(MAKE) $(AM_MAKEFLAGS) dvi \
@@ -939,11 +950,17 @@ sc_test_names:
fi
sc_diff_automake_in_automake:
- @if test `diff $(srcdir)/automake.in automake | wc -l` -ne 28; then \
+ @if test `diff $(srcdir)/automake.in automake | wc -l` -ne 32; then \
echo "found too many diffs between automake.in and automake" 1>&2; \
diff -c $(srcdir)/automake.in automake; \
exit 1; \
fi
+sc_diff_aclocal_in_aclocal:
+ @if test `diff $(srcdir)/aclocal.in aclocal | wc -l` -ne 34; then \
+ echo "found too many diffs between aclocal.in and aclocal" 1>&2; \
+ diff -c $(srcdir)/aclocal.in aclocal; \
+ exit 1; \
+ fi
sc_perl_syntax:
perllibdir="./lib$(PATH_SEPARATOR)$(srcdir)/lib" $(PERL) -c -w automake
@@ -1057,23 +1074,41 @@ sc_tests_plain_make:
fi
sc_tests_plain_autoconf:
- @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[ ]*autoconf';
then \
+ @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[ ]*autoconf\>';
then \
echo 'Do not run "autoconf" in the above tests. Use "$$AUTOCONF"
instead.' 1>&2; \
exit 1; \
fi
sc_tests_plain_autoupdate:
- @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[ ]*autoupdate';
then \
+ @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[
]*autoupdate\>'; then \
echo 'Do not run "autoupdate" in the above tests. Use "$$AUTOUPDATE"
instead.' 1>&2; \
exit 1; \
fi
sc_tests_plain_automake:
- @if grep -v '^#' $(srcdir)/tests/*.test | grep -E ':[
]*automake([^:]|$$)'; then \
+ @if grep -v '^#' $(srcdir)/tests/*.test | grep -E ':[
]*automake\>([^:]|$$)'; then \
echo 'Do not run "automake" in the above tests. Use "$$AUTOMAKE"
instead.' 1>&2; \
exit 1; \
fi
+sc_tests_plain_autoheader:
+ @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[
]*autoheader\>'; then \
+ echo 'Do not run "automake" in the above tests. Use "$$AUTOHEADER"
instead.' 1>&2; \
+ exit 1; \
+ fi
+
+sc_tests_plain_autoreconf:
+ @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[
]*autoreconf\>'; then \
+ echo 'Do not run "automake" in the above tests. Use "$$AUTORECONF"
instead.' 1>&2; \
+ exit 1; \
+ fi
+
+sc_tests_plain_autom4te:
+ @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[ ]*autom4te\>';
then \
+ echo 'Do not run "automake" in the above tests. Use "$$AUTOM4TE"
instead.' 1>&2; \
+ exit 1; \
+ fi
+
sc_tests_here_document_format:
@if grep '<<' $(srcdir)/tests/*.test | grep -v 'END' | grep -v 'EOF';
then \
echo 'Use here documents with "END" and "EOF" only, for
greppability.' 1>&2; \
@@ -1082,6 +1117,7 @@ sc_tests_here_document_format:
sc_tests_Exit_not_exit:
@found=false; for file in $(srcdir)/tests/*.test; do \
+ case $$file in */self-check-*.test) continue;; esac; \
res=`sed -n -e '/^#/d; /^\$$PERL/d' -e '/<<.*END/,/^END/b' \
-e '/<<.*EOF/,/^EOF/b' -e '/exit [$$0-9]/p' $$file`; \
if test -n "$$res"; then \
@@ -1101,13 +1137,13 @@ sc_tests_automake_fails:
fi
sc_tests_plain_aclocal:
- @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[ ]*aclocal';
then \
+ @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[ ]*aclocal\>';
then \
echo 'Do not run "aclocal" in the above tests. Use "$$ACLOCAL"
instead.' 1>&2; \
exit 1; \
fi
sc_tests_plain_perl:
- @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[ ]*perl'; then \
+ @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[ ]*perl\>'; then
\
echo 'Do not run "perl" in the above tests. Use "$$PERL" instead.'
1>&2; \
exit 1; \
fi
@@ -1126,8 +1162,12 @@ sc_tests_overriding_macros_on_cmdline:
echo ' in the above lines, it is more portable.' 1>&2; \
exit 1; \
fi
- @if sed 's/DESTDIR=[^ ]*//; s/SHELL=[^ ]*//; s/V=[^ ]*//'
$(srcdir)/tests/*.test | \
- grep '\$$MAKE .*=' ; then \
+ @if sed -e 's/ DESTDIR=[^ ]*/ /' -e 's/ SHELL=[^ ]*/ /' \
+ -e 's/ V=[^ ]*/ /' -e 's///' \
+ -e "s/ DISTCHECK_CONFIGURE_FLAGS='[^']*'/ /" \
+ -e 's/ DISTCHECK_CONFIGURE_FLAGS="[^"]*"/ /' \
+ -e 's/ DISTCHECK_CONFIGURE_FLAGS=[^ ]/ /' \
+ $(srcdir)/tests/*.test | grep '\$$MAKE .*='; then \
echo 'Rewrite "$$MAKE foo=bar" as "foo=bar $$MAKE -e" in the above
lines,' 1>&2; \
echo 'it is more portable.' 1>&2; \
exit 1; \
diff --git a/NEWS b/NEWS
index 6d6c76b..74bd963 100644
--- a/NEWS
+++ b/NEWS
@@ -1,10 +1,23 @@
New in 1.11.1a:
+* WARNING: Future backward-incompatibilities!
+
+ - The Automake support for automatic de-ANSI-fication will be removed in
+ the next major Automake release (1.12).
+
* Miscellaneous changes:
- The `lzma' compression scheme and associated automake option `dist-lzma'
is obsoleted by `xz' and `dist-xz' due to upstream changes.
+ - A developer that needs to pass specific flags to configure at "make
+ distcheck" time can now, and indeed he's advised to, do so by defining
+ the developer-reserved makefile variable AM_DISTCHECK_CONFIGURE_FLAGS,
+ instead of the old DISTCHECK_CONFIGURE_FLAGS.
+ The DISTCHECK_CONFIGURE_FLAGS variable should now be reserved for the
+ user; still, the old Makefile.am files that used to define it should
+ still continue to work as before.
+
Bugs fixed in 1.11.1a:
* Bugs introduced by 1.11.1:
@@ -28,6 +41,15 @@ Bugs fixed in 1.11.1a:
languages: $(AM_YFLAGS) comes before $(YFLAGS), and $(AM_LFLAGS) before
$(LFLAGS), so that the user variables override the developer variables.
+ - Automake now warns about more primary/directory invalid combinations,
+ such as "doc_LIBRARIES" or "pkglib_PROGRAMS".
+
+ - On Darwin 9, `pythondir' and `pyexecdir' pointed below `/Library/Python'
+ even if the `--prefix' argument pointed outside of a system directory.
+ AM_PATH_PYTHON has been fixed to ignore the value returned from python's
+ `get_python_lib' function if it points outside the configured prefix,
+ unless the `--prefix' argument was either `/usr' or below `/System'.
+
- The AM_COND_IF macro also works if the shell expression for the conditional
is no longer valid for the condition.
@@ -60,6 +82,10 @@ Bugs fixed in 1.11.1a:
- Java sources specified with check_JAVA are not compiled anymore upon
"make all", but only upon "make check".
+
+ - Now aclocal and automake, when they've to spawn autoconf or autom4te
+ processes, honour the configure-time definitions of AUTOCONF and
+ AUTOM4TE.
Bugs fixed in 1.11.1:
diff --git a/THANKS b/THANKS
index 593ebc5..3d71419 100644
--- a/THANKS
+++ b/THANKS
@@ -37,6 +37,7 @@ Benoit Sigoure address@hidden
Bernard Giroud address@hidden
Bernard Urban address@hidden
Bernd Jendrissek address@hidden
+Bert Wesarg address@hidden
Bill Currie address@hidden
Bill Davidson address@hidden
Bill Fenner address@hidden
@@ -117,6 +118,7 @@ Geoffrey Keating address@hidden
Glenn Amerine address@hidden
Gord Matzigkeit address@hidden
Gordon Sadler address@hidden
+Graham Reitz address@hidden
Greg A. Woods address@hidden
Greg Schafer address@hidden
Guido Draheim address@hidden
diff --git a/aclocal.in b/aclocal.in
index 2210fe3..4b63c1a 100644
--- a/aclocal.in
+++ b/aclocal.in
@@ -663,7 +663,7 @@ sub trace_used_macros ()
my %files = map { $map{$_} => 1 } keys %macro_seen;
%files = strip_redundant_includes %files;
- my $traces = ($ENV{AUTOM4TE} || 'autom4te');
+ my $traces = ($ENV{AUTOM4TE} || '@am_AUTOM4TE@');
$traces .= " --language Autoconf-without-aclocal-m4 ";
# All candidate files.
$traces .= join (' ',
diff --git a/automake.in b/automake.in
index a8ec749..d0d986e 100755
--- a/automake.in
+++ b/automake.in
@@ -249,11 +249,11 @@ my @common_sometimes =
# Standard directories from the GNU Coding Standards, and additional
# pkg* directories from Automake. Stored in a hash for fast member check.
my %standard_prefix =
- map { $_ => 1 } (qw(bin data dataroot dvi exec html include info
- lib libexec lisp localstate man man1 man2 man3
- man4 man5 man6 man7 man8 man9 oldinclude pdf
- pkgdatadir pkgincludedir pkglibdir pkglibexecdir
- ps sbin sharedstate sysconf));
+ map { $_ => 1 } (qw(bin data dataroot doc dvi exec html include info
+ lib libexec lisp locale localstate man man1 man2
+ man3 man4 man5 man6 man7 man8 man9 oldinclude pdf
+ pkgdata pkginclude pkglib pkglibexec ps sbin
+ sharedstate sysconf));
# Copyright on generated Makefile.ins.
my $gen_copyright = "\
@@ -2636,7 +2636,7 @@ sub handle_libtool
sub handle_programs
{
my @proglist = &am_install_var ('progs', 'PROGRAMS',
- 'bin', 'sbin', 'libexec', 'pkglib',
+ 'bin', 'sbin', 'libexec', 'pkglibexec',
'noinst', 'check');
return if ! @proglist;
@@ -3746,8 +3746,8 @@ sub handle_man_pages
sub handle_data
{
&am_install_var ('-noextra', '-candist', 'data', 'DATA',
- 'data', 'dataroot', 'dvi', 'html', 'pdf', 'ps',
- 'sysconf', 'sharedstate', 'localstate',
+ 'data', 'dataroot', 'doc', 'dvi', 'html', 'pdf',
+ 'ps', 'sysconf', 'sharedstate', 'localstate',
'pkgdata', 'lisp', 'noinst', 'check');
}
@@ -5281,7 +5281,7 @@ sub scan_autoconf_traces ($)
sinclude => 1,
);
- my $traces = ($ENV{AUTOCONF} || 'autoconf') . " ";
+ my $traces = ($ENV{AUTOCONF} || '@am_AUTOCONF@') . " ";
# Use a separator unlikely to be used, not `:', the default, which
# has a precise meaning for AC_CONFIG_FILES and so on.
@@ -8323,6 +8323,50 @@ sub generate_makefile ($$)
################################################################
+# Helper function for usage().
+sub print_autodist_files (@)
+{
+ my @lcomm = sort (&uniq (@_));
+
+ my @four;
+ format USAGE_FORMAT =
+ @<<<<<<<<<<<<<<<< @<<<<<<<<<<<<<<<< @<<<<<<<<<<<<<<<< @<<<<<<<<<<<<<<<<
+ $four[0], $four[1], $four[2], $four[3]
+.
+ local $~ = "USAGE_FORMAT";
+
+ my $cols = 4;
+ my $rows = int(@lcomm / $cols);
+ my $rest = @lcomm % $cols;
+
+ if ($rest)
+ {
+ $rows++;
+ }
+ else
+ {
+ $rest = $cols;
+ }
+
+ for (my $y = 0; $y < $rows; $y++)
+ {
+ @four = ("", "", "", "");
+ for (my $x = 0; $x < $cols; $x++)
+ {
+ last if $y + 1 == $rows && $x == $rest;
+
+ my $idx = (($x > $rest)
+ ? ($rows * $rest + ($rows - 1) * ($x - $rest))
+ : ($rows * $x));
+
+ $idx += $y;
+ $four[$x] = $lcomm[$idx];
+ }
+ write;
+ }
+}
+
+
# Print usage information.
sub usage ()
{
@@ -8356,51 +8400,12 @@ Library files:
";
Automake::ChannelDefs::usage;
- my ($last, @lcomm);
- $last = '';
- foreach my $iter (sort ((@common_files, @common_sometimes)))
- {
- push (@lcomm, $iter) unless $iter eq $last;
- $last = $iter;
- }
-
- my @four;
- print "\nFiles which are automatically distributed, if found:\n";
- format USAGE_FORMAT =
- @<<<<<<<<<<<<<<<< @<<<<<<<<<<<<<<<< @<<<<<<<<<<<<<<<< @<<<<<<<<<<<<<<<<
- $four[0], $four[1], $four[2], $four[3]
-.
- $~ = "USAGE_FORMAT";
-
- my $cols = 4;
- my $rows = int(@lcomm / $cols);
- my $rest = @lcomm % $cols;
-
- if ($rest)
- {
- $rows++;
- }
- else
- {
- $rest = $cols;
- }
-
- for (my $y = 0; $y < $rows; $y++)
- {
- @four = ("", "", "", "");
- for (my $x = 0; $x < $cols; $x++)
- {
- last if $y + 1 == $rows && $x == $rest;
-
- my $idx = (($x > $rest)
- ? ($rows * $rest + ($rows - 1) * ($x - $rest))
- : ($rows * $x));
-
- $idx += $y;
- $four[$x] = $lcomm[$idx];
- }
- write;
- }
+ print "\nFiles automatically distributed if found " .
+ "(always):\n";
+ print_autodist_files @common_files;
+ print "\nFiles automatically distributed if found " .
+ "(under certain conditions):\n";
+ print_autodist_files @common_sometimes;
print '
Report bugs to <@PACKAGE_BUGREPORT@>.
diff --git a/configure b/configure
index 66f0178..d6ae9d8 100755
--- a/configure
+++ b/configure
@@ -603,7 +603,10 @@ am__isrc
INSTALL_DATA
INSTALL_SCRIPT
INSTALL_PROGRAM
+am_AUTOUPDATE
am_AUTOHEADER
+am_AUTORECONF
+am_AUTOM4TE
am_AUTOCONF
build_os
build_vendor
@@ -1774,11 +1777,18 @@ case $build_os in *\ *) build_os=`echo "$build_os" |
sed 's/ /-/g'`;; esac
# Save the AUTOCONF setting before AM_INIT_AUTOMAKE overrides it; this
# way we can run Autoconf tests from configure (or from the test
-# suite) without being bothered by `missing'. Likewise for autoheader.
+# suite) without being bothered by `missing'. Likewise for autom4te,
+# autoreconf, autoheader, and autoupdate.
am_AUTOCONF="${AUTOCONF-autoconf}"
+am_AUTOM4TE="${AUTOM4TE-autom4te}"
+
+am_AUTORECONF="${AUTORECONF-autoreconf}"
+
am_AUTOHEADER="${AUTOHEADER-autoheader}"
+am_AUTOUPDATE="${AUTOUPDATE-autoupdate}"
+
am__api_version='1.11'
diff --git a/configure.ac b/configure.ac
index a32d430..3b02705 100644
--- a/configure.ac
+++ b/configure.ac
@@ -28,9 +28,13 @@ AC_CANONICAL_BUILD
# Save the AUTOCONF setting before AM_INIT_AUTOMAKE overrides it; this
# way we can run Autoconf tests from configure (or from the test
-# suite) without being bothered by `missing'. Likewise for autoheader.
+# suite) without being bothered by `missing'. Likewise for autom4te,
+# autoreconf, autoheader, and autoupdate.
AC_SUBST([am_AUTOCONF], ["${AUTOCONF-autoconf}"])
+AC_SUBST([am_AUTOM4TE], ["${AUTOM4TE-autom4te}"])
+AC_SUBST([am_AUTORECONF], ["${AUTORECONF-autoreconf}"])
AC_SUBST([am_AUTOHEADER], ["${AUTOHEADER-autoheader}"])
+AC_SUBST([am_AUTOUPDATE], ["${AUTOUPDATE-autoupdate}"])
AM_INIT_AUTOMAKE([1.10a dist-bzip2 filename-length-max=99 color-tests
parallel-tests])
diff --git a/doc/Makefile.am b/doc/Makefile.am
index bb48fa2..f4f76c6 100644
--- a/doc/Makefile.am
+++ b/doc/Makefile.am
@@ -73,8 +73,14 @@ $(srcdir)/amhello-1.0.tar.gz: $(amhello_sources)
$(top_srcdir)/configure.ac
PATH="`pwd`/../tests$(PATH_SEPARATOR)$$PATH" && \
export PATH && \
cd $(srcdir)/amhello && \
- ACLOCAL=aclocal-$(APIVERSION) AUTOMAKE=automake-$(APIVERSION) \
- autoreconf -vfi && \
+ ACLOCAL=aclocal-$(APIVERSION) && export ACLOCAL && \
+ AUTOMAKE=automake-$(APIVERSION) && export AUTOMAKE && \
+ AUTOCONF='$(am_AUTOCONF)' && export AUTOCONF && \
+ AUTOM4TE='$(am_AUTOM4TE)' && export AUTOM4TE && \
+ AUTORECONF='$(am_AUTORECONF)' && export AUTORECONF && \
+ AUTOHEADER='$(am_AUTOHEADER)' && export AUTOHEADER && \
+ AUTOUPDATE='$(am_AUTOUPDATE)' && export AUTOUPDATE && \
+ $(am_AUTORECONF) -vfi && \
./configure && \
$(MAKE) $(AM_MAKEFLAGS) distcheck && \
$(MAKE) $(AM_MAKEFLAGS) distclean && \
diff --git a/doc/Makefile.in b/doc/Makefile.in
index 18e0e87..60b8ece 100644
--- a/doc/Makefile.in
+++ b/doc/Makefile.in
@@ -161,6 +161,9 @@ abs_top_builddir = @abs_top_builddir@
abs_top_srcdir = @abs_top_srcdir@
am_AUTOCONF = @am_AUTOCONF@
am_AUTOHEADER = @am_AUTOHEADER@
+am_AUTOM4TE = @am_AUTOM4TE@
+am_AUTORECONF = @am_AUTORECONF@
+am_AUTOUPDATE = @am_AUTOUPDATE@
am__leading_dot = @am__leading_dot@
am__tar = @am__tar@
am__untar = @am__untar@
@@ -817,8 +820,14 @@ $(srcdir)/amhello-1.0.tar.gz: $(amhello_sources)
$(top_srcdir)/configure.ac
PATH="`pwd`/../tests$(PATH_SEPARATOR)$$PATH" && \
export PATH && \
cd $(srcdir)/amhello && \
- ACLOCAL=aclocal-$(APIVERSION) AUTOMAKE=automake-$(APIVERSION) \
- autoreconf -vfi && \
+ ACLOCAL=aclocal-$(APIVERSION) && export ACLOCAL && \
+ AUTOMAKE=automake-$(APIVERSION) && export AUTOMAKE && \
+ AUTOCONF='$(am_AUTOCONF)' && export AUTOCONF && \
+ AUTOM4TE='$(am_AUTOM4TE)' && export AUTOM4TE && \
+ AUTORECONF='$(am_AUTORECONF)' && export AUTORECONF && \
+ AUTOHEADER='$(am_AUTOHEADER)' && export AUTOHEADER && \
+ AUTOUPDATE='$(am_AUTOUPDATE)' && export AUTOUPDATE && \
+ $(am_AUTORECONF) -vfi && \
./configure && \
$(MAKE) $(AM_MAKEFLAGS) distcheck && \
$(MAKE) $(AM_MAKEFLAGS) distclean && \
diff --git a/doc/automake.texi b/doc/automake.texi
index d60ca50..bea9f4e 100644
--- a/doc/automake.texi
+++ b/doc/automake.texi
@@ -84,7 +84,8 @@ section entitled ``GNU Free Documentation License.''
@c Put the macros in the function index.
@syncodeindex ac fn
address@hidden Put everything else into one index (arbitrarily chosen to be the
concept index).
address@hidden Put everything else into one index (arbitrarily chosen to be the
address@hidden concept index).
@syncodeindex op cp
@syncodeindex tr cp
@syncodeindex cm cp
@@ -117,6 +118,7 @@ section entitled ``GNU Free Documentation License.''
* Miscellaneous:: Miscellaneous rules
* Include:: Including extra files in an Automake template
* Conditionals:: Conditionals
+* Silencing Make:: Obtain less verbose output from @command{make}
* Gnits:: The effect of @option{--gnu} and
@option{--gnits}
* Cygnus:: The effect of @option{--cygnus}
* Not Enough:: When Automake is not Enough
@@ -231,7 +233,7 @@ Building Programs and Libraries
* Java Support:: Compiling Java sources
* Vala Support:: Compiling Vala sources
* Support for Other Languages:: Compiling other languages
-* ANSI:: Automatic de-ANSI-fication (obsolete)
+* ANSI:: Automatic de-ANSI-fication (deprecated, soon
to be removed)
* Dependencies:: Automatic dependency tracking
* EXEEXT:: Support for executable extensions
@@ -331,6 +333,12 @@ Conditionals
* Usage of Conditionals:: Declaring conditional content
* Limits of Conditionals:: Enclosing complete statements
+Silencing Make
+
+* Make verbosity:: Make is verbose by default
+* Tricks For Silencing Make:: Standard and generic ways to silence make
+* Automake silent-rules Option:: How Automake can help in silencing make
+
When Automake Isn't Enough
* Extending:: Adding new rules or overriding existing ones.
@@ -896,6 +904,7 @@ GNU Make Manual}).
VPATH builds have other interesting uses. One is to build the same
sources with multiple configurations. For instance:
address@hidden Keep in sync with amhello-cflags.test.
@example
~ % @kbd{tar zxf ~/amhello-1.0.tar.gz}
~ % @kbd{cd amhello-1.0}
@@ -1047,6 +1056,7 @@ instance my cross-compiler for MinGW32 has its binaries
called
Here is how we could build @code{amhello-1.0} for
@code{i586-mingw32msvc} on a GNU/Linux PC.
address@hidden Keep in sync with amhello-cross-compile.test.
@smallexample
~/amhello-1.0 % @kbd{./configure --build i686-pc-linux-gnu --host
i586-mingw32msvc}
checking for a BSD-compatible install... /usr/bin/install -c
@@ -1161,6 +1171,7 @@ by some means.
For instance here is how we could create a binary package containing a
snapshot of all the files to be installed.
address@hidden Keep in sync with amhello-binpkg.test.
@example
~/amhello-1.0 % @kbd{./configure --prefix /usr}
@dots{}
@@ -1840,6 +1851,7 @@ When examining a variable definition, Automake will
recursively examine
variables referenced in the definition. For example, if Automake is
looking at the content of @code{foo_SOURCES} in this snippet
address@hidden Keep in sync with interp.test.
@example
xs = a.c b.c
foo_SOURCES = c.c $(xs)
@@ -2018,6 +2030,7 @@ defined (e.g., @samp{zardir}).
For instance, the following snippet will install @file{file.xml} into
@samp{$(datadir)/xml}.
address@hidden Keep in sync with primary-prefix-couples-documented-valid.test.
@example
xmldir = $(datadir)/xml
xml_DATA = file.xml
@@ -2028,6 +2041,7 @@ performs to diagnose suspicious directory/primary couples
(in the
unlikely case these checks are undesirable, and you really know what
you're doing). For example, Automake would error out on this input:
address@hidden Should be tested in primary-prefix-invalid-couples.test.
@example
# Forbidden directory combinations, automake will error out on this.
pkglib_PROGRAMS = foo
@@ -2037,6 +2051,7 @@ doc_LIBRARIES = libquux.a
@noindent
but it will succeed with this:
address@hidden Keep in sync with primary-prefix-couples-documented-valid.test.
@example
# Work around forbidden directory combinations. Do not use this
# without a very good reason!
@@ -2117,6 +2132,7 @@ data_DATA = file1 @dots{} address@hidden address@hidden
@dots{} address@hidden
@noindent
may also be written as
address@hidden Keep in sync with primary-prefix-couples-documented-valid.test.
@example
data_DATA = file1 @dots{} address@hidden
data2dir = $(datadir)
@@ -2219,8 +2235,9 @@ source in case you need more recent versions.
@table @code
@item ansi2knr.c
@itemx ansi2knr.1
-These two files are used for de-ANSI-fication support (obsolete
address@hidden).
+These two files are used for de-ANSI-fication support (they are
+deprecated now, and @emph{will be removed} in the next major Automake
+release; @pxref{ANSI}).
@item compile
This is a wrapper for compilers that do not accept options @option{-c}
@@ -2440,24 +2457,13 @@ false.o: true.c
$(COMPILE) -DEXIT_CODE=1 -c true.c && mv true.o false.o
@end example
-Also, these explicit rules do not work if the obsolete de-ANSI-fication feature
-is used (@pxref{ANSI}). Supporting de-ANSI-fication requires a little
-more work:
-
address@hidden
-true_.o: true_.c false_.o
- $(COMPILE) -DEXIT_CODE=0 -c true_.c
-
-false_.o: true_.c
- $(COMPILE) -DEXIT_CODE=1 -c true_.c && mv true_.o false_.o
address@hidden example
-
As it turns out, there is also a much easier way to do this same task.
-Some of the above techniques are useful enough that we've kept the
+Some of the above technique is useful enough that we've kept the
example in the manual. However if you were to build @code{true} and
@code{false} in real life, you would probably use per-program
compilation flags, like so:
address@hidden Keep in sync with specflg7.test and specflg8.test.
@example
bin_PROGRAMS = false true
@@ -2469,10 +2475,9 @@ true_CPPFLAGS = -DEXIT_CODE=0
@end example
In this case Automake will cause @file{true.c} to be compiled twice,
-with different flags. De-ANSI-fication will work automatically. In
-this instance, the names of the object files would be chosen by
-automake; they would be @file{false-true.o} and @file{true-true.o}.
-(The name of the object files rarely matters.)
+with different flags. In this instance, the names of the object files
+would be chosen by automake; they would be @file{false-true.o} and
address@hidden (The name of the object files rarely matters.)
@node Invoking Automake
@@ -2782,6 +2787,7 @@ literals. If part of the specification uses shell
variables,
@command{automake} will not be able to fulfill this setup, and you will
have to complete the missing bits by hand. For instance, on
address@hidden Keep in sync with output11.test.
@example
file=input
@dots{}
@@ -2797,6 +2803,7 @@ source file.)
Similarly
address@hidden Keep in sync with output11.test.
@example
file=output
file2=out:in
@@ -3026,8 +3033,9 @@ this way, e.g., @code{AC_PATH_XTRA} defines
@code{X_CFLAGS} and
if @code{AC_PATH_XTRA} is called.
@item AM_C_PROTOTYPES
-This is required when using the obsolete de-ANSI-fication feature; see
address@hidden
+This is required when using the deprecated de-ANSI-fication feature;
address@hidden @emph{It will be removed} in the next major Automake
+release.
@item AM_CONDITIONAL
This introduces an Automake conditional (@pxref{Conditionals}).
@@ -3423,6 +3431,7 @@ installs this macro so that @command{aclocal} will find
it.
A macro file's name should end in @file{.m4}. Such files should be
installed in @file{$(datadir)/aclocal}. This is as simple as writing:
address@hidden Keep in sync with primary-prefix-couples-documented-valid.test.
@example
aclocaldir = $(datadir)/aclocal
aclocal_DATA = mymacro.m4 myothermacro.m4
@@ -4003,8 +4012,10 @@ Autoconf Manual}).
Check to see if function prototypes are understood by the compiler. If
so, define @samp{PROTOTYPES} and set the output variables @code{U} and
@code{ANSI2KNR} to the empty string. Otherwise, set @code{U} to
address@hidden and @code{ANSI2KNR} to @samp{./ansi2knr}. Automake uses these
-values to implement the obsolete de-ANSI-fication feature.
address@hidden and @code{ANSI2KNR} to @samp{./ansi2knr}. Automake used these
+values to implement the deprecated de-ANSI-fication feature; however,
+support for @emph{that feature will be removed} in the next major Automake
+release, and then @emph{these macros and variables will go away as well}.
@item AM_CONFIG_HEADER
@acindex AM_CONFIG_HEADER
@@ -4259,9 +4270,7 @@ does not know the possible values of these variables. In
this case
@cindex @code{SUBDIRS} and @code{AM_CONDITIONAL}
@cindex @code{AM_CONDITIONAL} and @code{SUBDIRS}
address@hidden The test case for the setup described here is
address@hidden test/subdircond2.test
address@hidden Try to keep it in sync.
address@hidden Keep in sync with subcond2.test.
@file{configure} should output the @file{Makefile} for each directory
and define a condition into which @file{opt/} should be built.
@@ -4301,9 +4310,7 @@ automatically because it knows that @code{MAYBE_OPT} can
contain
@cindex @code{SUBDIRS} and @code{AC_SUBST}
@cindex @code{AC_SUBST} and @code{SUBDIRS}
address@hidden The test case for the setup described here is
address@hidden test/subdircond3.test
address@hidden Try to keep it in sync.
address@hidden Keep in sync with subcond3.test.
Another possibility is to define @code{MAYBE_OPT} from
@file{./configure} using @code{AC_SUBST}:
@@ -4461,6 +4468,7 @@ often be replaced by several variables, one for each
destination
directory (@pxref{Uniform}). For instance, the last example could be
rewritten as follows:
address@hidden Keep in sync with primary-prefix-couples-documented-valid.test.
@example
imagesdir = $(pkgdatadir)/images
soundsdir = $(pkgdatadir)/sounds
@@ -4604,7 +4612,7 @@ to build programs and libraries.
* Java Support:: Compiling Java sources
* Vala Support:: Compiling Vala sources
* Support for Other Languages:: Compiling other languages
-* ANSI:: Automatic de-ANSI-fication (obsolete)
+* ANSI:: Automatic de-ANSI-fication (deprecated, soon
to be removed)
* Dependencies:: Automatic dependency tracking
* EXEEXT:: Support for executable extensions
@end menu
@@ -4635,14 +4643,14 @@ programs. Most of the comments about these also apply
to libraries
@vindex bin_PROGRAMS
@vindex sbin_PROGRAMS
@vindex libexec_PROGRAMS
address@hidden pkglib_PROGRAMS
address@hidden pkglibexec_PROGRAMS
@vindex noinst_PROGRAMS
@vindex check_PROGRAMS
In a directory containing source that gets built into a program (as
opposed to a library or a script), the @code{PROGRAMS} primary is used.
Programs can be installed in @code{bindir}, @code{sbindir},
address@hidden, @code{pkglibdir}, @code{pkglibexecdir}, or not at all
address@hidden, @code{pkglibexecdir}, or not at all
(@code{noinst_}). They can also be built only for @samp{make check}, in
which case the prefix is @samp{check_}.
@@ -4911,6 +4919,7 @@ You can also use Automake conditionals
(@pxref{Conditionals}) to
select programs to be built. In this case you don't have to worry
about @samp{$(EXEEXT)} or @code{EXTRA_PROGRAMS}.
address@hidden Keep in sync with exeext.test.
@example
bin_PROGRAMS = cpio pax
if WANT_MT
@@ -4961,6 +4970,7 @@ Extra objects can be added to a library using the
@address@hidden variable. This should be used for objects
determined by @command{configure}. Again from @code{cpio}:
address@hidden Keep in sync with pr401c.test.
@example
libcpio_a_LIBADD = $(LIBOBJS) $(ALLOCA)
@end example
@@ -5164,6 +5174,7 @@ relates to @file{libfoo.la} or @file{libbar.la} at the
time it creates
the link rule for these two libraries. Therefore the @option{-rpath}
argument must be explicitly supplied.
address@hidden Keep in sync with ltcond.test.
@example
EXTRA_LTLIBRARIES = libfoo.la libbar.la
lib_LTLIBRARIES = $(WANTEDLIBS)
@@ -5179,6 +5190,7 @@ Automake is able to compute the @option{-rpath} setting
itself, because
it's clear that both libraries will end up in @samp{$(libdir)} if they
are installed.
address@hidden Keep in sync with ltcond.test.
@example
lib_LTLIBRARIES =
if WANT_LIBFOO
@@ -5205,6 +5217,7 @@ we could build a @file{libhello.la} library using either
@file{hello-linux.c} or @file{hello-generic.c} with the following
@file{Makefile.am}.
address@hidden Keep in sync with ltcond2.test.
@example
lib_LTLIBRARIES = libhello.la
libhello_la_SOURCES = hello-common.c
@@ -5219,6 +5232,7 @@ either @file{hello-linux.lo} or @address@hidden
Or we could simply use an Automake conditional as follows.
address@hidden Keep in sync with ltcond2.test.
@example
lib_LTLIBRARIES = libhello.la
libhello_la_SOURCES = hello-common.c
@@ -5258,6 +5272,7 @@ dependency anywhere it won't be built (this is why
Here is a sample setup merging libtool convenience libraries from
subdirectories into one main @file{libtop.la} library.
address@hidden Keep in sync with ltconv.test.
@example
# -- Top-level Makefile.am --
SUBDIRS = sub1 sub2 @dots{}
@@ -5831,8 +5846,8 @@ needs to be avoided: when a target should not be built
from sources.
We already saw such an example in @ref{true}; this happens when all
the constituents of a target have already been compiled and just need
to be combined using a @code{_LDADD} variable. Then it is necessary
-to define an empty @code{_SOURCES} variable, so that @command{automake} does
not
-compute a default.
+to define an empty @code{_SOURCES} variable, so that @command{automake}
+does not compute a default.
@example
bin_PROGRAMS = target
@@ -6753,13 +6768,14 @@ suffix rule handling (@pxref{Suffixes}).
@node ANSI
address@hidden Automatic de-ANSI-fication
address@hidden Automatic de-ANSI-fication (deprecated, soon to be removed)
@cindex de-ANSI-fication, defined
-The features described in this section are obsolete; you should not
-used any of them in new code, and they may be withdrawn in future
-Automake releases.
address@hidden features described in this section are deprecated; you must
+not use any of them in new code, and remove their use from older but
+still maintained code: they will be withdrawn in the next major
+Automake release.}
When the C language was standardized in 1989, there was a long
transition period where package developers needed to worry about
@@ -6813,8 +6829,9 @@ If no directory prefix is given, the files are assumed to
be in the
current directory.
Note that automatic de-ANSI-fication will not work when the package is
-being built for a different host architecture. That is because
@command{automake}
-currently has no way to build @command{ansi2knr} for the build machine.
+being built for a different host architecture. That is because
address@hidden currently has no way to build @command{ansi2knr}
+for the build machine.
@c FIXME: this paragraph might be better moved to an `upgrading' section.
@cindex @code{LTLIBOBJS} and @code{ansi2knr}
@@ -6908,10 +6925,10 @@ bin_PROGRAMS = liver$(EXEEXT)
The targets Automake generates are likewise given the @samp{$(EXEEXT)}
extension.
-The variables @code{TESTS} and @code{XFAIL_TESTS} (@pxref{Simple Tests}) are
also
-rewritten if they contain filenames that have been declared as programs
-in the same @file{Makefile}. (This is mostly useful when some programs
-from @code{check_PROGRAMS} are listed in @code{TESTS}.)
+The variables @code{TESTS} and @code{XFAIL_TESTS} (@pxref{Simple Tests})
+are also rewritten if they contain filenames that have been declared as
+programs in the same @file{Makefile}. (This is mostly useful when some
+programs from @code{check_PROGRAMS} are listed in @code{TESTS}.)
However, Automake cannot apply this rewriting to @command{configure}
substitutions. This means that if you are conditionally building a
@@ -7474,6 +7491,7 @@ variable explicitly prevents byte-compilation.
Since Automake 1.8, we now recommend using @code{lisp_DATA} instead:
address@hidden Keep in sync with primary-prefix-couples-documented-valid.test.
@example
lisp_DATA = file1.el file2.el
@end example
@@ -7527,6 +7545,7 @@ files are not included in the distribution, you should
use the
Here is a typical setup for distributing @file{.java} files and
installing the @file{.class} files resulting from their compilation.
address@hidden Keep in sync with primary-prefix-couples-documented-valid.test.
@example
javadir = $(datadir)/java
dist_java_JAVA = a.java b.java @dots{}
@@ -7600,12 +7619,13 @@ Automake ships with an Autoconf macro called
@code{AM_PATH_PYTHON}
that will determine some Python-related directory variables (see
below). If you have called @code{AM_PATH_PYTHON} from
@file{configure.ac}, then you may use the variables
address@hidden Keep in sync with primary-prefix-couples-documented-valid.test.
@code{python_PYTHON} or @code{pkgpython_PYTHON} to list Python source
files in your @file{Makefile.am}, depending on where you want your files
installed (see the definitions of @code{pythondir} and
@code{pkgpythondir} below).
address@hidden AM_PATH_PYTHON (@ovar{version}, @ovar{action-if-found}, @
address@hidden AM_PATH_PYTHON (@ovar{version}, @ovar{action-if-found},
@ovar{action-if-not-found})
Search for a Python interpreter on the system. This macro takes three
@@ -7688,6 +7708,7 @@ This is the directory where Python extension modules
(shared libraries)
should be installed. An extension module written in C could be declared
as follows to Automake:
address@hidden Keep in sync with primary-prefix-couples-documented-valid.test.
@example
pyexec_LTLIBRARIES = quaternion.la
quaternion_la_SOURCES = quaternion.c support.c support.h
@@ -7884,6 +7905,7 @@ passed to @code{makeinfo} when building @file{.info}
files; and
@samp{$(AM_MAKEINFOHTMLFLAGS)} is used when building @file{.html}
files.
address@hidden Keep in sync with txinfo21.test.
For instance, the following setting can be used to obtain one single
@file{.html} file per manual, without node separators.
@example
@@ -8109,10 +8131,11 @@ Variables using the standard directory prefixes
@samp{bin},
For instance, @code{data_DATA} files are installed by @code{install-data},
while @code{bin_PROGRAMS} files are installed by @code{install-exec}.
-Any variable using a user-defined directory prefix with @samp{exec} in
-the name (e.g., @code{myexecbin_PROGRAMS}) is installed by
address@hidden All other user-defined prefixes are installed by
address@hidden
+Any variable using a user-defined directory prefix with
address@hidden in the name (e.g.,
address@hidden Keep in sync with primary-prefix-couples-documented-valid.test.
address@hidden) is installed by @code{install-exec}. All
+other user-defined prefixes are installed by @code{install-data}.
@node Extending Installation
@section Extending Installation
@@ -8291,14 +8314,19 @@ is run. The default setting is @option{--best}.
@cmindex include
For the most part, the files to distribute are automatically found by
Automake: all source files are automatically included in a distribution,
-as are all @file{Makefile.am}s and @file{Makefile.in}s. Automake also
+as are all @file{Makefile.am} and @file{Makefile.in} files. Automake also
has a built-in list of commonly used files that are automatically
included if they are found in the current directory (either physically,
-or as the target of a @file{Makefile.am} rule). This list is printed by
address@hidden --help}. Also, files that are read by @command{configure}
+or as the target of a @file{Makefile.am} rule); this list is printed by
address@hidden --help}. Note that some files in this list are actually
+distributed only if other certain conditions hold (for example,
address@hidden Keep in sync with autodist-config-headers.test.
+the @file{config.h.top} and @file{config.h.bot} files are automatically
+distributed only if, e.g., @samp{AC_CONFIG_HEADERS([config.h])} is used
+in @file{configure.ac}). Also, files that are read by @command{configure}
(i.e.@: the source files corresponding to the files specified in various
Autoconf macros such as @code{AC_CONFIG_FILES} and siblings) are
-automatically distributed. Files included in @file{Makefile.am}s (using
+automatically distributed. Files included in a @file{Makefile.am} (using
@code{include}) or in @file{configure.ac} (using @code{m4_include}), and
helper scripts installed with @samp{automake --add-missing} are also
distributed.
@@ -8417,11 +8445,29 @@ makes a distribution, then tries to do a @code{VPATH}
build
(@pxref{VPATH Builds}), run the test suite, and finally make another
tarball to ensure the distribution is self-contained.
address@hidden AM_DISTCHECK_CONFIGURE_FLAGS
@vindex DISTCHECK_CONFIGURE_FLAGS
Building the package involves running @samp{./configure}. If you need
to supply additional flags to @command{configure}, define them in the
address@hidden variable, either in your top-level
address@hidden, or on the command line when invoking @command{make}.
address@hidden variable in your top-level
address@hidden The user can still extend or override the flags
+provided there by defining the @code{DISTCHECK_CONFIGURE_FLAGS} variable,
+on the command line when invoking @command{make}.
+
+Still, developers are encouraged to strive to make their code buildable
+without requiring any special configure option; thus, in general, you
+shouldn't define @code{AM_DISTCHECK_CONFIGURE_FLAGS}. However, there
+might be few scenarios in which the use of this variable is justified.
+GNU @command{m4} offers an example. GNU @command{m4} configures by
+default with its experimental and seldom used "changeword" feature
+disabled; so in its case it is useful to have @command{make distcheck}
+run configure with the @option{--with-changeword} option, to ensure that
+the code for changeword support still compiles correctly.
+GNU @command{m4} also employs the @code{AM_DISTCHECK_CONFIGURE_FLAGS}
+variable to stress-test the use of @option{--program-prefix=g}, since at
+one point the @command{m4} build system had a bug where @command{make
+installcheck} was wrongly assuming it could blindly test "@command{m4}",
+rather than the just-installed "@command{gm4}".
@trindex distcheck-hook
If the @code{distcheck-hook} rule is defined in your top-level
@@ -8431,9 +8477,10 @@ is configured and built. Your @code{distcheck-hook} can
do almost
anything, though as always caution is advised. Generally this hook is
used to check for potential distribution errors not caught by the
standard mechanism. Note that @code{distcheck-hook} as well as
address@hidden are not honored in a subpackage
address@hidden, but the @code{DISTCHECK_CONFIGURE_FLAGS} are
-passed down to the @command{configure} script of the subpackage.
address@hidden and @code{DISTCHECK_CONFIGURE_FLAGS}
+are not honored in a subpackage @file{Makefile.am}, but the flags from
address@hidden and @code{DISTCHECK_CONFIGURE_FLAGS}
+are passed down to the @command{configure} script of the subpackage.
@trindex distcleancheck
@vindex DISTCLEANFILES
@@ -8463,6 +8510,7 @@ If you want @code{distcleancheck} to ignore built files
that have not
been cleaned because they are also part of the distribution, add the
following definition instead:
address@hidden Keep in sync with distcleancheck.test.
@example
distcleancheck_listfiles = \
find . -type f -exec sh -c 'test -f $(srcdir)/$$1 || echo $$1' \
@@ -8611,6 +8659,7 @@ set @code{TESTS_ENVIRONMENT} to an invocation of the
shell (e.g.
interpreter. For instance, the following setup may be used to run tests
with Perl:
address@hidden Keep in sync with tests-environment-backcompat.test.
@example
TESTS_ENVIRONMENT = $(PERL) -Mstrict -w
TESTS = foo.pl bar.pl baz.pl
@@ -8625,10 +8674,10 @@ parallel-tests}).
@cindex Tests, expected failure
@cindex Expected test failure
address@hidden XFAIL_TESTS
You may define the variable @code{XFAIL_TESTS} to a list of tests
(usually a subset of @code{TESTS}) that are expected to fail. This will
reverse the result of those tests.
address@hidden XFAIL_TESTS
Automake ensures that each file listed in @code{TESTS} is built before
any tests are run; you can list both source and derived programs (or
@@ -8706,6 +8755,7 @@ this extension to be called with this driver. For all
tests without a
registered extension, the variables @code{LOG_COMPILER},
@code{AM_LOG_FLAGS}, and @code{LOG_FLAGS} may be used. For example,
address@hidden Keep in sync with parallel-tests-log-compiler-example.test.
@example
TESTS = foo.pl bar.py baz
TEST_EXTENSIONS = .pl .py
@@ -8772,6 +8822,21 @@ use a command like this to run only a subset of the
tests:
env TESTS="foo.test bar.test" make -e check
@end example
+Note however that the command above will unconditionally overwrite the
address@hidden file, thus clobbering the recorded results
+of any previous testsuite run. This might be undesirable for packages
+whose testsuite takes long time to execute. Luckily, this problem can
+easily be avoided by overriding also @code{TEST_SUITE_LOG} at runtime;
+for example,
+
address@hidden Keep in sync with parallel-tests-log-override-2.test.
address@hidden
+env TEST_SUITE_LOG=partial.log TESTS="..." make -e check
address@hidden example
+
+will write the result of the partial testsuite runs to the
address@hidden, without touching @file{test-suite.log}.
+
@item
You can set the @code{TEST_LOGS} variable. By default, this variable is
computed at @command{make} run time from the value of @code{TESTS} as
@@ -8782,6 +8847,9 @@ set x subset*.log; shift
env TEST_LOGS="foo.log $*" make -e check
@end example
+The comments made above about @code{TEST_SUITE_LOG} overriding applies
+here too.
+
@item
@vindex RECHECK_LOGS
@cindex lazy test execution
@@ -9052,11 +9120,15 @@ implies options @option{readme-alpha} and
@option{check-news}.
@itemx @address@hidden/ansi2knr}
@cindex Option, @option{ansi2knr}
@opindex ansi2knr
-Turn on the obsolete de-ANSI-fication feature. @xref{ANSI}. If preceded by a
+Turn on the deprecated de-ANSI-fication feature (@pxref{ANSI}). Note
+that that feature and this option @emph{will be removed} in the next
+major Automake release.
+
+If preceded by a
path, the generated @file{Makefile.in} will look in the specified
directory to find the @file{ansi2knr} program. The path should be a
relative path to another directory in the same distribution (Automake
-currently does not check this).
+does not check this).
@item @option{check-news}
@cindex Option, @option{check-news}
@@ -9209,90 +9281,18 @@ letter; it should be omitted for non-alpha releases.
@cindex Option, @option{silent-rules}
@opindex silent-rules
Enable less verbose build rules. This can be used to let build rules
-output a status line of the form
-
+output status lines of the form:
@example
- GEN @var{output-file}
+GEN @var{output-file}
+ CC @var{object-file}
@end example
-
@noindent
instead of printing the command that will be executed to update
address@hidden It can also silence @command{libtool} output.
-
-To enable less verbose build rules, both the developer and the user
-of the package have to take a number of steps. The developer needs
-to do either of the following:
-
address@hidden @bullet
address@hidden
-Add the @option{silent-rules} option as argument to @code{AM_INIT_AUTOMAKE}.
address@hidden
-Call the @code{AM_SILENT_RULES} macro from within the @file{configure.ac}
-file.
address@hidden itemize
-
-It is not possible to instead specify @option{silent-rules} in a
address@hidden file.
-
address@hidden default verbosity for silent-rules
-If the developer has done either of the above, then the user of the
-package may influence the verbosity at @command{configure} run time as
-well as at @command{make} run time:
-
address@hidden @bullet
address@hidden
address@hidden --enable-silent-rules
address@hidden --disable-silent-rules
-Passing @option{--enable-silent-rules} to @command{configure} will cause
-build rules to be less verbose; the option @option{--disable-silent-rules}
-is the default and will cause normal verbose output.
address@hidden
address@hidden @code{V}
-At @command{make} run time, the default chosen at @command{configure}
-time may be overridden: @code{make V=1} will produce verbose output,
address@hidden V=0} less verbose output.
address@hidden itemize
-
-For portability to different @command{make} implementations, package authors
-are advised to not set the variable @code{V} inside the @file{Makefile.am}
-file, to allow the user to override the value for subdirectories as well.
-
-The current implementation of this feature relies on a non-POSIX, but in
-practice rather widely supported @file{Makefile} construct of nested
-variable expansion @samp{$(@var{var1}$(V))}. Do not use the
address@hidden option if your package needs to build with
address@hidden implementations that do not support it. The
address@hidden option turns off warnings about recursive variable
-expansion, which are in turn enabled by @option{-Wportability}
-(@pxref{Invoking Automake}).
-
address@hidden @code{AM_V_GEN}
address@hidden @code{AM_V_at}
address@hidden @code{AM_DEFAULT_VERBOSITY}
-To extend the silent mode to your own rules, you have two choices:
-
address@hidden @bullet
address@hidden
-You can use the predefined variable @code{AM_V_GEN} as a prefix to
-commands that should output a status line in silent mode, and
address@hidden as a prefix to commands that should not output anything
-in silent mode. When output is to be verbose, both of these variables
-will expand to the empty string.
address@hidden
-You can add your own variables, so strings of your own choice are shown.
-The following snippet shows how you would define your own equivalent of
address@hidden:
-
address@hidden
-pkg_verbose = $(pkg_verbose_$(V))
-pkg_verbose_ = $(pkg_verbose_$(AM_DEFAULT_VERBOSITY))
-pkg_verbose_0 = @@echo GEN $@@;
-
-foo: foo.in
- $(pkg_verbose)cp $(srcdir)/foo.in $@@
address@hidden example
address@hidden itemize
address@hidden or to compile @var{object-file}. It can also
+silence @command{libtool} output.
+For more information about how to use, enable, or disable silent
+rules, @pxref{Automake silent-rules Option}.
@item @option{std-options}
@cindex Options, @option{std-options}
@@ -9533,6 +9533,7 @@ For instance, the following definition prevents Automake
from misinterpreting
the @samp{.idlC.cpp:} rule as an attempt to transform @file{.idlC} files into
@file{.cpp} files.
address@hidden Keep in sync with suffix7.test.
@example
SUFFIXES = .idl C.cpp
.idlC.cpp:
@@ -9767,6 +9768,293 @@ Subdirectories}, @pxref{Conditional Sources},
@pxref{Conditional
Programs}, @pxref{Conditional Libtool Libraries}, @pxref{Conditional
Libtool Sources}).
address@hidden Silencing Make
address@hidden Silencing @command{make}
+
address@hidden Silent @command{make}
address@hidden Silencing @command{make}
address@hidden Silent rules
address@hidden Silent @command{make} rules
+
address@hidden
+* Make verbosity:: Make is verbose by default
+* Tricks For Silencing Make:: Standard and generic ways to silence make
+* Automake silent-rules Option:: How Automake can help in silencing make
address@hidden menu
+
address@hidden Make verbosity
address@hidden Make is verbose by default
+
+Normally, when executing the set of rules associated with a target,
address@hidden prints each rule before it is executed. This behaviour,
+while having been in place for a long time, and being even mandated by
+the POSIX standard, starkly violates the ``silence is golden'' UNIX
address@hidden also
address@hidden://catb.org/~esr/writings/taoup/html/ch11s09.html}.}:
+
address@hidden
+When a program has nothing interesting or surprising to say, it should
+say nothing. Well-behaved Unix programs do their jobs unobtrusively,
+with a minimum of fuss and bother. Silence is golden.
address@hidden quotation
+
+In fact, while such verbosity of @command{make} can theoretically be
+useful to track bugs and understand reasons of failures right away, it
+can also hide warning and error messages from @command{make}-invoked
+tools, drowning them in a flood of uninteresting and seldom useful
+messages, and thus allowing them to go easily undetected.
+
+This problem can be very annoying, especially for developers, who usually
+know quite well what's going on behind the scenes, and for whom the
+verbose output from @command{make} ends up being mostly noise that hampers
+the easy detection of potentially important warning messages.
+
address@hidden Tricks For Silencing Make
address@hidden Standard and generic ways to silence make
+
+Here we describe some common idioms/tricks to obtain a quieter make
+output, with their relative advantages and drawbacks. In the next
+section (@ref{Automake silent-rules Option}) we'll see how Automake
+can help in this respect.
+
address@hidden @bullet
+
address@hidden @command{make -s}
+
+This simply causes @command{make} not to print @emph{any} rule before
+executing it.
+
+The @option{-s} flag is mandated by POSIX, universally supported, and
+its purpose and function are easy to understand.
+
+But it also has its serious limitations too. First of all, it embodies
+an ``all or nothing'' strategy, i.e., either everything is silenced, or
+nothing is; this lack of granularity can sometimes be a fatal flaw.
+Moreover, when the @option{-s} flag is used, the @command{make} output
+might turn out to be too much terse; in case of errors, the user won't
+be able to easily see what rule or command have caused them, or even,
+in case of tools with poor error reporting, what the errors were!
+
address@hidden @command{make >/dev/null || make}
+
+Apparently, this perfectly obeys the ``silence is golden'' rule: warnings
+from stderr are passed through, output reporting is done only in case of
+error, and in that case it should provide a verbose-enough report to allow
+an easy determination of the error location and causes.
+
+However, calling @command{make} two times in a row might hide errors
+(especially intermittent ones), or subtly change the expected semantic
+of the @command{make} calls --- things these which can clearly make
+debugging and error assessment very difficult.
+
address@hidden @command{make --no-print-directory}
+
+This is GNU @command{make} specific. When called with the
address@hidden option, GNU @command{make} will disable
+printing of the working directory by invoked address@hidden (the
+well-known address@hidden/Leaving directory ...}'' messages). This helps
+to decrease the verbosity of the output, but experience has shown that
+it can also often render debugging considerably harder in projects using
+deeply-nested @command{make} recursion.
+
+As an aside, notice that the @option{--no-print-directory} option is
+automatically activated if the @option{-s} flag is used.
+
address@hidden TODO: Other tricks?
address@hidden TODO: Maybe speak about the @code{.SILENT} target?
address@hidden TODO: - Pros: More granularity on what to silence.
address@hidden TODO: - Cons: No easy way to temporarily override.
+
address@hidden itemize
+
address@hidden Automake silent-rules Option
address@hidden How Automake can help in silencing make
+
+The tricks and idioms for silencing @command{make} described in the
+previous section can be useful from time to time, but we've seen that
+they all have their serious drawbacks and limitations. That's why
+automake provides support for a more advanced and flexible way of
+obtaining quieter output from @command{make}: the @option{silent-rules}
+mode.
+
address@hidden TODO: Maybe describe in brief the precedent set by the build
system
address@hidden of the Linux Kernel, from which Automake took inspiration ...
Links?
+
+To give the gist of what @option{silent-rules} can do, here is a simple
+comparison between a typical @command{make} output (where silent rules
+are disabled) and one with silent rules enabled:
+
address@hidden
+% @kbd{cat Makefile.am}
+bin_PROGRAMS = foo
+foo_SOURCES = main.c func.c
+% @kbd{cat main.c}
+int main (void) @{ return func (); @} /* func used undeclared */
+% @kbd{cat func.c}
+int func (void) @{ int i; return i; @} /* i used uninitialized */
+
address@hidden make output is by default very verbose. This causes warnings
+from the compiler to be somewhat hidden, and not immediate to spot.}
+% @kbd{make CFLAGS=-Wall}
+gcc -DPACKAGE_NAME=\"foo\" -DPACKAGE_TARNAME=\"foo\" ...
+-DPACKAGE_STRING=\"foo\ 1.0\" -DPACKAGE_BUGREPORT=\"\" ...
+-DPACKAGE=\"foo\" -DVERSION=\"1.0\" -I. -Wall -MT main.o
+-MD -MP -MF .deps/main.Tpo -c -o main.o main.c
+main.c: In function âmainâ:
+main.c:3:3: warning: implicit declaration of function âfuncâ
+mv -f .deps/main.Tpo .deps/main.Po
+gcc -DPACKAGE_NAME=\"foo\" -DPACKAGE_TARNAME=\"foo\" ...
+-DPACKAGE_STRING=\"foo\ 1.0\" -DPACKAGE_BUGREPORT=\"\" ...
+-DPACKAGE=\"foo\" -DVERSION=\"1.0\" -I. -Wall -MT func.o
+-MD -MP -MF .deps/func.Tpo -c -o func.o func.c
+func.c: In function âfuncâ:
+func.c:4:3: warning: âiâ used uninitialized in this function
+mv -f .deps/func.Tpo .deps/func.Po
+gcc -Wall -o foo main.o func.o
+
address@hidden up, so that we we can rebuild everything from scratch.}
+% @kbd{make clean}
+test -z "foo" || rm -f foo
+rm -f *.o
+
address@hidden rules enabled: the output is minimal but informative. In
+particular, the warnings from the compiler stick out very clearly.}
+% @kbd{make V=0 CFLAGS=-Wall}
+ CC main.o
+main.c: In function âmainâ:
+main.c:3:3: warning: implicit declaration of function âfuncâ
+ CC func.o
+func.c: In function âfuncâ:
+func.c:4:3: warning: âiâ used uninitialized in this function
+ CCLD foo
address@hidden example
+
address@hidden silent-rules and libtool
+Also, in projects using @command{libtool}, the use of silent rules can
+automatically enable the @command{libtool}'s @option{--silent} option:
+
address@hidden
+% @kbd{cat Makefile.am}
+lib_LTLIBRARIES = libx.la
+
+% @kbd{make # Both make and libtool are verbose by default.}
+...
+libtool: compile: gcc -DPACKAGE_NAME=\"foo\" ... -DLT_OBJDIR=\".libs/\"
+ -I. -g -O2 -MT libx.lo -MD -MP -MF .deps/libx.Tpo -c libx.c -fPIC
+ -DPIC -o .libs/libx.o
+mv -f .deps/libx.Tpo .deps/libx.Plo
+/bin/sh ./libtool --tag=CC --mode=link gcc -g -O2 -o libx.la -rpath
+ /usr/local/lib libx.lo
+libtool: link: gcc -shared .libs/libx.o -Wl,-soname -Wl,libx.so.0
+ -o .libs/libx.so.0.0.0
+libtool: link: cd .libs && rm -f libx.so && ln -s libx.so.0.0.0 libx.so
+...
+
+% @kbd{make V=0}
+ CC libx.lo
+ CCLD libx.la
address@hidden example
+
+Let's now see how the @option{silent-rules} mode interfaces with the
+package developer and the package user.
+
+To enable the use of @option{silent-rules} in his package, a developer
+needs to do either of the following:
+
address@hidden @bullet
address@hidden
+Add the @option{silent-rules} option as argument to @code{AM_INIT_AUTOMAKE}.
address@hidden
+Call the @code{AM_SILENT_RULES} macro from within the @file{configure.ac}
+file.
address@hidden itemize
+
+It is not possible to instead specify @option{silent-rules} in a
address@hidden file.
+
+If the developer has done either of the above, then the user of the
+package may influence the verbosity at @command{configure} run time as
+well as at @command{make} run time:
+
address@hidden @bullet
address@hidden
address@hidden --enable-silent-rules
address@hidden --disable-silent-rules
+Passing @option{--enable-silent-rules} to @command{configure} will cause
+build rules to be less verbose; the option @option{--disable-silent-rules}
+will cause normal verbose output.
address@hidden
address@hidden @code{V}
+At @command{make} run time, the default chosen at @command{configure}
+time may be overridden: @code{make V=1} will produce verbose output,
address@hidden V=0} less verbose output.
address@hidden itemize
+
address@hidden default verbosity for silent-rules
+Note that silent rules are @emph{disabled} by default; the user must
+enable them explicitly at either @command{configure} run time or at
address@hidden run time. We think that this is a good policy, since
+it provides the casual user with enough information to prepare a good
+bug report in case anything breaks.
+
+Still, notwithstanding the rationales above, a developer who wants to
+make silent rules enabled by default in his own package can do so by
+adding a @samp{yes} argument to the @code{AM_SILENT_RULES} call in
address@hidden We advise against this approach, though.
+
address@hidden Keep in sync with silent-configsite.test
+Users who prefer to have silent rules enabled by default can edit their
address@hidden file to make the variable @code{enable_silent_rules}
+default to @samp{yes}. This should still allow disabling silent rules
+at @command{configure} time and at @command{make} time.
+
address@hidden FIXME: there's really a need to specify this explicitly?
+For portability to different @command{make} implementations, package authors
+are advised to not set the variable @code{V} inside the @file{Makefile.am}
+file, to allow the user to override the value for subdirectories as well.
+
+The current implementation of this feature relies on a non-POSIX, but in
+practice rather widely supported @file{Makefile} construct of nested
+variable expansion @samp{$(@var{var1}$(V))}. Do not use the
address@hidden option if your package needs to build with
address@hidden implementations that do not support it. The
address@hidden option turns off warnings about recursive variable
+expansion, which are in turn enabled by @option{-Wportability}
+(@pxref{Invoking Automake}).
+
address@hidden @code{AM_V_GEN}
address@hidden @code{AM_V_at}
address@hidden @code{AM_DEFAULT_VERBOSITY}
+To extend the silent mode to your own rules, you have two choices:
+
address@hidden @bullet
address@hidden
+You can use the predefined variable @code{AM_V_GEN} as a prefix to
+commands that should output a status line in silent mode, and
address@hidden as a prefix to commands that should not output anything
+in silent mode. When output is to be verbose, both of these variables
+will expand to the empty string.
address@hidden
+You can add your own variables, so strings of your own choice are shown.
+The following snippet shows how you would define your own equivalent of
address@hidden:
+
address@hidden
+pkg_verbose = $(pkg_verbose_$(V))
+pkg_verbose_ = $(pkg_verbose_$(AM_DEFAULT_VERBOSITY))
+pkg_verbose_0 = @@echo PKG-GEN $@@;
+
+foo: foo.in
+ $(pkg_verbose)cp $(srcdir)/foo.in $@@
address@hidden example
+
address@hidden itemize
+
+As a final note, observe that, even when silent rules are enabled,
+the @option{--no-print-directory} option is still required with GNU
address@hidden if the address@hidden/Leaving directory ...}'' messages
+are to be disabled.
+
@node Gnits
@chapter The effect of @option{--gnu} and @option{--gnits}
@@ -10075,6 +10363,7 @@ Checks, autoconf, The Autoconf Manual}) and use
@samp{$(LN_S)} in
For instance, here is how you could install a versioned copy of a
program using @samp{$(LN_S)}:
address@hidden Keep in sync with insthook.test
@example
install-exec-hook:
cd $(DESTDIR)$(bindir) && \
@@ -10089,7 +10378,9 @@ destination directory in order to create relative links.
When writing @code{install-exec-hook} or @code{install-data-hook},
please bear in mind that the exec/data distinction is based on the
installation directory, not on the primary used (@pxref{The Two Parts of
-Install}). So a @code{foo_SCRIPTS} will be installed by
+Install}).
address@hidden Keep in sync with primary-prefix-couples-documented-valid.test.
+So a @code{foo_SCRIPTS} will be installed by
@code{install-data}, and a @code{barexec_SCRIPTS} will be installed by
@code{install-exec}. You should define your hooks consequently.
diff --git a/lib/Automake/Makefile.in b/lib/Automake/Makefile.in
index 5d73a3c..1602023 100644
--- a/lib/Automake/Makefile.in
+++ b/lib/Automake/Makefile.in
@@ -181,6 +181,9 @@ abs_top_builddir = @abs_top_builddir@
abs_top_srcdir = @abs_top_srcdir@
am_AUTOCONF = @am_AUTOCONF@
am_AUTOHEADER = @am_AUTOHEADER@
+am_AUTOM4TE = @am_AUTOM4TE@
+am_AUTORECONF = @am_AUTORECONF@
+am_AUTOUPDATE = @am_AUTOUPDATE@
am__leading_dot = @am__leading_dot@
am__tar = @am__tar@
am__untar = @am__untar@
diff --git a/lib/Automake/Options.pm b/lib/Automake/Options.pm
index 9543aa5..b7ff3d1 100644
--- a/lib/Automake/Options.pm
+++ b/lib/Automake/Options.pm
@@ -252,6 +252,10 @@ sub _process_option_list (\%$@)
}
elsif (/^(.*\/)?ansi2knr$/)
{
+ # This feature is deprecated, will be removed in the next
+ # Automake major release.
+ msg 'obsolete', $where,
+ "automatic de-ANSI-fication support is deprecated\n";
# An option like "../lib/ansi2knr" is allowed. With no
# path prefix, we assume the required programs are in this
# directory. We save the actual option for later.
diff --git a/lib/Automake/tests/Makefile.in b/lib/Automake/tests/Makefile.in
index 79af81b..3d1b299 100644
--- a/lib/Automake/tests/Makefile.in
+++ b/lib/Automake/tests/Makefile.in
@@ -105,15 +105,21 @@ am__base_list = \
am__rst_title = sed 's/.*/ & /;h;s/./=/g;p;x;p;g;p;s/.*//'
am__rst_section = sed 'p;s/./=/g;p;g'
# Put stdin (possibly several lines separated by ". ") in a box.
-am__text_box = $(AWK) '{ \
- n = split($$0, lines, "\\. "); max = 0; \
- for (i = 1; i <= n; ++i) \
- if (max < length(lines[i])) \
- max = length(lines[i]); \
- for (i = 0; i < max; ++i) line = line "="; \
- print line; \
- for (i = 1; i <= n; ++i) if (lines[i]) print lines[i];\
- print line; \
+# Prefix each line by 'col' and terminate each with 'std', for coloring.
+# Multi line coloring is problematic with "less -R", so we really need
+# to color each line individually.
+am__text_box = $(AWK) '{ \
+ n = split($$0, lines, "\\. "); max = 0; \
+ for (i = 1; i <= n; ++i) \
+ if (max < length(lines[i])) \
+ max = length(lines[i]); \
+ for (i = 0; i < max; ++i) \
+ line = line "="; \
+ print col line std; \
+ for (i = 1; i <= n; ++i) \
+ if (lines[i]) \
+ print col lines[i] std; \
+ print col line std; \
}'
# Solaris 10 'make', and several other traditional 'make' implementations,
# pass "-e" to $(SHELL), and POSIX 2008 even requires this. Work around it
@@ -226,6 +232,9 @@ abs_top_builddir = @abs_top_builddir@
abs_top_srcdir = @abs_top_srcdir@
am_AUTOCONF = @am_AUTOCONF@
am_AUTOHEADER = @am_AUTOHEADER@
+am_AUTOM4TE = @am_AUTOM4TE@
+am_AUTORECONF = @am_AUTORECONF@
+am_AUTOUPDATE = @am_AUTOUPDATE@
am__leading_dot = @am__leading_dot@
am__tar = @am__tar@
am__untar = @am__untar@
@@ -391,12 +400,11 @@ $(TEST_SUITE_LOG): $(TEST_LOGS)
test x"$$VERBOSE" = x || $$exit || cat $(TEST_SUITE_LOG); \
$(am__tty_colors); \
if $$exit; then \
- echo $(ECHO_N) "$$grn$(ECHO_C)"; \
+ col="$$grn"; \
else \
- echo $(ECHO_N) "$$red$(ECHO_C)"; \
+ col="$$red"; \
fi; \
- echo "$$msg" | $(am__text_box); \
- echo $(ECHO_N) "$$std$(ECHO_C)"; \
+ echo "$$msg" | $(am__text_box) "col=$$col" "std=$$std"; \
$$exit
# Run all the tests.
diff --git a/lib/INSTALL b/lib/INSTALL
index 81fd332..a1e89e1 100644
--- a/lib/INSTALL
+++ b/lib/INSTALL
@@ -1,8 +1,8 @@
Installation Instructions
*************************
-Copyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005,
-2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc.
+Copyright (C) 1994-1996, 1999-2002, 2004-2011 Free Software Foundation,
+Inc.
Copying and distribution of this file, with or without modification,
are permitted in any medium without royalty provided the copyright
@@ -226,6 +226,11 @@ order to use an ANSI C compiler:
and if that doesn't work, install pre-built binaries of GCC for HP-UX.
+ HP-UX `make' updates targets which have the same time stamps as
+their prerequisites, which makes it generally unusable when shipped
+generated files such as `configure' are involved. Use GNU `make'
+instead.
+
On OSF/1 a.k.a. Tru64, some versions of the default C compiler cannot
parse its `<wchar.h>' header file. The option `-nodtk' can be used as
a workaround. If GNU CC is not installed, it is therefore recommended
diff --git a/lib/Makefile.in b/lib/Makefile.in
index 04b5d0e..a689f03 100644
--- a/lib/Makefile.in
+++ b/lib/Makefile.in
@@ -183,6 +183,9 @@ abs_top_builddir = @abs_top_builddir@
abs_top_srcdir = @abs_top_srcdir@
am_AUTOCONF = @am_AUTOCONF@
am_AUTOHEADER = @am_AUTOHEADER@
+am_AUTOM4TE = @am_AUTOM4TE@
+am_AUTORECONF = @am_AUTORECONF@
+am_AUTOUPDATE = @am_AUTOUPDATE@
am__leading_dot = @am__leading_dot@
am__tar = @am__tar@
am__untar = @am__untar@
diff --git a/lib/am/Makefile.in b/lib/am/Makefile.in
index b3f5741..df9e3ba 100644
--- a/lib/am/Makefile.in
+++ b/lib/am/Makefile.in
@@ -141,6 +141,9 @@ abs_top_builddir = @abs_top_builddir@
abs_top_srcdir = @abs_top_srcdir@
am_AUTOCONF = @am_AUTOCONF@
am_AUTOHEADER = @am_AUTOHEADER@
+am_AUTOM4TE = @am_AUTOM4TE@
+am_AUTORECONF = @am_AUTORECONF@
+am_AUTOUPDATE = @am_AUTOUPDATE@
am__leading_dot = @am__leading_dot@
am__tar = @am__tar@
am__untar = @am__untar@
diff --git a/lib/am/check.am b/lib/am/check.am
index 4d10ce9..0b54312 100644
--- a/lib/am/check.am
+++ b/lib/am/check.am
@@ -75,15 +75,21 @@ am__rst_title = sed 's/.*/ &
/;h;s/./=/g;p;x;p;g;p;s/.*//'
am__rst_section = sed 'p;s/./=/g;p;g'
# Put stdin (possibly several lines separated by ". ") in a box.
-am__text_box = $(AWK) '{ \
- n = split($$0, lines, "\\. "); max = 0; \
- for (i = 1; i <= n; ++i) \
- if (max < length(lines[i])) \
- max = length(lines[i]); \
- for (i = 0; i < max; ++i) line = line "="; \
- print line; \
- for (i = 1; i <= n; ++i) if (lines[i]) print lines[i];\
- print line; \
+# Prefix each line by 'col' and terminate each with 'std', for coloring.
+# Multi line coloring is problematic with "less -R", so we really need
+# to color each line individually.
+am__text_box = $(AWK) '{ \
+ n = split($$0, lines, "\\. "); max = 0; \
+ for (i = 1; i <= n; ++i) \
+ if (max < length(lines[i])) \
+ max = length(lines[i]); \
+ for (i = 0; i < max; ++i) \
+ line = line "="; \
+ print col line std; \
+ for (i = 1; i <= n; ++i) \
+ if (lines[i]) \
+ print col lines[i] std; \
+ print col line std; \
}'
# Solaris 10 'make', and several other traditional 'make' implementations,
@@ -213,12 +219,11 @@ $(TEST_SUITE_LOG): $(TEST_LOGS)
test x"$$VERBOSE" = x || $$exit || cat $(TEST_SUITE_LOG); \
$(am__tty_colors); \
if $$exit; then \
- echo $(ECHO_N) "$$grn$(ECHO_C)"; \
+ col="$$grn"; \
else \
- echo $(ECHO_N) "$$red$(ECHO_C)"; \
+ col="$$red"; \
fi; \
- echo "$$msg" | $(am__text_box); \
- echo $(ECHO_N) "$$std$(ECHO_C)"; \
+ echo "$$msg" | $(am__text_box) "col=$$col" "std=$$std"; \
$$exit
RECHECK_LOGS = $(TEST_LOGS)
@@ -398,14 +403,17 @@ check-TESTS: $(TESTS)
fi; \
dashes=`echo "$$dashes" | sed s/./=/g`; \
if test "$$failed" -eq 0; then \
- echo "$$grn$$dashes"; \
+ col="$$grn"; \
else \
- echo "$$red$$dashes"; \
+ col="$$red"; \
fi; \
- echo "$$banner"; \
- test -z "$$skipped" || echo "$$skipped"; \
- test -z "$$report" || echo "$$report"; \
- echo "$$dashes$$std"; \
+## Multi line coloring is problematic with "less -R", so we really need
+## to color each line individually.
+ echo "$${col}$$dashes$${std}"; \
+ echo "$${col}$$banner$${std}"; \
+ test -z "$$skipped" || echo "$${col}$$skipped$${std}"; \
+ test -z "$$report" || echo "$${col}$$report$${std}"; \
+ echo "$${col}$$dashes$${std}"; \
test "$$failed" -eq 0; \
else :; fi
diff --git a/lib/am/configure.am b/lib/am/configure.am
index e9299d6..594ec67 100644
--- a/lib/am/configure.am
+++ b/lib/am/configure.am
@@ -17,12 +17,13 @@
## This dummy rule is called from subdirectories whenever one of the
-## top-level Makefile's dependencies must be updated. It does not
-## need to depend on %MAKEFILE% because GNU make will always make sure
-## %MAKEFILE% is updated before considering the am--refresh target.
+## top-level Makefile's dependencies must be updated. It does depend
+## on %MAKEFILE% for the benefit of non-GNU make implementations (GNU
+## make will always make sure %MAKEFILE% is updated before considering
+## the am--refresh target anyway).
if %?TOPDIR_P%
.PHONY: am--refresh
-am--refresh:
+am--refresh: %MAKEFILE%
@:
endif %?TOPDIR_P%
diff --git a/lib/am/distdir.am b/lib/am/distdir.am
index e0f3bce..c2dd7c5 100644
--- a/lib/am/distdir.am
+++ b/lib/am/distdir.am
@@ -468,7 +468,9 @@ distcheck: dist
&& ../configure --srcdir=.. --prefix="$$dc_install_base" \
?GETTEXT? --with-included-gettext \
## Additional flags for configure. Keep this last in the configure
-## invocation so the user can override previous options.
+## invocation so the developer and user can override previous options,
+## and let the user's flags take precedence over the developer's ones.
+ $(AM_DISTCHECK_CONFIGURE_FLAGS) \
$(DISTCHECK_CONFIGURE_FLAGS) \
&& $(MAKE) $(AM_MAKEFLAGS) \
&& $(MAKE) $(AM_MAKEFLAGS) dvi \
diff --git a/lib/config-ml.in b/lib/config-ml.in
index 2dd0d51..1198346 100644
--- a/lib/config-ml.in
+++ b/lib/config-ml.in
@@ -2,7 +2,7 @@
# wanting multilib support.
#
# Copyright (C) 1995, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
-# 2005, 2006, 2007, 2008, 2010 Free Software Foundation, Inc.
+# 2005, 2006, 2007, 2008, 2010, 2011 Free Software Foundation, Inc.
#
# This file is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -224,19 +224,6 @@ done
# $host here, not $target.
case "${host}" in
-arc-*-elf*)
- if [ x$enable_biendian != xyes ]
- then
- old_multidirs=${multidirs}
- multidirs=""
- for x in ${old_multidirs}; do
- case "${x}" in
- *be*) : ;;
- *) multidirs="${multidirs} ${x}" ;;
- esac
- done
- fi
- ;;
arm-*-*)
if [ x"$enable_fpu" = xno ]
then
diff --git a/lib/config.guess b/lib/config.guess
index 4c8f032..b02565c 100755
--- a/lib/config.guess
+++ b/lib/config.guess
@@ -1,10 +1,10 @@
#! /bin/sh
# Attempt to guess a canonical system name.
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
-# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010
-# Free Software Foundation, Inc.
+# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010,
+# 2011 Free Software Foundation, Inc.
-timestamp='2010-09-24'
+timestamp='2011-06-03'
# This file is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by
@@ -57,7 +57,7 @@ GNU config.guess ($timestamp)
Originally written by Per Bothner.
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free
+2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free
Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
@@ -92,7 +92,7 @@ if test $# != 0; then
exit 1
fi
-trap 'exit 1' HUP INT TERM
+trap 'exit 1' 1 2 15
# CC_FOR_BUILD -- compiler used by this script. Note that the use of a
# compiler to aid in system detection is discouraged as it requires
@@ -106,7 +106,7 @@ trap 'exit 1' HUP INT TERM
set_cc_for_build='
trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) &&
exit \$exitcode" 0 ;
-trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" HUP INT
PIPE TERM ;
+trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15
;
: ${TMPDIR=/tmp} ;
{ tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n
"$tmp" && test -d "$tmp" ; } ||
{ test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp)
; } ||
@@ -181,7 +181,7 @@ case
"${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
fi
;;
*)
- os=netbsd
+ os=netbsd
;;
esac
# The OS release
@@ -224,7 +224,7 @@ case
"${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'`
;;
*5.*)
- UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'`
+ UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'`
;;
esac
# According to Compaq, /usr/sbin/psrinfo has been available on
@@ -270,7 +270,10 @@ case
"${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
# A Xn.n version is an unreleased experimental baselevel.
# 1.2 uses "1.2" for uname -r.
echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e
's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
- exit ;;
+ # Reset EXIT trap before exiting to avoid spurious non-zero exit code.
+ exitcode=$?
+ trap '' 0
+ exit $exitcode ;;
Alpha\ *:Windows_NT*:*)
# How do we know it's Interix rather than the generic POSIX subsystem?
# Should we change UNAME_MACHINE based on the output of uname instead
@@ -296,7 +299,7 @@ case
"${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
echo s390-ibm-zvmoe
exit ;;
*:OS400:*:*)
- echo powerpc-ibm-os400
+ echo powerpc-ibm-os400
exit ;;
arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*)
echo arm-acorn-riscix${UNAME_RELEASE}
@@ -395,23 +398,23 @@ case
"${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
# MiNT. But MiNT is downward compatible to TOS, so this should
# be no problem.
atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*)
- echo m68k-atari-mint${UNAME_RELEASE}
+ echo m68k-atari-mint${UNAME_RELEASE}
exit ;;
atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*)
echo m68k-atari-mint${UNAME_RELEASE}
- exit ;;
+ exit ;;
*falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*)
- echo m68k-atari-mint${UNAME_RELEASE}
+ echo m68k-atari-mint${UNAME_RELEASE}
exit ;;
milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*)
- echo m68k-milan-mint${UNAME_RELEASE}
- exit ;;
+ echo m68k-milan-mint${UNAME_RELEASE}
+ exit ;;
hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*)
- echo m68k-hades-mint${UNAME_RELEASE}
- exit ;;
+ echo m68k-hades-mint${UNAME_RELEASE}
+ exit ;;
*:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*)
- echo m68k-unknown-mint${UNAME_RELEASE}
- exit ;;
+ echo m68k-unknown-mint${UNAME_RELEASE}
+ exit ;;
m68k:machten:*:*)
echo m68k-apple-machten${UNAME_RELEASE}
exit ;;
@@ -481,8 +484,8 @@ EOF
echo m88k-motorola-sysv3
exit ;;
AViiON:dgux:*:*)
- # DG/UX returns AViiON for all architectures
- UNAME_PROCESSOR=`/usr/bin/uname -p`
+ # DG/UX returns AViiON for all architectures
+ UNAME_PROCESSOR=`/usr/bin/uname -p`
if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ]
then
if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \
@@ -495,7 +498,7 @@ EOF
else
echo i586-dg-dgux${UNAME_RELEASE}
fi
- exit ;;
+ exit ;;
M88*:DolphinOS:*:*) # DolphinOS (SVR3)
echo m88k-dolphin-sysv3
exit ;;
@@ -595,52 +598,52 @@ EOF
9000/[678][0-9][0-9])
if [ -x /usr/bin/getconf ]; then
sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null`
- sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS
2>/dev/null`
- case "${sc_cpu_version}" in
- 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0
- 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1
- 532) # CPU_PA_RISC2_0
- case "${sc_kernel_bits}" in
- 32) HP_ARCH="hppa2.0n" ;;
- 64) HP_ARCH="hppa2.0w" ;;
+ sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null`
+ case "${sc_cpu_version}" in
+ 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0
+ 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1
+ 532) # CPU_PA_RISC2_0
+ case "${sc_kernel_bits}" in
+ 32) HP_ARCH="hppa2.0n" ;;
+ 64) HP_ARCH="hppa2.0w" ;;
'') HP_ARCH="hppa2.0" ;; # HP-UX 10.20
- esac ;;
- esac
+ esac ;;
+ esac
fi
if [ "${HP_ARCH}" = "" ]; then
eval $set_cc_for_build
- sed 's/^ //' << EOF >$dummy.c
+ sed 's/^ //' << EOF >$dummy.c
- #define _HPUX_SOURCE
- #include <stdlib.h>
- #include <unistd.h>
+ #define _HPUX_SOURCE
+ #include <stdlib.h>
+ #include <unistd.h>
- int main ()
- {
- #if defined(_SC_KERNEL_BITS)
- long bits = sysconf(_SC_KERNEL_BITS);
- #endif
- long cpu = sysconf (_SC_CPU_VERSION);
+ int main ()
+ {
+ #if defined(_SC_KERNEL_BITS)
+ long bits = sysconf(_SC_KERNEL_BITS);
+ #endif
+ long cpu = sysconf (_SC_CPU_VERSION);
- switch (cpu)
- {
- case CPU_PA_RISC1_0: puts ("hppa1.0"); break;
- case CPU_PA_RISC1_1: puts ("hppa1.1"); break;
- case CPU_PA_RISC2_0:
- #if defined(_SC_KERNEL_BITS)
- switch (bits)
- {
- case 64: puts ("hppa2.0w"); break;
- case 32: puts ("hppa2.0n"); break;
- default: puts ("hppa2.0"); break;
- } break;
- #else /* !defined(_SC_KERNEL_BITS) */
- puts ("hppa2.0"); break;
- #endif
- default: puts ("hppa1.0"); break;
- }
- exit (0);
- }
+ switch (cpu)
+ {
+ case CPU_PA_RISC1_0: puts ("hppa1.0"); break;
+ case CPU_PA_RISC1_1: puts ("hppa1.1"); break;
+ case CPU_PA_RISC2_0:
+ #if defined(_SC_KERNEL_BITS)
+ switch (bits)
+ {
+ case 64: puts ("hppa2.0w"); break;
+ case 32: puts ("hppa2.0n"); break;
+ default: puts ("hppa2.0"); break;
+ } break;
+ #else /* !defined(_SC_KERNEL_BITS) */
+ puts ("hppa2.0"); break;
+ #endif
+ default: puts ("hppa1.0"); break;
+ }
+ exit (0);
+ }
EOF
(CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) &&
HP_ARCH=`$dummy`
test -z "$HP_ARCH" && HP_ARCH=hppa
@@ -731,22 +734,22 @@ EOF
exit ;;
C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*)
echo c1-convex-bsd
- exit ;;
+ exit ;;
C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*)
if getsysinfo -f scalar_acc
then echo c32-convex-bsd
else echo c2-convex-bsd
fi
- exit ;;
+ exit ;;
C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*)
echo c34-convex-bsd
- exit ;;
+ exit ;;
C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*)
echo c38-convex-bsd
- exit ;;
+ exit ;;
C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*)
echo c4-convex-bsd
- exit ;;
+ exit ;;
CRAY*Y-MP:*:*:*)
echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
exit ;;
@@ -770,14 +773,14 @@ EOF
exit ;;
F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*)
FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'
'abcdefghijklmnopqrstuvwxyz'`
- FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'
'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
- FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'`
- echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
- exit ;;
+ FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'
'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
+ FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'`
+ echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
+ exit ;;
5000:UNIX_System_V:4.*:*)
- FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'
'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
- FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'
'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'`
- echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
+ FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'
'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
+ FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'
'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'`
+ echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
exit ;;
i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*)
echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE}
@@ -805,14 +808,14 @@ EOF
echo ${UNAME_MACHINE}-pc-mingw32
exit ;;
i*:windows32*:*)
- # uname -m includes "-pc" on this system.
- echo ${UNAME_MACHINE}-mingw32
+ # uname -m includes "-pc" on this system.
+ echo ${UNAME_MACHINE}-mingw32
exit ;;
i*:PW*:*)
echo ${UNAME_MACHINE}-pc-pw32
exit ;;
*:Interix*:*)
- case ${UNAME_MACHINE} in
+ case ${UNAME_MACHINE} in
x86)
echo i586-pc-interix${UNAME_RELEASE}
exit ;;
@@ -867,7 +870,7 @@ EOF
EV6) UNAME_MACHINE=alphaev6 ;;
EV67) UNAME_MACHINE=alphaev67 ;;
EV68*) UNAME_MACHINE=alphaev68 ;;
- esac
+ esac
objdump --private-headers /bin/sh | grep -q ld.so.1
if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi
echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC}
@@ -879,7 +882,13 @@ EOF
then
echo ${UNAME_MACHINE}-unknown-linux-gnu
else
- echo ${UNAME_MACHINE}-unknown-linux-gnueabi
+ if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \
+ | grep -q __ARM_PCS_VFP
+ then
+ echo ${UNAME_MACHINE}-unknown-linux-gnueabi
+ else
+ echo ${UNAME_MACHINE}-unknown-linux-gnueabihf
+ fi
fi
exit ;;
avr32*:Linux:*:*)
@@ -892,7 +901,7 @@ EOF
echo crisv32-axis-linux-gnu
exit ;;
frv:Linux:*:*)
- echo frv-unknown-linux-gnu
+ echo frv-unknown-linux-gnu
exit ;;
i*86:Linux:*:*)
LIBC=gnu
@@ -960,7 +969,7 @@ EOF
echo ${UNAME_MACHINE}-ibm-linux
exit ;;
sh64*:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-gnu
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
sh*:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
@@ -969,7 +978,7 @@ EOF
echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
tile*:Linux:*:*)
- echo ${UNAME_MACHINE}-tilera-linux-gnu
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
vax:Linux:*:*)
echo ${UNAME_MACHINE}-dec-linux-gnu
@@ -978,7 +987,7 @@ EOF
echo x86_64-unknown-linux-gnu
exit ;;
xtensa*:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-gnu
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
i*86:DYNIX/ptx:4*:*)
# ptx 4.0 does uname -s correctly, with DYNIX/ptx in there.
@@ -987,11 +996,11 @@ EOF
echo i386-sequent-sysv4
exit ;;
i*86:UNIX_SV:4.2MP:2.*)
- # Unixware is an offshoot of SVR4, but it has its own version
- # number series starting with 2...
- # I am not positive that other SVR4 systems won't match this,
+ # Unixware is an offshoot of SVR4, but it has its own version
+ # number series starting with 2...
+ # I am not positive that other SVR4 systems won't match this,
# I just have to hope. -- rms.
- # Use sysv4.2uw... so that sysv4* matches it.
+ # Use sysv4.2uw... so that sysv4* matches it.
echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION}
exit ;;
i*86:OS/2:*:*)
@@ -1023,7 +1032,7 @@ EOF
fi
exit ;;
i*86:*:5:[678]*)
- # UnixWare 7.x, OpenUNIX and OpenServer 6.
+ # UnixWare 7.x, OpenUNIX and OpenServer 6.
case `/bin/uname -X | grep "^Machine"` in
*486*) UNAME_MACHINE=i486 ;;
*Pentium) UNAME_MACHINE=i586 ;;
@@ -1051,13 +1060,13 @@ EOF
exit ;;
pc:*:*:*)
# Left here for compatibility:
- # uname -m prints for DJGPP always 'pc', but it prints nothing about
- # the processor, so we play safe by assuming i586.
+ # uname -m prints for DJGPP always 'pc', but it prints nothing about
+ # the processor, so we play safe by assuming i586.
# Note: whatever this is, it MUST be the same as what config.sub
# prints for the "djgpp" host, or else GDB configury will decide that
# this is a cross-build.
echo i586-pc-msdosdjgpp
- exit ;;
+ exit ;;
Intel:Mach:3*:*)
echo i386-pc-mach3
exit ;;
@@ -1092,8 +1101,8 @@ EOF
/bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
&& { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;;
3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*)
- /bin/uname -p 2>/dev/null | grep 86 >/dev/null \
- && { echo i486-ncr-sysv4; exit; } ;;
+ /bin/uname -p 2>/dev/null | grep 86 >/dev/null \
+ && { echo i486-ncr-sysv4; exit; } ;;
NCR*:*:4.2:* | MPRAS*:*:4.2:*)
OS_REL='.3'
test -r /etc/.relid \
@@ -1136,10 +1145,10 @@ EOF
echo ns32k-sni-sysv
fi
exit ;;
- PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort
- # says <address@hidden>
- echo i586-unisys-sysv4
- exit ;;
+ PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort
+ # says <address@hidden>
+ echo i586-unisys-sysv4
+ exit ;;
*:UNIX_System_V:4*:FTX*)
# From Gerald Hewes <address@hidden>.
# How about differentiating between stratus architectures? -djm
@@ -1165,11 +1174,11 @@ EOF
exit ;;
R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*)
if [ -d /usr/nec ]; then
- echo mips-nec-sysv${UNAME_RELEASE}
+ echo mips-nec-sysv${UNAME_RELEASE}
else
- echo mips-unknown-sysv${UNAME_RELEASE}
+ echo mips-unknown-sysv${UNAME_RELEASE}
fi
- exit ;;
+ exit ;;
BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only.
echo powerpc-be-beos
exit ;;
@@ -1282,13 +1291,13 @@ EOF
echo pdp10-unknown-its
exit ;;
SEI:*:*:SEIUX)
- echo mips-sei-seiux${UNAME_RELEASE}
+ echo mips-sei-seiux${UNAME_RELEASE}
exit ;;
*:DragonFly:*:*)
echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e
's/[-(].*//'`
exit ;;
*:*VMS:*:*)
- UNAME_MACHINE=`(uname -p) 2>/dev/null`
+ UNAME_MACHINE=`(uname -p) 2>/dev/null`
case "${UNAME_MACHINE}" in
A*) echo alpha-dec-vms ; exit ;;
I*) echo ia64-dec-vms ; exit ;;
@@ -1328,11 +1337,11 @@ main ()
#include <sys/param.h>
printf ("m68k-sony-newsos%s\n",
#ifdef NEWSOS4
- "4"
+ "4"
#else
- ""
+ ""
#endif
- ); exit (0);
+ ); exit (0);
#endif
#endif
diff --git a/lib/config.sub b/lib/config.sub
index 3ec94f1..f9fcdc8 100755
--- a/lib/config.sub
+++ b/lib/config.sub
@@ -1,10 +1,10 @@
#! /bin/sh
# Configuration validation subroutine script.
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
-# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010
-# Free Software Foundation, Inc.
+# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010,
+# 2011 Free Software Foundation, Inc.
-timestamp='2010-12-11'
+timestamp='2011-06-03'
# This file is (in principle) common to ALL GNU software.
# The presence of a machine in this file suggests that SOME GNU software
@@ -76,7 +76,7 @@ version="\
GNU config.sub ($timestamp)
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free
+2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free
Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
@@ -158,8 +158,8 @@ case $os in
os=
basic_machine=$1
;;
- -bluegene*)
- os=-cnk
+ -bluegene*)
+ os=-cnk
;;
-sim | -cisco | -oki | -wec | -winbond)
os=
@@ -175,10 +175,10 @@ case $os in
os=-chorusos
basic_machine=$1
;;
- -chorusrdb)
- os=-chorusrdb
+ -chorusrdb)
+ os=-chorusrdb
basic_machine=$1
- ;;
+ ;;
-hiux*)
os=-hiuxwe2
;;
@@ -286,9 +286,10 @@ case $basic_machine in
| nds32 | nds32le | nds32be \
| nios | nios2 \
| ns16k | ns32k \
+ | open8 \
| or32 \
| pdp10 | pdp11 | pj | pjl \
- | powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \
+ | powerpc | powerpc64 | powerpc64le | powerpcle \
| pyramid \
| rx \
| score \
@@ -296,12 +297,12 @@ case $basic_machine in
| sh64 | sh64le \
| sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet |
sparclite \
| sparcv8 | sparcv9 | sparcv9b | sparcv9v \
- | spu | strongarm \
- | tahoe | thumb | tic4x | tic54x | tic55x | tic6x | tic80 | tron \
+ | spu \
+ | tahoe | tic4x | tic54x | tic55x | tic6x | tic80 | tron \
| ubicom32 \
- | v850 | v850e \
+ | v850 | v850e | v850e1 | v850e2 | v850es | v850e2v3 \
| we32k \
- | x86 | xc16x | xscale | xscalee[bl] | xstormy16 | xtensa \
+ | x86 | xc16x | xstormy16 | xtensa \
| z8k | z80)
basic_machine=$basic_machine-unknown
;;
@@ -325,6 +326,18 @@ case $basic_machine in
basic_machine=mt-unknown
;;
+ strongarm | thumb | xscale)
+ basic_machine=arm-unknown
+ ;;
+
+ xscaleeb)
+ basic_machine=armeb-unknown
+ ;;
+
+ xscaleel)
+ basic_machine=armel-unknown
+ ;;
+
# We use `pc' rather than `unknown'
# because (1) that's what they normally are, and
# (2) the word "unknown" tends to confuse beginning users.
@@ -382,24 +395,26 @@ case $basic_machine in
| nds32-* | nds32le-* | nds32be-* \
| nios-* | nios2-* \
| none-* | np1-* | ns16k-* | ns32k-* \
+ | open8-* \
| orion-* \
| pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \
- | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \
+ | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* \
| pyramid-* \
| romp-* | rs6000-* | rx-* \
| sh-* | sh[1234]-* | sh[24]a-* | sh[24]aeb-* | sh[23]e-* | sh[34]eb-*
| sheb-* | shbe-* \
| shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \
| sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* |
sparclet-* \
| sparclite-* \
- | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | strongarm-* | sv1-*
| sx?-* \
- | tahoe-* | thumb-* \
+ | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | sv1-* | sx?-* \
+ | tahoe-* \
| tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \
- | tile-* | tilegx-* \
+ | tile*-* \
| tron-* \
| ubicom32-* \
- | v850-* | v850e-* | vax-* \
+ | v850-* | v850e-* | v850e1-* | v850es-* | v850e2-* | v850e2v3-* \
+ | vax-* \
| we32k-* \
- | x86-* | x86_64-* | xc16x-* | xps100-* | xscale-* | xscalee[bl]-* \
+ | x86-* | x86_64-* | xc16x-* | xps100-* \
| xstormy16-* | xtensa*-* \
| ymp-* \
| z8k-* | z80-*)
@@ -424,7 +439,7 @@ case $basic_machine in
basic_machine=a29k-amd
os=-udi
;;
- abacus)
+ abacus)
basic_machine=abacus-unknown
;;
adobe68k)
@@ -507,7 +522,7 @@ case $basic_machine in
basic_machine=c90-cray
os=-unicos
;;
- cegcc)
+ cegcc)
basic_machine=arm-unknown
os=-cegcc
;;
@@ -755,7 +770,7 @@ case $basic_machine in
basic_machine=ns32k-utek
os=-sysv
;;
- microblaze)
+ microblaze)
basic_machine=microblaze-xilinx
;;
mingw32)
@@ -862,10 +877,10 @@ case $basic_machine in
np1)
basic_machine=np1-gould
;;
- neo-tandem)
+ neo-tandem)
basic_machine=neo-tandem
;;
- nse-tandem)
+ nse-tandem)
basic_machine=nse-tandem
;;
nsr-tandem)
@@ -950,9 +965,10 @@ case $basic_machine in
;;
power) basic_machine=power-ibm
;;
- ppc) basic_machine=powerpc-unknown
+ ppc | ppcbe) basic_machine=powerpc-unknown
;;
- ppc-*) basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'`
+ ppc-* | ppcbe-*)
+ basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'`
;;
ppcle | powerpclittle | ppc-le | powerpc-little)
basic_machine=powerpcle-unknown
@@ -1046,6 +1062,9 @@ case $basic_machine in
basic_machine=i860-stratus
os=-sysv4
;;
+ strongarm-* | thumb-*)
+ basic_machine=arm-`echo $basic_machine | sed 's/^[^-]*-//'`
+ ;;
sun2)
basic_machine=m68000-sun
;;
@@ -1102,13 +1121,8 @@ case $basic_machine in
basic_machine=t90-cray
os=-unicos
;;
- # This must be matched before tile*.
- tilegx*)
- basic_machine=tilegx-unknown
- os=-linux-gnu
- ;;
tile*)
- basic_machine=tile-unknown
+ basic_machine=$basic_machine-unknown
os=-linux-gnu
;;
tx39)
@@ -1178,6 +1192,9 @@ case $basic_machine in
xps | xps100)
basic_machine=xps100-honeywell
;;
+ xscale-* | xscalee[bl]-*)
+ basic_machine=`echo $basic_machine | sed 's/^xscale/arm/'`
+ ;;
ymp)
basic_machine=ymp-cray
os=-unicos
@@ -1275,11 +1292,11 @@ esac
if [ x"$os" != x"" ]
then
case $os in
- # First match some system type aliases
- # that might get confused with valid system types.
+ # First match some system type aliases
+ # that might get confused with valid system types.
# -solaris* is a basic system type, with this one exception.
- -auroraux)
- os=-auroraux
+ -auroraux)
+ os=-auroraux
;;
-solaris1 | -solaris1.*)
os=`echo $os | sed -e 's|solaris1|sunos4|'`
@@ -1364,7 +1381,7 @@ case $os in
-opened*)
os=-openedition
;;
- -os400*)
+ -os400*)
os=-os400
;;
-wince*)
@@ -1413,7 +1430,7 @@ case $os in
-sinix*)
os=-sysv4
;;
- -tpf*)
+ -tpf*)
os=-tpf
;;
-triton*)
@@ -1458,8 +1475,8 @@ case $os in
-dicos*)
os=-dicos
;;
- -nacl*)
- ;;
+ -nacl*)
+ ;;
-none)
;;
*)
@@ -1482,10 +1499,10 @@ else
# system, and we'll never get to this point.
case $basic_machine in
- score-*)
+ score-*)
os=-elf
;;
- spu-*)
+ spu-*)
os=-elf
;;
*-acorn)
@@ -1497,8 +1514,8 @@ case $basic_machine in
arm*-semi)
os=-aout
;;
- c4x-* | tic4x-*)
- os=-coff
+ c4x-* | tic4x-*)
+ os=-coff
;;
tic54x-*)
os=-coff
@@ -1534,7 +1551,7 @@ case $basic_machine in
m68*-cisco)
os=-aout
;;
- mep-*)
+ mep-*)
os=-elf
;;
mips*-cisco)
@@ -1561,7 +1578,7 @@ case $basic_machine in
*-ibm)
os=-aix
;;
- *-knuth)
+ *-knuth)
os=-mmixware
;;
*-wec)
diff --git a/lib/texinfo.tex b/lib/texinfo.tex
index 1130b8f..fd22fd6 100644
--- a/lib/texinfo.tex
+++ b/lib/texinfo.tex
@@ -3,11 +3,11 @@
% Load plain if necessary, i.e., if running under initex.
\expandafter\ifx\csname fmtname\endcsname\relax\input plain\fi
%
-\def\texinfoversion{2010-12-23.17}
+\def\texinfoversion{2011-05-23.16}
%
% Copyright 1985, 1986, 1988, 1990, 1991, 1992, 1993, 1994, 1995,
% 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006,
-% 2007, 2008, 2009, 2010 Free Software Foundation, Inc.
+% 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc.
%
% This texinfo.tex file is free software: you can redistribute it and/or
% modify it under the terms of the GNU General Public License as
@@ -118,8 +118,8 @@
\ifx\putwordChapter\undefined \gdef\putwordChapter{Chapter}\fi
\ifx\putwordfile\undefined \gdef\putwordfile{file}\fi
\ifx\putwordin\undefined \gdef\putwordin{in}\fi
-\ifx\putwordIndexIsEmpty\undefined \gdef\putwordIndexIsEmpty{(Index is
empty)}\fi
-\ifx\putwordIndexNonexistent\undefined \gdef\putwordIndexNonexistent{(Index is
nonexistent)}\fi
+\ifx\putwordIndexIsEmpty\undefined \gdef\putwordIndexIsEmpty{(Index is
empty)}\fi
+\ifx\putwordIndexNonexistent\undefined \gdef\putwordIndexNonexistent{(Index
is nonexistent)}\fi
\ifx\putwordInfo\undefined \gdef\putwordInfo{Info}\fi
\ifx\putwordInstanceVariableof\undefined
\gdef\putwordInstanceVariableof{Instance Variable of}\fi
\ifx\putwordMethodon\undefined \gdef\putwordMethodon{Method on}\fi
@@ -158,15 +158,18 @@
\def\spaceisspace{\catcode`\ =\spacecat}
% sometimes characters are active, so we need control sequences.
+\chardef\ampChar = `\&
\chardef\colonChar = `\:
\chardef\commaChar = `\,
\chardef\dashChar = `\-
\chardef\dotChar = `\.
\chardef\exclamChar= `\!
+\chardef\hashChar = `\#
\chardef\lquoteChar= `\`
\chardef\questChar = `\?
\chardef\rquoteChar= `\'
\chardef\semiChar = `\;
+\chardef\slashChar = `\/
\chardef\underChar = `\_
% Ignore a token.
@@ -215,7 +218,7 @@
\tracingmacros2
\tracingrestores1
\showboxbreadth\maxdimen \showboxdepth\maxdimen
- \ifx\eTeXversion\undefined\else % etex gives us more logging
+ \ifx\eTeXversion\thisisundefined\else % etex gives us more logging
\tracingscantokens1
\tracingifs1
\tracinggroups1
@@ -545,7 +548,7 @@
}
\def\inenvironment#1{%
\ifx#1\empty
- out of any environment%
+ outside of any environment%
\else
in environment \expandafter\string#1%
\fi
@@ -557,7 +560,7 @@
\parseargdef\end{%
\if 1\csname iscond.#1\endcsname
\else
- % The general wording of \badenverr may not be ideal, but... --kasal,
06nov03
+ % The general wording of \badenverr may not be ideal.
\expandafter\checkenv\csname#1\endcsname
\csname E#1\endcsname
\endgroup
@@ -608,7 +611,7 @@
\else\ifx\temp\offword \plainnonfrenchspacing
\else
\errhelp = \EMsimple
- \errmessage{Unknown @frenchspacing option `\temp', must be on/off}%
+ \errmessage{Unknown @frenchspacing option `\temp', must be on|off}%
\fi\fi
}
@@ -690,15 +693,6 @@ where each line of input produces a line of output.}
\newdimen\mil \mil=0.001in
-% Old definition--didn't work.
-%\parseargdef\need{\par %
-%% This method tries to make TeX break the page naturally
-%% if the depth of the box does not fit.
-%{\baselineskip=0pt%
-%\vtop to #1\mil{\vfil}\kern -#1\mil\nobreak
-%\prevdepth=-1000pt
-%}}
-
\parseargdef\need{%
% Ensure vertical mode, so we don't make a big box in the middle of a
% paragraph.
@@ -849,6 +843,7 @@ where each line of input produces a line of output.}
\makevalueexpandable % we want to expand any @value in FILE.
\turnoffactive % and allow special characters in the expansion
\indexnofonts % Allow `@@' and other weird things in file names.
+ \wlog{texinfo.tex: doing @include of #1^^J}%
\edef\temp{\noexpand\input #1 }%
%
% This trickery is to read FILE outside of a group, in case it makes
@@ -1078,9 +1073,8 @@ where each line of input produces a line of output.}
\newif\ifpdfmakepagedest
% when pdftex is run in dvi mode, \pdfoutput is defined (so \pdfoutput=1
-% can be set). So we test for \relax and 0 as well as \undefined,
-% borrowed from ifpdf.sty.
-\ifx\pdfoutput\undefined
+% can be set). So we test for \relax and 0 as well as being undefined.
+\ifx\pdfoutput\thisisundefined
\else
\ifx\pdfoutput\relax
\else
@@ -1512,7 +1506,7 @@ output) for that.)}
% if we are producing pdf, and we have \pdffontattr, then define cmaps.
% (\pdffontattr was introduced many years ago, but people still run
% older pdftex's; it's easy to conditionalize, so we do.)
-\ifpdf \ifx\pdffontattr\undefined \else
+\ifpdf \ifx\pdffontattr\thisisundefined \else
\begingroup
\catcode`\^^M=\active \def^^M{^^J}% Output line endings as the ^^J char.
\catcode`\%=12 \immediate\pdfobj stream {%!PS-Adobe-3.0 Resource-CMap
@@ -1779,7 +1773,7 @@ end
% Use cm as the default font prefix.
% To specify the font prefix, you must define \fontprefix
% before you read in texinfo.tex.
-\ifx\fontprefix\undefined
+\ifx\fontprefix\thisisundefined
\def\fontprefix{cm}
\fi
% Support font families that don't use the same naming scheme as CM.
@@ -2070,7 +2064,7 @@ end
%
\parseargdef\fonttextsize{%
\def\textsizearg{#1}%
- \wlog{doing @fonttextsize \textsizearg}%
+ %\wlog{doing @fonttextsize \textsizearg}%
%
% Set \globaldefs so that documents can use this inside @tex, since
% makeinfo 4.8 does not support it, but we need it nonetheless.
@@ -2252,12 +2246,14 @@ end
% Markup style setup for left and right quotes.
\defmarkupstylesetup\markupsetuplq{%
- \expandafter\let\expandafter \temp \csname
markupsetuplq\currentmarkupstyle\endcsname
+ \expandafter\let\expandafter \temp
+ \csname markupsetuplq\currentmarkupstyle\endcsname
\ifx\temp\relax \markupsetuplqdefault \else \temp \fi
}
\defmarkupstylesetup\markupsetuprq{%
- \expandafter\let\expandafter \temp \csname
markupsetuprq\currentmarkupstyle\endcsname
+ \expandafter\let\expandafter \temp
+ \csname markupsetuprq\currentmarkupstyle\endcsname
\ifx\temp\relax \markupsetuprqdefault \else \temp \fi
}
@@ -2291,12 +2287,11 @@ end
\let\markupsetuplqkbd \markupsetnoligaturesquoteleft
-% Allow an option to not replace quotes with a regular directed right
-% quote/apostrophe (char 0x27), but instead use the undirected quote
-% from cmtt (char 0x0d). The undirected quote is ugly, so don't make it
-% the default, but it works for pasting with more pdf viewers (at least
-% evince), the lilypond developers report. xpdf does work with the
-% regular 0x27.
+% Allow an option to not use regular directed right quote/apostrophe
+% (char 0x27), but instead the undirected quote from cmtt (char 0x0d).
+% The undirected quote is ugly, so don't make it the default, but it
+% works for pasting with more pdf viewers (at least evince), the
+% lilypond developers report. xpdf does work with the regular 0x27.
%
\def\codequoteright{%
\expandafter\ifx\csname SETtxicodequoteundirected\endcsname\relax
@@ -2320,6 +2315,36 @@ end
\else \char'22 \fi
}
+% Commands to set the quote options.
+%
+\parseargdef\codequoteundirected{%
+ \def\temp{#1}%
+ \ifx\temp\onword
+ \expandafter\let\csname SETtxicodequoteundirected\endcsname
+ = t%
+ \else\ifx\temp\offword
+ \expandafter\let\csname SETtxicodequoteundirected\endcsname
+ = \relax
+ \else
+ \errhelp = \EMsimple
+ \errmessage{Unknown @codequoteundirected value `\temp', must be on|off}%
+ \fi\fi
+}
+%
+\parseargdef\codequotebacktick{%
+ \def\temp{#1}%
+ \ifx\temp\onword
+ \expandafter\let\csname SETtxicodequotebacktick\endcsname
+ = t%
+ \else\ifx\temp\offword
+ \expandafter\let\csname SETtxicodequotebacktick\endcsname
+ = \relax
+ \else
+ \errhelp = \EMsimple
+ \errmessage{Unknown @codequotebacktick value `\temp', must be on|off}%
+ \fi\fi
+}
+
% [Knuth] pp. 380,381,391, disable Spanish ligatures ?` and !` of \tt font.
\def\noligaturesquoteleft{\relax\lq}
@@ -2487,6 +2512,8 @@ end
}
}
+\def\codex #1{\tclose{#1}\endgroup}
+
\def\realdash{-}
\def\codedash{-\discretionary{}{}{}}
\def\codeunder{%
@@ -2500,7 +2527,6 @@ end
\discretionary{}{}{}}%
{\_}%
}
-\def\codex #1{\tclose{#1}\endgroup}
% An additional complication: the above will allow breaks after, e.g.,
% each of the four underscores in __typeof__. This is undesirable in
@@ -2520,63 +2546,18 @@ end
\allowcodebreaksfalse
\else
\errhelp = \EMsimple
- \errmessage{Unknown @allowcodebreaks option `\txiarg'}%
+ \errmessage{Unknown @allowcodebreaks option `\txiarg', must be true|false}%
\fi\fi
}
-% @kbd is like @code, except that if the argument is just one @key command,
-% then @kbd has no effect.
-\def\kbd#1{{\setupmarkupstyle{kbd}\def\look{#1}\expandafter\kbdfoo\look??\par}}
-
-% @kbdinputstyle -- arg is `distinct' (@kbd uses slanted tty font always),
-% `example' (@kbd uses ttsl only inside of @example and friends),
-% or `code' (@kbd uses normal tty font always).
-\parseargdef\kbdinputstyle{%
- \def\txiarg{#1}%
- \ifx\txiarg\worddistinct
- \gdef\kbdexamplefont{\ttsl}\gdef\kbdfont{\ttsl}%
- \else\ifx\txiarg\wordexample
- \gdef\kbdexamplefont{\ttsl}\gdef\kbdfont{\tt}%
- \else\ifx\txiarg\wordcode
- \gdef\kbdexamplefont{\tt}\gdef\kbdfont{\tt}%
- \else
- \errhelp = \EMsimple
- \errmessage{Unknown @kbdinputstyle option `\txiarg'}%
- \fi\fi\fi
-}
-\def\worddistinct{distinct}
-\def\wordexample{example}
-\def\wordcode{code}
-
-% Default is `distinct'.
-\kbdinputstyle distinct
-
-\def\xkey{\key}
-\def\kbdfoo#1#2#3\par{\def\one{#1}\def\three{#3}\def\threex{??}%
-\ifx\one\xkey\ifx\threex\three \key{#2}%
-\else{\tclose{\kbdfont\setupmarkupstyle{kbd}\look}}\fi
-\else{\tclose{\kbdfont\setupmarkupstyle{kbd}\look}}\fi}
-
-% For @indicateurl, @env, @command quotes seem unnecessary, so use \code.
-\let\indicateurl=\code
-\let\env=\code
-\let\command=\code
-
-% @clicksequence{File @click{} Open ...}
-\def\clicksequence#1{\begingroup #1\endgroup}
-
-% @clickstyle @arrow (by default)
-\parseargdef\clickstyle{\def\click{#1}}
-\def\click{\arrow}
-
% @uref (abbreviation for `urlref') takes an optional (comma-separated)
% second argument specifying the text to display and an optional third
% arg as text to display instead of (rather than in addition to) the url
-% itself. First (mandatory) arg is the url. Perhaps eventually put in
-% a hypertex \special here.
-%
-\def\uref#1{\douref #1,,,\finish}
-\def\douref#1,#2,#3,#4\finish{\begingroup
+% itself. First (mandatory) arg is the url.
+% (This \urefnobreak definition isn't used now, leaving it for a while
+% for comparison.)
+\def\urefnobreak#1{\dourefnobreak #1,,,\finish}
+\def\dourefnobreak#1,#2,#3,#4\finish{\begingroup
\unsepspaces
\pdfurl{#1}%
\setbox0 = \hbox{\ignorespaces #3}%
@@ -2597,6 +2578,103 @@ end
\endlink
\endgroup}
+% This \urefbreak definition is the active one.
+\def\urefbreak{\begingroup \urefcatcodes \dourefbreak}
+\let\uref=\urefbreak
+\def\dourefbreak#1{\urefbreakfinish #1,,,\finish}
+\def\urefbreakfinish#1,#2,#3,#4\finish{% doesn't work in @example
+ \unsepspaces
+ \pdfurl{#1}%
+ \setbox0 = \hbox{\ignorespaces #3}%
+ \ifdim\wd0 > 0pt
+ \unhbox0 % third arg given, show only that
+ \else
+ \setbox0 = \hbox{\ignorespaces #2}%
+ \ifdim\wd0 > 0pt
+ \ifpdf
+ \unhbox0 % PDF: 2nd arg given, show only it
+ \else
+ \unhbox0\ (\urefcode{#1})% DVI: 2nd arg given, show both it and url
+ \fi
+ \else
+ \urefcode{#1}% only url given, so show it
+ \fi
+ \fi
+ \endlink
+\endgroup}
+
+% Allow line breaks around only a few characters (only).
+\def\urefcatcodes{%
+ \catcode\ampChar=\active \catcode\dotChar=\active
+ \catcode\hashChar=\active \catcode\questChar=\active
+ \catcode\slashChar=\active
+}
+{
+ \urefcatcodes
+ %
+ \global\def\urefcode{\begingroup
+ \setupmarkupstyle{code}%
+ \urefcatcodes
+ \let&\urefcodeamp
+ \let.\urefcodedot
+ \let#\urefcodehash
+ \let?\urefcodequest
+ \let/\urefcodeslash
+ \codex
+ }
+ %
+ % By default, they are just regular characters.
+ \global\def&{\normalamp}
+ \global\def.{\normaldot}
+ \global\def#{\normalhash}
+ \global\def?{\normalquest}
+ \global\def/{\normalslash}
+}
+
+% we put a little stretch before and after the breakable chars, to help
+% line breaking of long url's. The unequal skips make look better in
+% cmtt at least, especially for dots.
+\def\urefprestretch{\urefprebreak \hskip0pt plus.13em }
+\def\urefpoststretch{\urefpostbreak \hskip0pt plus.1em }
+%
+\def\urefcodeamp{\urefprestretch \&\urefpoststretch}
+\def\urefcodedot{\urefprestretch .\urefpoststretch}
+\def\urefcodehash{\urefprestretch \#\urefpoststretch}
+\def\urefcodequest{\urefprestretch ?\urefpoststretch}
+\def\urefcodeslash{\futurelet\next\urefcodeslashfinish}
+{
+ \catcode`\/=\active
+ \global\def\urefcodeslashfinish{%
+ \urefprestretch \slashChar
+ % Allow line break only after the final / in a sequence of
+ % slashes, to avoid line break between the slashes in http://.
+ \ifx\next/\else \urefpoststretch \fi
+ }
+}
+
+% One more complication: by default we'll break after the special
+% characters, but some people like to break before the special chars, so
+% allow that. Also allow no breaking at all, for manual control.
+%
+\parseargdef\urefbreakstyle{%
+ \def\txiarg{#1}%
+ \ifx\txiarg\wordnone
+ \def\urefprebreak{\nobreak}\def\urefpostbreak{\nobreak}
+ \else\ifx\txiarg\wordbefore
+ \def\urefprebreak{\allowbreak}\def\urefpostbreak{\nobreak}
+ \else\ifx\txiarg\wordafter
+ \def\urefprebreak{\nobreak}\def\urefpostbreak{\allowbreak}
+ \else
+ \errhelp = \EMsimple
+ \errmessage{Unknown @urefbreakstyle setting `\txiarg'}%
+ \fi\fi\fi
+}
+\def\wordafter{after}
+\def\wordbefore{before}
+\def\wordnone{none}
+
+\urefbreakstyle after
+
% @url synonym for @uref, since that's how everyone uses it.
%
\let\url=\uref
@@ -2618,6 +2696,51 @@ end
\let\email=\uref
\fi
+% @kbd is like @code, except that if the argument is just one @key command,
+% then @kbd has no effect.
+\def\kbd#1{{\setupmarkupstyle{kbd}\def\look{#1}\expandafter\kbdfoo\look??\par}}
+
+% @kbdinputstyle -- arg is `distinct' (@kbd uses slanted tty font always),
+% `example' (@kbd uses ttsl only inside of @example and friends),
+% or `code' (@kbd uses normal tty font always).
+\parseargdef\kbdinputstyle{%
+ \def\txiarg{#1}%
+ \ifx\txiarg\worddistinct
+ \gdef\kbdexamplefont{\ttsl}\gdef\kbdfont{\ttsl}%
+ \else\ifx\txiarg\wordexample
+ \gdef\kbdexamplefont{\ttsl}\gdef\kbdfont{\tt}%
+ \else\ifx\txiarg\wordcode
+ \gdef\kbdexamplefont{\tt}\gdef\kbdfont{\tt}%
+ \else
+ \errhelp = \EMsimple
+ \errmessage{Unknown @kbdinputstyle setting `\txiarg'}%
+ \fi\fi\fi
+}
+\def\worddistinct{distinct}
+\def\wordexample{example}
+\def\wordcode{code}
+
+% Default is `distinct'.
+\kbdinputstyle distinct
+
+\def\xkey{\key}
+\def\kbdfoo#1#2#3\par{\def\one{#1}\def\three{#3}\def\threex{??}%
+\ifx\one\xkey\ifx\threex\three \key{#2}%
+\else{\tclose{\kbdfont\setupmarkupstyle{kbd}\look}}\fi
+\else{\tclose{\kbdfont\setupmarkupstyle{kbd}\look}}\fi}
+
+% For @indicateurl, @env, @command quotes seem unnecessary, so use \code.
+\let\indicateurl=\code
+\let\env=\code
+\let\command=\code
+
+% @clicksequence{File @click{} Open ...}
+\def\clicksequence#1{\begingroup #1\endgroup}
+
+% @clickstyle @arrow (by default)
+\parseargdef\clickstyle{\def\click{#1}}
+\def\click{\arrow}
+
% Typeset a dimension, e.g., `in' or `pt'. The only reason for the
% argument is to make the input look right: @dmn{pt} instead of @dmn{}pt.
%
@@ -3005,7 +3128,7 @@ end
% Textures 1.7.7 (preloaded format=plain 93.10.14) (68K) 16 APR 2004 02:38
% so we'll define it if necessary.
%
-\ifx\Orb\undefined
+\ifx\Orb\thisisundefined
\def\Orb{\mathhexbox20D}
\fi
@@ -3033,8 +3156,9 @@ end
\newif\ifsetshortcontentsaftertitlepage
\let\setshortcontentsaftertitlepage = \setshortcontentsaftertitlepagetrue
-\parseargdef\shorttitlepage{\begingroup\hbox{}\vskip 1.5in \chaprm
\centerline{#1}%
- \endgroup\page\hbox{}\page}
+\parseargdef\shorttitlepage{%
+ \begingroup \hbox{}\vskip 1.5in \chaprm \centerline{#1}%
+ \endgroup\page\hbox{}\page}
\envdef\titlepage{%
% Open one extra group, as we want to close it in the middle of \Etitlepage.
@@ -3094,7 +3218,7 @@ end
\finishedtitlepagetrue
}
-%%% Macros to be used within @titlepage:
+% Macros to be used within @titlepage:
\let\subtitlerm=\tenrm
\def\subtitlefont{\subtitlerm \normalbaselineskip = 13pt \normalbaselines}
@@ -3127,7 +3251,7 @@ end
}
-%%% Set up page headings and footings.
+% Set up page headings and footings.
\let\thispage=\folio
@@ -3279,7 +3403,7 @@ end
% This produces Day Month Year style of output.
% Only define if not already defined, in case a txi-??.tex file has set
% up a different format (e.g., txi-cs.tex does this).
-\ifx\today\undefined
+\ifx\today\thisisundefined
\def\today{%
\number\day\space
\ifcase\month
@@ -3826,9 +3950,9 @@ end
\setbox0=\vbox{X}\global\multitablelinespace=\the\baselineskip
\global\advance\multitablelinespace by-\ht0
\fi
-%% Test to see if parskip is larger than space between lines of
-%% table. If not, do nothing.
-%% If so, set to same dimension as multitablelinespace.
+% Test to see if parskip is larger than space between lines of
+% table. If not, do nothing.
+% If so, set to same dimension as multitablelinespace.
\ifdim\multitableparskip>\multitablelinespace
\global\multitableparskip=\multitablelinespace
\global\advance\multitableparskip-7pt %% to keep parskip somewhat smaller
@@ -5242,7 +5366,8 @@ end
\global\let\subsubsection = \appendixsubsubsec
}
-\outer\parseargdef\unnumbered{\unnmhead0{#1}} % normally unnmhead0 calls
unnumberedzzz
+% normally unnmhead0 calls unnumberedzzz:
+\outer\parseargdef\unnumbered{\unnmhead0{#1}}
\def\unnumberedzzz#1{%
\global\secno=0 \global\subsecno=0 \global\subsubsecno=0
\global\advance\unnumberedno by 1
@@ -5286,40 +5411,47 @@ end
\let\top\unnumbered
% Sections.
+%
\outer\parseargdef\numberedsec{\numhead1{#1}} % normally calls seczzz
\def\seczzz#1{%
\global\subsecno=0 \global\subsubsecno=0 \global\advance\secno by 1
\sectionheading{#1}{sec}{Ynumbered}{\the\chapno.\the\secno}%
}
-\outer\parseargdef\appendixsection{\apphead1{#1}} % normally calls
appendixsectionzzz
+% normally calls appendixsectionzzz:
+\outer\parseargdef\appendixsection{\apphead1{#1}}
\def\appendixsectionzzz#1{%
\global\subsecno=0 \global\subsubsecno=0 \global\advance\secno by 1
\sectionheading{#1}{sec}{Yappendix}{\appendixletter.\the\secno}%
}
\let\appendixsec\appendixsection
-\outer\parseargdef\unnumberedsec{\unnmhead1{#1}} % normally calls
unnumberedseczzz
+% normally calls unnumberedseczzz:
+\outer\parseargdef\unnumberedsec{\unnmhead1{#1}}
\def\unnumberedseczzz#1{%
\global\subsecno=0 \global\subsubsecno=0 \global\advance\secno by 1
\sectionheading{#1}{sec}{Ynothing}{\the\unnumberedno.\the\secno}%
}
% Subsections.
-\outer\parseargdef\numberedsubsec{\numhead2{#1}} % normally calls
numberedsubseczzz
+%
+% normally calls numberedsubseczzz:
+\outer\parseargdef\numberedsubsec{\numhead2{#1}}
\def\numberedsubseczzz#1{%
\global\subsubsecno=0 \global\advance\subsecno by 1
\sectionheading{#1}{subsec}{Ynumbered}{\the\chapno.\the\secno.\the\subsecno}%
}
-\outer\parseargdef\appendixsubsec{\apphead2{#1}} % normally calls
appendixsubseczzz
+% normally calls appendixsubseczzz:
+\outer\parseargdef\appendixsubsec{\apphead2{#1}}
\def\appendixsubseczzz#1{%
\global\subsubsecno=0 \global\advance\subsecno by 1
\sectionheading{#1}{subsec}{Yappendix}%
{\appendixletter.\the\secno.\the\subsecno}%
}
-\outer\parseargdef\unnumberedsubsec{\unnmhead2{#1}} %normally calls
unnumberedsubseczzz
+% normally calls unnumberedsubseczzz:
+\outer\parseargdef\unnumberedsubsec{\unnmhead2{#1}}
\def\unnumberedsubseczzz#1{%
\global\subsubsecno=0 \global\advance\subsecno by 1
\sectionheading{#1}{subsec}{Ynothing}%
@@ -5327,21 +5459,25 @@ end
}
% Subsubsections.
-\outer\parseargdef\numberedsubsubsec{\numhead3{#1}} % normally
numberedsubsubseczzz
+%
+% normally numberedsubsubseczzz:
+\outer\parseargdef\numberedsubsubsec{\numhead3{#1}}
\def\numberedsubsubseczzz#1{%
\global\advance\subsubsecno by 1
\sectionheading{#1}{subsubsec}{Ynumbered}%
{\the\chapno.\the\secno.\the\subsecno.\the\subsubsecno}%
}
-\outer\parseargdef\appendixsubsubsec{\apphead3{#1}} % normally
appendixsubsubseczzz
+% normally appendixsubsubseczzz:
+\outer\parseargdef\appendixsubsubsec{\apphead3{#1}}
\def\appendixsubsubseczzz#1{%
\global\advance\subsubsecno by 1
\sectionheading{#1}{subsubsec}{Yappendix}%
{\appendixletter.\the\secno.\the\subsecno.\the\subsubsecno}%
}
-\outer\parseargdef\unnumberedsubsubsec{\unnmhead3{#1}} %normally
unnumberedsubsubseczzz
+% normally unnumberedsubsubseczzz:
+\outer\parseargdef\unnumberedsubsubsec{\unnmhead3{#1}}
\def\unnumberedsubsubseczzz#1{%
\global\advance\subsubsecno by 1
\sectionheading{#1}{subsubsec}{Ynothing}%
@@ -5391,14 +5527,13 @@ end
% (including whitespace, linebreaking, etc. around it),
% given all the information in convenient, parsed form.
-%%% Args are the skip and penalty (usually negative)
+% Args are the skip and penalty (usually negative)
\def\dobreak#1#2{\par\ifdim\lastskip<#1\removelastskip\penalty#2\vskip#1\fi}
-%%% Define plain chapter starts, and page on/off switching for it
% Parameter controlling skip before chapter headings (if needed)
-
\newskip\chapheadingskip
+% Define plain chapter starts, and page on/off switching for it.
\def\chapbreak{\dobreak \chapheadingskip {-4000}}
\def\chappager{\par\vfill\supereject}
% Because \domark is called before \chapoddpage, the filler page will
@@ -5601,6 +5736,8 @@ end
%
\def\sectionheading#1#2#3#4{%
{%
+ \checkenv{}% should not be in an environment.
+ %
% Switch to the right set of fonts.
\csname #2fonts\endcsname \rmisbold
%
@@ -6346,7 +6483,7 @@ end
%
\def\Equotation{%
\par
- \ifx\quotationauthor\undefined\else
+ \ifx\quotationauthor\thisisundefined\else
% indent a bit.
\leftline{\kern 2\leftskip \sl ---\quotationauthor}%
\fi
@@ -6505,6 +6642,7 @@ end
\makevalueexpandable
\setupverbatim
\indexnofonts % Allow `@@' and other weird things in file names.
+ \wlog{texinfo.tex: doing @verbatiminclude of #1^^J}%
\input #1
\afterenvbreak
}%
@@ -6554,7 +6692,7 @@ end
% commands also insert a nobreak penalty, and we don't want to allow
% a break between a section heading and a defun.
%
- % As a minor refinement, we avoid "club" headers by signalling
+ % As a further refinement, we avoid "club" headers by signalling
% with penalty of 10003 after the very first @deffn in the
% sequence (see above), and penalty of 10002 after any following
% @def command.
@@ -6621,13 +6759,36 @@ end
\def\domakedefun#1#2#3{%
\envdef#1{%
\startdefun
+ \doingtypefnfalse % distinguish typed functions from all else
\parseargusing\activeparens{\printdefunline#3}%
}%
\def#2{\dodefunx#1}%
\def#3%
}
-%%% Untyped functions:
+\newif\ifdoingtypefn % doing typed function?
+\newif\ifrettypeownline % typeset return type on its own line?
+
+% @deftypefnnewline on|off says whether the return type of typed functions
+% are printed on their own line. This affects @deftypefn, @deftypefun,
+% @deftypeop, and @deftypemethod.
+%
+\parseargdef\deftypefnnewline{%
+ \def\temp{#1}%
+ \ifx\temp\onword
+ \expandafter\let\csname SETtxideftypefnnl\endcsname
+ = \empty
+ \else\ifx\temp\offword
+ \expandafter\let\csname SETtxideftypefnnl\endcsname
+ = \relax
+ \else
+ \errhelp = \EMsimple
+ \errmessage{Unknown @txideftypefnnl value `\temp',
+ must be on|off}%
+ \fi\fi
+}
+
+% Untyped functions:
% @deffn category name args
\makedefun{deffn}{\deffngeneral{}}
@@ -6646,7 +6807,7 @@ end
\defname{#2}{}{#3}\magicamp\defunargs{#4\unskip}%
}
-%%% Typed functions:
+% Typed functions:
% @deftypefn category type name args
\makedefun{deftypefn}{\deftypefngeneral{}}
@@ -6661,10 +6822,11 @@ end
%
\def\deftypefngeneral#1#2 #3 #4 #5\endheader{%
\dosubind{fn}{\code{#4}}{#1}%
+ \doingtypefntrue
\defname{#2}{#3}{#4}\defunargs{#5\unskip}%
}
-%%% Typed variables:
+% Typed variables:
% @deftypevr category type var args
\makedefun{deftypevr}{\deftypecvgeneral{}}
@@ -6682,7 +6844,7 @@ end
\defname{#2}{#3}{#4}\defunargs{#5\unskip}%
}
-%%% Untyped variables:
+% Untyped variables:
% @defvr category var args
\makedefun{defvr}#1 {\deftypevrheader{#1} {} }
@@ -6693,7 +6855,8 @@ end
% \defcvof {category of}class var args
\def\defcvof#1#2 {\deftypecvof{#1}#2 {} }
-%%% Type:
+% Types:
+
% @deftp category name args
\makedefun{deftp}#1 #2 #3\endheader{%
\doind{tp}{\code{#2}}%
@@ -6721,25 +6884,49 @@ end
% We are followed by (but not passed) the arguments, if any.
%
\def\defname#1#2#3{%
+ \par
% Get the values of \leftskip and \rightskip as they were outside the @def...
\advance\leftskip by -\defbodyindent
%
- % How we'll format the type name. Putting it in brackets helps
+ % Determine if we are typesetting the return type of a typed function
+ % on a line by itself.
+ \rettypeownlinefalse
+ \ifdoingtypefn % doing a typed function specifically?
+ % then check user option for putting return type on its own line:
+ \expandafter\ifx\csname SETtxideftypefnnl\endcsname\relax \else
+ \rettypeownlinetrue
+ \fi
+ \fi
+ %
+ % How we'll format the category name. Putting it in brackets helps
% distinguish it from the body text that may end up on the next line
% just below it.
\def\temp{#1}%
\setbox0=\hbox{\kern\deflastargmargin \ifx\temp\empty\else [\rm\temp]\fi}
%
- % Figure out line sizes for the paragraph shape.
+ % Figure out line sizes for the paragraph shape. We'll always have at
+ % least two.
+ \tempnum = 2
+ %
% The first line needs space for \box0; but if \rightskip is nonzero,
% we need only space for the part of \box0 which exceeds it:
\dimen0=\hsize \advance\dimen0 by -\wd0 \advance\dimen0 by \rightskip
+ %
+ % If doing a return type on its own line, we'll have another line.
+ \ifrettypeownline
+ \advance\tempnum by 1
+ \def\maybeshapeline{0in \hsize}%
+ \else
+ \def\maybeshapeline{}%
+ \fi
+ %
% The continuations:
\dimen2=\hsize \advance\dimen2 by -\defargsindent
- % (plain.tex says that \dimen1 should be used only as global.)
- \parshape 2 0in \dimen0 \defargsindent \dimen2
%
- % Put the type name to the right margin.
+ % The final paragraph shape:
+ \parshape \tempnum 0in \dimen0 \maybeshapeline \defargsindent \dimen2
+ %
+ % Put the category name at the right margin.
\noindent
\hbox to 0pt{%
\hfil\box0 \kern-\hsize
@@ -6761,8 +6948,16 @@ end
% . this still does not fix the ?` and !` ligatures, but so far no
% one has made identifiers using them :).
\df \tt
- \def\temp{#2}% return value type
- \ifx\temp\empty\else \tclose{\temp} \fi
+ \def\temp{#2}% text of the return type
+ \ifx\temp\empty\else
+ \tclose{\temp}% typeset the return type
+ \ifrettypeownline
+ % put return type on its own line; prohibit line break following:
+ \hfil\vadjust{\nobreak}\break
+ \else
+ \space % type on same line, so just followed by a space
+ \fi
+ \fi % no return type
#3% output function name
}%
{\rm\enskip}% hskip 0.5 em of \tenrm
@@ -6880,7 +7075,7 @@ end
% To do this right we need a feature of e-TeX, \scantokens,
% which we arrange to emulate with a temporary file in ordinary TeX.
-\ifx\eTeXversion\undefined
+\ifx\eTeXversion\thisisundefined
\newwrite\macscribble
\def\scantokens#1{%
\toks0={#1}%
@@ -6905,12 +7100,14 @@ end
% ... and for \example:
\spaceisspace
%
- % The \empty here causes a following catcode 5 newline to be eaten
- % as part of reading whitespace after a control sequence. It does
- % not eat a catcode 13 newline. There's no good way to handle the
- % two cases. See the Macro Details node in the manual for the
- % workaround we currently have to recommend for macros and
+ % The \empty here causes a following catcode 5 newline to be eaten as
+ % part of reading whitespace after a control sequence. It does not
+ % eat a catcode 13 newline. There's no good way to handle the two
+ % cases (untried: maybe e-TeX's \everyeof could help, though plain TeX
+ % would then have different behavior). See the Macro Details node in
+ % the manual for the workaround we recommend for macros and
% line-oriented commands.
+ %
\scantokens{#1\empty}%
\endgroup}
@@ -7235,7 +7432,8 @@ end
% @inforef is relatively simple.
\def\inforef #1{\inforefzzz #1,,,,**}
-\def\inforefzzz #1,#2,#3,#4**{\putwordSee{} \putwordInfo{} \putwordfile{}
\file{\ignorespaces #3{}},
+\def\inforefzzz #1,#2,#3,#4**{%
+ \putwordSee{} \putwordInfo{} \putwordfile{} \file{\ignorespaces #3{}},
node \samp{\ignorespaces#1{}}}
% @node's only job in TeX is to define \lastnode, which is used in
@@ -7296,11 +7494,32 @@ end
\toks0 = \expandafter{\lastsection}%
\immediate \writexrdef{title}{\the\toks0 }%
\immediate \writexrdef{snt}{\csname #2\endcsname}% \Ynumbered etc.
- \safewhatsit{\writexrdef{pg}{\folio}}% will be written later, during
\shipout
+ \safewhatsit{\writexrdef{pg}{\folio}}% will be written later, at \shipout
}%
\fi
}
+% @xrefautosectiontitle on|off says whether @section(ing) names are used
+% automatically in xrefs, if the third arg is not explicitly specified.
+% This was provided as a "secret" @set xref-automatic-section-title
+% variable, now it's official.
+%
+\parseargdef\xrefautomaticsectiontitle{%
+ \def\temp{#1}%
+ \ifx\temp\onword
+ \expandafter\let\csname SETxref-automatic-section-title\endcsname
+ = \empty
+ \else\ifx\temp\offword
+ \expandafter\let\csname SETxref-automatic-section-title\endcsname
+ = \relax
+ \else
+ \errhelp = \EMsimple
+ \errmessage{Unknown @xrefautomaticsectiontitle value `\temp',
+ must be on|off}%
+ \fi\fi
+}
+
+
% @xref, @pxref, and @ref generate cross-references. For \xrefX, #1 is
% the node name, #2 the name of the Info cross-reference, #3 the printed
% node name, #4 the name of the Info file, #5 the name of the printed
@@ -7317,7 +7536,7 @@ end
\setbox0=\hbox{\printedrefname\unskip}%
\ifdim \wd0 = 0pt
% No printed node name was explicitly given.
- \expandafter\ifx\csname SETxref-automatic-section-title\endcsname\relax
+ \expandafter\ifx\csname SETxref-automatic-section-title\endcsname \relax
% Use the node name inside the square brackets.
\def\printedrefname{\ignorespaces #1}%
\else
@@ -7787,7 +8006,7 @@ end
it from ftp://tug.org/tex/epsf.tex.}
%
\def\image#1{%
- \ifx\epsfbox\undefined
+ \ifx\epsfbox\thisiundefined
\ifwarnednoepsf \else
\errhelp = \noepsfhelp
\errmessage{epsf.tex not found, images will be ignored}%
@@ -8252,7 +8471,7 @@ directory should work if nowhere else does.}
%
% Latin1 (ISO-8859-1) character definitions.
\def\latonechardefs{%
- \gdef^^a0{~}
+ \gdef^^a0{\tie}
\gdef^^a1{\exclamdown}
\gdef^^a2{\missingcharmsg{CENT SIGN}}
\gdef^^a3{{\pounds}}
@@ -8282,7 +8501,7 @@ directory should work if nowhere else does.}
\gdef^^b9{$^1$}
\gdef^^ba{\ordm}
%
- \gdef^^bb{\guilletright}
+ \gdef^^bb{\guillemetright}
\gdef^^bc{$1\over4$}
\gdef^^bd{$1\over2$}
\gdef^^be{$3\over4$}
@@ -8374,7 +8593,7 @@ directory should work if nowhere else does.}
% Latin2 (ISO-8859-2) character definitions.
\def\lattwochardefs{%
- \gdef^^a0{~}
+ \gdef^^a0{\tie}
\gdef^^a1{\ogonek{A}}
\gdef^^a2{\u{}}
\gdef^^a3{\L}
@@ -8547,7 +8766,7 @@ directory should work if nowhere else does.}
\gdef\DeclareUnicodeCharacter#1#2{%
\countUTFz = "#1\relax
- \wlog{\space\space defining Unicode char U+#1 (decimal \the\countUTFz)}%
+ %\wlog{\space\space defining Unicode char U+#1 (decimal \the\countUTFz)}%
\begingroup
\parseXMLCharref
\def\UTFviiiTwoOctets##1##2{%
@@ -9223,28 +9442,21 @@ directory should work if nowhere else does.}
\message{and turning on texinfo input format.}
+\def^^L{\par} % remove \outer, so ^L can appear in an @comment
+
% DEL is a comment character, in case @c does not suffice.
\catcode`\^^? = 14
% Define macros to output various characters with catcode for normal text.
-\catcode`\"=\other
-\catcode`\~=\other
-\catcode`\^=\other
-\catcode`\_=\other
-\catcode`\|=\other
-\catcode`\<=\other
-\catcode`\>=\other
-\catcode`\+=\other
-\catcode`\$=\other
-\def\normaldoublequote{"}
-\def\normaltilde{~}
-\def\normalcaret{^}
-\def\normalunderscore{_}
-\def\normalverticalbar{|}
-\def\normalless{<}
-\def\normalgreater{>}
-\def\normalplus{+}
-\def\normaldollar{$}%$ font-lock fix
+\catcode`\"=\other \def\normaldoublequote{"}
+\catcode`\$=\other \def\normaldollar{$}%$ font-lock fix
+\catcode`\+=\other \def\normalplus{+}
+\catcode`\<=\other \def\normalless{<}
+\catcode`\>=\other \def\normalgreater{>}
+\catcode`\^=\other \def\normalcaret{^}
+\catcode`\_=\other \def\normalunderscore{_}
+\catcode`\|=\other \def\normalverticalbar{|}
+\catcode`\~=\other \def\normaltilde{~}
% This macro is used to make a character print one way in \tt
% (where it can probably be output as-is), and another way in other fonts,
@@ -9337,16 +9549,16 @@ directory should work if nowhere else does.}
% the literal character `\'.
%
@address@hidden
- @address@hidden
@let"address@hidden
- @address@hidden
+ @address@hidden %$ font-lock fix
+ @address@hidden
+ @let<address@hidden
+ @let>address@hidden
+ @address@hidden
@address@hidden
@address@hidden
@let|address@hidden
- @let<address@hidden
- @let>address@hidden
- @address@hidden
- @address@hidden %$ font-lock fix
+ @address@hidden
@markupsetuplqdefault
@markupsetuprqdefault
@unsepspaces
@@ -9378,10 +9590,16 @@ directory should work if nowhere else does.}
% Say @foo, not \foo, in error messages.
@escapechar = `@@
+% These (along with & and #) are made active for url-breaking, so need
+% active definitions as the normal characters.
address@hidden@normaldot{.}
address@hidden@normalquest{?}
address@hidden@normalslash{/}
+
% These look ok in all fonts, so just make them not special.
address@hidden@& = @other
address@hidden@# = @other
address@hidden@% = @other
address@hidden@& = @other @address@hidden&}
address@hidden@# = @other @address@hidden
address@hidden@% = @other @address@hidden
@c Finally, make ` and ' active, so that txicodequoteundirected and
@c txicodequotebacktick work right in, e.g., @address@hidden'}}. If we
diff --git a/m4/Makefile.in b/m4/Makefile.in
index 845ad1f..2499ca7 100644
--- a/m4/Makefile.in
+++ b/m4/Makefile.in
@@ -141,6 +141,9 @@ abs_top_builddir = @abs_top_builddir@
abs_top_srcdir = @abs_top_srcdir@
am_AUTOCONF = @am_AUTOCONF@
am_AUTOHEADER = @am_AUTOHEADER@
+am_AUTOM4TE = @am_AUTOM4TE@
+am_AUTORECONF = @am_AUTORECONF@
+am_AUTOUPDATE = @am_AUTOUPDATE@
am__leading_dot = @am__leading_dot@
am__tar = @am__tar@
am__untar = @am__untar@
diff --git a/m4/protos.m4 b/m4/protos.m4
index 427193b..f710293 100644
--- a/m4/protos.m4
+++ b/m4/protos.m4
@@ -13,6 +13,8 @@
AC_DEFUN([AM_C_PROTOTYPES],
[AC_REQUIRE([AC_C_PROTOTYPES])
+AC_DIAGNOSE([obsolete],
+ [$0: automatic de-ANSI-fication support is deprecated])
if test "$ac_cv_prog_cc_stdc" != no; then
U= ANSI2KNR=
else
diff --git a/tests/Makefile.am b/tests/Makefile.am
index b91a025..b545dda 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -38,7 +38,16 @@ $(parallel_tests): $(parallel_tests:-p.test=.test)
Makefile.am
MAINTAINERCLEANFILES = $(parallel_tests)
+# Some testsuite-influential variables should be overridable from the
+# test scripts, but not from the environment.
+TESTS_ENVIRONMENT = \
+ test x"$$me" = x || unset me; \
+ test x"$$required" = x || unset required; \
+ test x"$$parallel_tests" = x || unset parallel_tests;
+
TESTS = \
+self-check-env-sanitize.test \
+self-check-report.test \
aclibobj.test \
aclocal.test \
aclocal3.test \
@@ -76,10 +85,14 @@ alloca.test \
alloca2.test \
alpha.test \
alpha2.test \
+amhello-cflags.test \
+amhello-cross-compile.test \
+amhello-binpkg.test \
amassign.test \
ammissing.test \
amopt.test \
amsubst.test \
+ansi2knr-deprecation.test \
ansi.test \
ansi2.test \
ansi3.test \
@@ -103,6 +116,7 @@ autodist-acconfig-no-subdir.test \
autodist-aclocal-m4.test \
autodist-config-headers.test \
autodist-configure-no-subdir.test \
+autodist-no-duplicate.test \
autodist-stamp-vti.test \
autohdr.test \
autohdr2.test \
@@ -146,6 +160,7 @@ check11.test \
check-exported-srcdir.test \
check-tests-in-builddir.test \
check-tests_environment.test \
+tests-environment-backcompat.test \
checkall.test \
clean.test \
clean2.test \
@@ -288,7 +303,6 @@ depend4.test \
depend5.test \
depend6.test \
destdir.test \
-dirforbid.test \
dirlist.test \
dirlist2.test \
discover.test \
@@ -304,6 +318,11 @@ distdir.test \
distlinks.test \
distlinksbrk.test \
distname.test \
+distcheck-configure-flags.test \
+distcheck-configure-flags-am.test \
+distcheck-configure-flags-subpkg.test \
+distcheck-hook.test \
+distcheck-hook2.test \
dmalloc.test \
dollar.test \
dollarvar.test \
@@ -509,7 +528,6 @@ man2.test \
man3.test \
man4.test \
man5.test \
-mclean.test \
mdate.test \
mdate2.test \
mdate3.test \
@@ -580,8 +598,13 @@ parallel-tests7.test \
parallel-tests8.test \
parallel-tests9.test \
parallel-tests10.test \
+parallel-tests-harderror.test \
parallel-tests-unreadable-log.test \
parallel-tests-subdir.test \
+parallel-tests-log-override-1.test \
+parallel-tests-log-override-2.test \
+parallel-tests-log-override-recheck.test \
+parallel-tests-log-compiler-example.test \
parse.test \
percent.test \
percent2.test \
@@ -624,6 +647,10 @@ prefix.test \
primary.test \
primary2.test \
primary3.test \
+primary-prefix-invalid-couples.test \
+primary-prefix-valid-couples.test \
+primary-prefix-couples-force-valid.test \
+primary-prefix-couples-documented-valid.test \
proginst.test \
python.test \
python2.test \
@@ -646,6 +673,11 @@ remake4.test \
remake5.test \
remake6.test \
remake7.test \
+remake-subdir-from-subdir.test \
+remake-subdir-gnu.test \
+remake-subdir.test \
+remake-subdir2.test \
+remake-subdir-long-time.test \
pr8365-remake-timing.test \
regex.test \
req.test \
@@ -671,6 +703,7 @@ silent-lex-gcc.test \
silent-lex-generic.test \
silent-yacc-gcc.test \
silent-yacc-generic.test \
+silent-configsite.test \
srcsub.test \
srcsub2.test \
space.test \
diff --git a/tests/Makefile.in b/tests/Makefile.in
index 371d214..85a5168 100644
--- a/tests/Makefile.in
+++ b/tests/Makefile.in
@@ -108,15 +108,21 @@ am__base_list = \
am__rst_title = sed 's/.*/ & /;h;s/./=/g;p;x;p;g;p;s/.*//'
am__rst_section = sed 'p;s/./=/g;p;g'
# Put stdin (possibly several lines separated by ". ") in a box.
-am__text_box = $(AWK) '{ \
- n = split($$0, lines, "\\. "); max = 0; \
- for (i = 1; i <= n; ++i) \
- if (max < length(lines[i])) \
- max = length(lines[i]); \
- for (i = 0; i < max; ++i) line = line "="; \
- print line; \
- for (i = 1; i <= n; ++i) if (lines[i]) print lines[i];\
- print line; \
+# Prefix each line by 'col' and terminate each with 'std', for coloring.
+# Multi line coloring is problematic with "less -R", so we really need
+# to color each line individually.
+am__text_box = $(AWK) '{ \
+ n = split($$0, lines, "\\. "); max = 0; \
+ for (i = 1; i <= n; ++i) \
+ if (max < length(lines[i])) \
+ max = length(lines[i]); \
+ for (i = 0; i < max; ++i) \
+ line = line "="; \
+ print col line std; \
+ for (i = 1; i <= n; ++i) \
+ if (lines[i]) \
+ print col lines[i] std; \
+ print col line std; \
}'
# Solaris 10 'make', and several other traditional 'make' implementations,
# pass "-e" to $(SHELL), and POSIX 2008 even requires this. Work around it
@@ -231,6 +237,9 @@ abs_top_builddir = @abs_top_builddir@
abs_top_srcdir = @abs_top_srcdir@
am_AUTOCONF = @am_AUTOCONF@
am_AUTOHEADER = @am_AUTOHEADER@
+am_AUTOM4TE = @am_AUTOM4TE@
+am_AUTORECONF = @am_AUTORECONF@
+am_AUTOUPDATE = @am_AUTOUPDATE@
am__leading_dot = @am__leading_dot@
am__tar = @am__tar@
am__untar = @am__untar@
@@ -302,13 +311,20 @@ comment9-p.test \
dejagnu-p.test \
exeext4-p.test \
maken3-p.test \
-maken4-p.test \
-pr401-p.test \
-pr401b-p.test \
-pr401c-p.test
+maken4-p.test
MAINTAINERCLEANFILES = $(parallel_tests)
+
+# Some testsuite-influential variables should be overridable from the
+# test scripts, but not from the environment.
+TESTS_ENVIRONMENT = \
+ test x"$$me" = x || unset me; \
+ test x"$$required" = x || unset required; \
+ test x"$$parallel_tests" = x || unset parallel_tests;
+
TESTS = \
+self-check-env-sanitize.test \
+self-check-report.test \
aclibobj.test \
aclocal.test \
aclocal3.test \
@@ -346,10 +362,14 @@ alloca.test \
alloca2.test \
alpha.test \
alpha2.test \
+amhello-cflags.test \
+amhello-cross-compile.test \
+amhello-binpkg.test \
amassign.test \
ammissing.test \
amopt.test \
amsubst.test \
+ansi2knr-deprecation.test \
ansi.test \
ansi2.test \
ansi3.test \
@@ -373,6 +393,7 @@ autodist-acconfig-no-subdir.test \
autodist-aclocal-m4.test \
autodist-config-headers.test \
autodist-configure-no-subdir.test \
+autodist-no-duplicate.test \
autodist-stamp-vti.test \
autohdr.test \
autohdr2.test \
@@ -416,6 +437,7 @@ check11.test \
check-exported-srcdir.test \
check-tests-in-builddir.test \
check-tests_environment.test \
+tests-environment-backcompat.test \
checkall.test \
clean.test \
clean2.test \
@@ -558,7 +580,6 @@ depend4.test \
depend5.test \
depend6.test \
destdir.test \
-dirforbid.test \
dirlist.test \
dirlist2.test \
discover.test \
@@ -574,6 +595,11 @@ distdir.test \
distlinks.test \
distlinksbrk.test \
distname.test \
+distcheck-configure-flags.test \
+distcheck-configure-flags-am.test \
+distcheck-configure-flags-subpkg.test \
+distcheck-hook.test \
+distcheck-hook2.test \
dmalloc.test \
dollar.test \
dollarvar.test \
@@ -779,7 +805,6 @@ man2.test \
man3.test \
man4.test \
man5.test \
-mclean.test \
mdate.test \
mdate2.test \
mdate3.test \
@@ -850,8 +875,13 @@ parallel-tests7.test \
parallel-tests8.test \
parallel-tests9.test \
parallel-tests10.test \
+parallel-tests-harderror.test \
parallel-tests-unreadable-log.test \
parallel-tests-subdir.test \
+parallel-tests-log-override-1.test \
+parallel-tests-log-override-2.test \
+parallel-tests-log-override-recheck.test \
+parallel-tests-log-compiler-example.test \
parse.test \
percent.test \
percent2.test \
@@ -894,6 +924,10 @@ prefix.test \
primary.test \
primary2.test \
primary3.test \
+primary-prefix-invalid-couples.test \
+primary-prefix-valid-couples.test \
+primary-prefix-couples-force-valid.test \
+primary-prefix-couples-documented-valid.test \
proginst.test \
python.test \
python2.test \
@@ -916,6 +950,11 @@ remake4.test \
remake5.test \
remake6.test \
remake7.test \
+remake-subdir-from-subdir.test \
+remake-subdir-gnu.test \
+remake-subdir.test \
+remake-subdir2.test \
+remake-subdir-long-time.test \
pr8365-remake-timing.test \
regex.test \
req.test \
@@ -941,6 +980,7 @@ silent-lex-gcc.test \
silent-lex-generic.test \
silent-yacc-gcc.test \
silent-yacc-generic.test \
+silent-configsite.test \
srcsub.test \
srcsub2.test \
space.test \
@@ -1229,12 +1269,11 @@ $(TEST_SUITE_LOG): $(TEST_LOGS)
test x"$$VERBOSE" = x || $$exit || cat $(TEST_SUITE_LOG); \
$(am__tty_colors); \
if $$exit; then \
- echo $(ECHO_N) "$$grn$(ECHO_C)"; \
+ col="$$grn"; \
else \
- echo $(ECHO_N) "$$red$(ECHO_C)"; \
+ col="$$red"; \
fi; \
- echo "$$msg" | $(am__text_box); \
- echo $(ECHO_N) "$$std$(ECHO_C)"; \
+ echo "$$msg" | $(am__text_box) "col=$$col" "std=$$std"; \
$$exit
# Run all the tests.
diff --git a/tests/README b/tests/README
index 93f9cbf..ca17c4f 100644
--- a/tests/README
+++ b/tests/README
@@ -93,6 +93,13 @@ Do
Cite the PR number (if any), and the original reporter (if any), so
we can find or ask for information if needed.
+ If a test checks examples or idioms given in the documentation, make
+ sure the documentation reference them appropriately in comments, as in:
+ @c Keep in sync with autodist-config-headers.test.
+ @example
+ ...
+ @end example
+
Use `required=...' for required tools. Do not explicitly require
tools which can be taken for granted because they're listed in the
GNU Coding Standards (for example, `gzip').
@@ -100,10 +107,20 @@ Do
Include ./defs in every test script (see existing tests for examples
of how to do this).
+ Use the `skip_' function to skip tests, with a meaningful message if
+ possible. Where convenient, use the `warn_' function to print generic
+ warnings, the `fail_' function for test failures, and the `fatal_'
+ function for hard errors. In case a hard error is due to a failed
+ set-up of a test scenario, you can use the `framework_fail_' function
+ instead.
+
For tests that use the `parallel-tests' Automake option, set the shell
variable `parallel_tests' to "yes" before including ./defs. Also,
- use for them a name that ends in `-p.test' and does not clash with any
- generated tests in the suite.
+ do not use for them a name that ends in `-p.test', since that would
+ risk to clash with automatically-generated tests. For tests that are
+ *not* meant to work with the `parallel-tests' Automake option (these
+ should be very very few), set the shell variable `parallel_tests' to
+ "no" before including ./defs.
./defs sets a skeleton configure.in. If possible, append to this
file. In some cases you'll have to overwrite it, but this should
@@ -172,12 +189,12 @@ Do not
reason, but at least it makes sure the original error is still
here.)
- Do not override Makefile variables using make arguments, as in
- $MAKE ANSI2KNR=./ansi2knr U=_ all
- this is not portable for recursive targets (targets that
- call a sub-make may not pass `ANSI2KNR=./ansi2knr U=_' along).
- Use the following instead.
- ANSI2KNR=./ansi2knr U=_ $MAKE -e all
+ Do not override Makefile variables using make arguments, as in e.g.:
+ $MAKE prefix=/opt install
+ This is not portable for recursive targets (targets that call a
+ sub-make may not pass `prefix=/opt' along). Use the following
+ instead:
+ prefix=/opt $MAKE -e install
Do not send a test case without signing a copyright disclaimer.
See http://sources.redhat.com/automake/contribute.html or
diff --git a/tests/autodist-acconfig.test b/tests/amhello-binpkg.test
similarity index 57%
copy from tests/autodist-acconfig.test
copy to tests/amhello-binpkg.test
index 49ab2f0..34600fe 100755
--- a/tests/autodist-acconfig.test
+++ b/tests/amhello-binpkg.test
@@ -14,33 +14,30 @@
# 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 that `acconfig.h' is automatically distributed if it exists
-# (at automake runtime).
-# Related to automake bug#7819.
+# Test an example from the manual about the `amhello' package:
+# using DESTDIR to build simple, no-frills binary packages.
. ./defs || Exit 1
set -e
-cat >> configure.in <<END
-AC_OUTPUT
-END
-
-cat > Makefile.am <<'END'
-.PHONY: test
-test: distdir
- ls -l $(distdir)
- echo ' ' $(DIST_COMMON) ' ' | grep '[ /]acconfig\.h '
- test -f $(distdir)/acconfig.h
-END
+cp "$testsrcdir"/../doc/amhello-1.0.tar.gz . \
+ || fatal_ "cannot get amhello tarball"
-: > acconfig.h
+gzip -dc amhello-1.0.tar.gz | tar xf -
+cd amhello-1.0
-$ACLOCAL
-$AUTOMAKE
-$AUTOCONF
+./configure --prefix /usr
+make
+make DESTDIR="`pwd`/inst" install
+cd inst
+find . -type f -print > ../files.lst
+tar cvf amhello-1.0-i686.tar.gz `cat ../files.lst` > t
+LC_ALL=C sort t > tar.got
-./configure
-$MAKE test
+diff - tar.got <<'END'
+./usr/bin/hello
+./usr/share/doc/amhello/README
+END
:
diff --git a/tests/amhello-cflags.test b/tests/amhello-cflags.test
new file mode 100755
index 0000000..56f7729
--- /dev/null
+++ b/tests/amhello-cflags.test
@@ -0,0 +1,51 @@
+#! /bin/sh
+# Copyright (C) 2011 Free Software Foundation, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+# Test an example from the manual about the `amhello' package:
+# using VPATH builds to configure the same package with different
+# options.
+
+required=gcc
+. ./defs || Exit 1
+
+set -e
+
+cp "$testsrcdir"/../doc/amhello-1.0.tar.gz . \
+ || fatal_ "cannot get amhello tarball"
+
+gzip -dc amhello-1.0.tar.gz | tar xf -
+cd amhello-1.0
+
+mkdir debug optim
+cd debug
+../configure CFLAGS='-g -O0'
+$MAKE
+ls -l . src # For debugging.
+cd ../optim
+../configure CFLAGS='-O3 -fomit-frame-pointer'
+$MAKE
+ls -l . src # For debugging.
+cd ..
+
+# Check that we have really compiled the objects with two different
+# configurations.
+for exeext in '' .exe :; do
+ test -f optim/src/hello$exeext && break
+ test "$exeext" = : && fatal_ "cannot determine extension of executables"
+done
+cmp optim/src/hello$exeext debug/src/hello$exeext && Exit 1
+
+:
diff --git a/tests/amhello-cross-compile.test b/tests/amhello-cross-compile.test
new file mode 100755
index 0000000..6db91ba
--- /dev/null
+++ b/tests/amhello-cross-compile.test
@@ -0,0 +1,54 @@
+#! /bin/sh
+# Copyright (C) 2011 Free Software Foundation, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+# Test an example from the manual about the `amhello' package:
+# cross-compiling a package from Linux/Unix to MinGW.
+
+required=i586-mingw32msvc-gcc
+. ./defs || Exit 1
+
+set -e
+
+cp "$testsrcdir"/../doc/amhello-1.0.tar.gz . \
+ || fatal_ "cannot get amhello tarball"
+
+host=i586-mingw32msvc
+build=`"$testsrcdir"/../lib/config.guess` && test -n "$build" \
+ || fatal_ "cannot guess build platform"
+case $build in *mingw*) skip_ "build system is MinGW too";; esac
+
+gzip -dc amhello-1.0.tar.gz | tar xf -
+cd amhello-1.0
+
+./configure --build "$build" --host "$host" > stdout \
+ || { cat stdout ; Exit 1; }
+cat stdout
+grep '^checking for i586-mingw32msvc-strip\.\.\.' stdout
+grep '^checking for i586-mingw32msvc-gcc\.\.\.' stdout
+grep '^checking for suffix of executables\.\.\. \.exe *$' stdout
+grep '^checking for suffix of object files\.\.\. o *$' stdout
+grep '^checking whether i586-mingw32msvc-gcc accepts -g\.\.\. yes' stdout
+
+$MAKE
+
+cd src
+file hello.exe > whatis
+cat whatis
+$EGREP 'DOS|Win' whatis
+grep 'executable' whatis
+grep 'ELF' whatis && Exit 1
+
+:
diff --git a/tests/ansi.test b/tests/ansi.test
index 7795f48..0aa000e 100755
--- a/tests/ansi.test
+++ b/tests/ansi.test
@@ -42,8 +42,8 @@ END
: > ansi2knr.1
$ACLOCAL
-$AUTOCONF
-$AUTOMAKE
+$AUTOCONF -Wno-obsolete
+$AUTOMAKE -Wno-obsolete
./configure
diff --git a/tests/ansi10.test b/tests/ansi10.test
index 88b8618..4ff2c86 100755
--- a/tests/ansi10.test
+++ b/tests/ansi10.test
@@ -55,8 +55,8 @@ main (int argc, char **argv)
END
$ACLOCAL
-$AUTOCONF
-$AUTOMAKE -a
+$AUTOCONF -Wno-obsolete
+$AUTOMAKE -Wno-obsolete -a
# Sanity check: make sure it's ok to set ac_cv_prog_cc_stdc as we do.
test `grep -c ac_cv_prog_cc_stdc configure` -gt 1
diff --git a/tests/ansi2.test b/tests/ansi2.test
index 77ca2c6..504c8c3 100755
--- a/tests/ansi2.test
+++ b/tests/ansi2.test
@@ -35,6 +35,6 @@ END
: > ansi2knr.1
$ACLOCAL
-$AUTOMAKE
+$AUTOMAKE -Wno-obsolete
grep '^all[-a-z]*:.*ANSI2KNR' Makefile.in
diff --git a/tests/ansi2knr-deprecation.test b/tests/ansi2knr-deprecation.test
new file mode 100755
index 0000000..543d9c6
--- /dev/null
+++ b/tests/ansi2knr-deprecation.test
@@ -0,0 +1,69 @@
+#! /bin/sh
+# Copyright (C) 2011 Free Software Foundation, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+# Check that the use of automatic de-ANSI-fication feature is deprecated.
+# That feature will be removed in the next major Automake release.
+
+. ./defs || Exit 1
+
+set -e
+
+warn_rx='automatic de-ANSI-fication.*deprecated'
+
+cat >> configure.in <<'END'
+AC_PROG_CC
+AM_C_PROTOTYPES
+END
+
+$ACLOCAL
+
+$AUTOCONF -Wall -Werror -Wno-obsolete
+$AUTOCONF -Wnone -Wobsolete -Werror 2>stderr && { cat stderr >&2; Exit 1; }
+cat stderr >&2
+grep "^configure\\.in:5:.* AM_C_PROTOTYPES:.*$warn_rx" stderr
+
+sed '/AM_C_PROTOTYPES/d' configure.in > config.stub
+diff configure.in config.stub && fatal_ "failed to edit configure.in"
+rm -f configure.in
+
+cat > Makefile.stub <<'END'
+ANSI2KNR = :
+U =
+END
+
+for opt in ansi2knr lib/ansi2knr; do
+ # ansi2knr option in Makefile.am
+ cp config.stub configure.in
+ cp Makefile.stub Makefile.am
+ echo "AUTOMAKE_OPTIONS = $opt" >> Makefile.am
+ cat Makefile.am # For debugging.
+ $AUTOMAKE -Wno-obsolete
+ AUTOMAKE_fails
+ grep "^Makefile\.am:3:.*$warn_rx" stderr
+ AUTOMAKE_fails -Wnone -Wobsolete
+ grep "^Makefile\.am:3:.*$warn_rx" stderr
+ # ansi2knr option in configure.in
+ cp Makefile.stub Makefile.am
+ sed "s|^\\(AM_INIT_AUTOMAKE\\).*|\1([$opt])|" config.stub > configure.in
+ cat configure.in # For debugging.
+ $AUTOMAKE -Wno-obsolete
+ AUTOMAKE_fails
+ grep "^configure\.in:2:.*$warn_rx" stderr
+ AUTOMAKE_fails -Wnone -Wobsolete
+ grep "^configure\.in:2:.*$warn_rx" stderr
+done
+
+:
diff --git a/tests/ansi3.test b/tests/ansi3.test
index e1e0c42..22ef485 100755
--- a/tests/ansi3.test
+++ b/tests/ansi3.test
@@ -51,8 +51,8 @@ export CFLAGS
# We use gcc and not gcc -traditional as the latter fails on some
# Linux boxes (Red Hat 5.1 in particular).
$ACLOCAL
-$AUTOCONF
-$AUTOMAKE -a 2>stderr || { cat stderr >&2; Exit 1; }
+$AUTOCONF -Wno-obsolete
+$AUTOMAKE -Wno-obsolete -a 2>stderr || { cat stderr >&2; Exit 1; }
cat stderr >&2
grep 'Makefile.am:1:.*ansi2knr\.c' stderr
CC='gcc' ./configure
diff --git a/tests/ansi3b.test b/tests/ansi3b.test
index ad222ff..0688781 100755
--- a/tests/ansi3b.test
+++ b/tests/ansi3b.test
@@ -52,8 +52,8 @@ export CFLAGS
# We use gcc and not gcc -traditional as the latter fails on some
# Linux boxes (Red Hat 5.1 in particular).
$ACLOCAL
-$AUTOCONF
-$AUTOMAKE -a 2>stderr || { cat stderr >&2; Exit 1; }
+$AUTOCONF -Wno-obsolete
+$AUTOMAKE -Wno-obsolete -a 2>stderr || { cat stderr >&2; Exit 1; }
cat stderr >&2
grep 'configure.in:2:.*ansi2knr\.1' stderr
CC='gcc' ./configure
diff --git a/tests/ansi4.test b/tests/ansi4.test
index 63250a9..0c0d339 100755
--- a/tests/ansi4.test
+++ b/tests/ansi4.test
@@ -37,6 +37,6 @@ END
: > hello.c
$ACLOCAL
-$AUTOMAKE
+$AUTOMAKE -Wno-obsolete
$FGREP 'ansi2knr.$(' Makefile.in
diff --git a/tests/ansi5.test b/tests/ansi5.test
index 2652cb7..d152be0 100755
--- a/tests/ansi5.test
+++ b/tests/ansi5.test
@@ -66,8 +66,8 @@ END
set -e
$ACLOCAL
-$AUTOCONF
-$AUTOMAKE -a
+$AUTOCONF -Wno-obsolete
+$AUTOMAKE -Wno-obsolete -a
# Ignore user CFLAGS.
CFLAGS=
export CFLAGS
diff --git a/tests/ansi6.test b/tests/ansi6.test
index 10196ea..691614d 100755
--- a/tests/ansi6.test
+++ b/tests/ansi6.test
@@ -61,8 +61,8 @@ END
set -e
$ACLOCAL
-$AUTOCONF
-$AUTOMAKE -a
+$AUTOCONF -Wno-obsolete
+$AUTOMAKE -Wno-obsolete -a
# Sanity check: make sure it's ok to set ac_cv_prog_cc_stdc as we do.
test `grep -c ac_cv_prog_cc_stdc configure` -gt 1
diff --git a/tests/ansi7.test b/tests/ansi7.test
index e97f517..9eae26b 100755
--- a/tests/ansi7.test
+++ b/tests/ansi7.test
@@ -63,8 +63,8 @@ END
set -e
$ACLOCAL
-$AUTOCONF
-$AUTOMAKE -a
+$AUTOCONF -Wno-obsolete
+$AUTOMAKE -Wno-obsolete -a
# Sanity check: make sure it's ok to set ac_cv_prog_cc_stdc as we do.
test `grep -c ac_cv_prog_cc_stdc configure` -gt 1
diff --git a/tests/ansi8.test b/tests/ansi8.test
index 33f17dc..bcf99b1 100755
--- a/tests/ansi8.test
+++ b/tests/ansi8.test
@@ -26,5 +26,5 @@ bin_PROGRAMS = hello
END
$ACLOCAL
-AUTOMAKE_fails -a
+AUTOMAKE_fails -Wno-obsolete -a
grep AM_C_PROTOTYPES stderr
diff --git a/tests/ansi9.test b/tests/ansi9.test
index 4eb1820..ab78dda 100755
--- a/tests/ansi9.test
+++ b/tests/ansi9.test
@@ -50,8 +50,8 @@ mkdir sub
cp loadavg.c sub/sub.c
$ACLOCAL
-$AUTOCONF
-$AUTOMAKE --add-missing -Wno-override
+$AUTOCONF -Wno-obsolete
+$AUTOMAKE --add-missing -Wno-override -Wno-obsolete
$FGREP 'loadavg-loadavg$U.o: loadavg$U.c' Makefile.in
# The following rule should not exist, because the
diff --git a/tests/autodist-no-duplicate.test b/tests/autodist-no-duplicate.test
new file mode 100755
index 0000000..81464c0
--- /dev/null
+++ b/tests/autodist-no-duplicate.test
@@ -0,0 +1,52 @@
+#! /bin/sh
+# Copyright (C) 2011 Free Software Foundation, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+# Check that there are no duplicates in the list of files automatically
+# distributed by automake.
+
+. ./defs || Exit 1
+
+set -e
+
+re='Files .*automatically distributed.*if found'
+
+# The automake manual states that the list of automatically-distributed
+# files should be given by `automake --help'.
+
+list1=`$AUTOMAKE --help \
+ | sed -n "/^$re.*always/,/^ *$/p" \
+ | sed 1d`
+list1=`echo $list1`
+
+list2=`$AUTOMAKE --help \
+ | sed -n "/^$re.*under certain conditions/,/^ *$/p" \
+ | sed 1d`
+list2=`echo $list2`
+
+test -n "$list1"
+test -n "$list2"
+
+st=0
+for i in 1 2; do
+ eval list=\${list$i}
+ for f in $list; do echo $f; done | sort > files$i.lst
+ uniq files$i.lst > files$i.uniq
+ cat files$i.lst
+ cat files$i.uniq
+ diff files$i.lst files$i.uniq || st=1
+done
+
+Exit $st
diff --git a/tests/autodist-subdir.test b/tests/autodist-subdir.test
index db694f8..83b293e 100755
--- a/tests/autodist-subdir.test
+++ b/tests/autodist-subdir.test
@@ -39,33 +39,8 @@ $AUTOCONF
# The automake manual states that the list of automatically-distributed
# files should be given by `automake --help'.
list=`$AUTOMAKE --help \
- | sed -n '/^Files .*automatically distributed.*if found/,/^ *$/p' \
+ | sed -n '/^Files.*automatically distributed.*if found.*always/,/^
*$/p' \
| sed 1d`
-list=`for f in $list; do
- case $f in
- configure|configure.in|configure.ac)
- # See test 'autodist-configure-no-subdir.test'.
- ;;
- aclocal.m4)
- # This file should be distributed only when it is a real
- # dependency for configure. Anyway, not a check to be
- # performed in this test.
- ;;
- acconfig.h)
- # Works only when it really exists, not when it is a
- # target in Makefile.am.
- ;;
- stamp-vti)
- # Works only when using info_TEXINFOS and version.texi.
- ;;
- config.h.bot|config.h.top)
- # Works only when the AC_CONFIG_HADERS macro is used.
- ;;
- *)
- echo $f
- ;;
- esac
- done`
# Normalize whitespace, just in case.
list=`echo $list`
diff --git a/tests/autodist.test b/tests/autodist.test
index 34b9526..9294bc3 100755
--- a/tests/autodist.test
+++ b/tests/autodist.test
@@ -25,15 +25,13 @@ set -e
# Ensure we are run from the right directory.
# (The last thing we want is to delete some random user files.)
-test -f ../defs-static
+test -f ../defs
rm -f *
cat > configure.in <<END
AC_INIT([$me], [1.0])
AC_CONFIG_AUX_DIR([.])
AM_INIT_AUTOMAKE
-## Will avoid useless regeneration of aclocal.m4, configure, etc.
-AM_MAINTAINER_MODE
AC_CONFIG_FILES([Makefile])
AC_OUTPUT
END
@@ -44,33 +42,8 @@ $AUTOCONF
# The automake manual states that the list of automatically-distributed
# files should be given by `automake --help'.
list=`$AUTOMAKE --help \
- | sed -n '/^Files .*automatically distributed.*if found/,/^ *$/p' \
+ | sed -n '/^Files.*automatically distributed.*if found.*always/,/^
*$/p' \
| sed 1d`
-list=`for f in $list; do
- case $f in
- configure|configure.in|configure.ac)
- # See test 'autodist-configure-no-subdir.test'.
- ;;
- aclocal.m4)
- # This file should be distributed only when it is a real
- # dependency for configure. Anyway, not a check to be
- # performed in this test.
- ;;
- acconfig.h)
- # Works only when it really exists, not when it is a
- # target in Makefile.am.
- ;;
- stamp-vti)
- # Works only when using info_TEXINFOS and version.texi.
- ;;
- config.h.bot|config.h.top)
- # Works only when the AC_CONFIG_HADERS macro is used.
- ;;
- *)
- echo $f
- ;;
- esac
- done`
# Normalize whitespace, just in case.
list=`echo $list`
diff --git a/tests/check-tests-in-builddir.test
b/tests/check-tests-in-builddir.test
index 2d0e423..b588f11 100755
--- a/tests/check-tests-in-builddir.test
+++ b/tests/check-tests-in-builddir.test
@@ -55,16 +55,27 @@ chmod a+x bar.test
$MAKE check >out 2>&1 || { cat out; Exit1; }
cat out
-grep '\.\./foo' out && Exit 1
-grep '^PASS: foo.test *$' out
+# The simple-tests driver does not strip VPATH components from
+# the name of the test, but the parallel-tests driver should.
+if test x"$parallel_tests" = x"yes"; then
+ grep '\.\./foo' out && Exit 1
+ grep '^PASS: foo.test *$' out
+else
+ grep '^PASS: .*foo.test *$' out
+fi
grep '^PASS: bar.test *$' out
rm -f test-suite.log foo.log bar.log
FOO_EXIT_STATUS=1 $MAKE check >out 2>&1 && { cat out; Exit1; }
cat out
-grep '\.\./foo' out && Exit 1
-grep '^FAIL: foo.test *$' out
+# See comments above.
+if test x"$parallel_tests" = x"yes"; then
+ grep '\.\./foo' out && Exit 1
+ grep '^FAIL: foo.test *$' out
+else
+ grep '^FAIL: .*foo.test *$' out
+fi
grep '^PASS: bar.test *$' out
rm -f test-suite.log foo.log bar.log
diff --git a/tests/cxxansi.test b/tests/cxxansi.test
index 8bbe9b2..9d6fd6e 100755
--- a/tests/cxxansi.test
+++ b/tests/cxxansi.test
@@ -39,7 +39,7 @@ END
: > jane.C
$ACLOCAL
-$AUTOMAKE
+$AUTOMAKE -Wno-obsolete
$FGREP 'jane$U' Makefile.in && Exit 1
$FGREP 'doe$U' Makefile.in
diff --git a/tests/defs.in b/tests/defs.in
index cf07a4e..f5e9e29 100644
--- a/tests/defs.in
+++ b/tests/defs.in
@@ -64,7 +64,25 @@ test -f "$srcdir/defs.in" || {
exit 1
}
-me=`echo "$0" | sed -e 's,.*[\\/],,;s/\.test$//'`
+# The name of the current test (without the `.test' suffix).
+# Test scripts can override it if they need to (but this should
+# be done carefully, and *before* including ./defs).
+if test -z "$me"; then
+ me=`echo "$0" | sed -e 's,.*[\\/],,;s/\.test$//'`
+elif env | grep '^me=' >/dev/null; then
+ echo "$0: variable \`me' is set in the environment: this is unsafe" >&2
+ exit 99
+fi
+
+# Check that the environment is properly sanitized.
+for var in required parallel_tests; do
+ if env | grep "^$var=" >/dev/null; then
+ echo "$me: variable \`$var' is set in the environment:" \
+ "this is unsafe" >&2
+ exit 99
+ fi
+done
+unset var
# This might be used in testcases checking distribution-related features.
# Test scripts are free to override this if they need to.
@@ -80,8 +98,10 @@ export SHELL
test -z "$PERL" && PERL='@PERL@'
test -z "$MAKE" && MAKE=make
test -z "$AUTOCONF" && AUTOCONF="@am_AUTOCONF@"
+test -z "$AUTOM4TE" && AUTOM4TE="@am_AUTOM4TE@"
+test -z "$AUTORECONF" && AUTORECONF="@am_AUTORECONF@"
test -z "$AUTOHEADER" && AUTOHEADER="@am_AUTOHEADER@"
-test -z "$AUTOUPDATE" && AUTOUPDATE=autoupdate
+test -z "$AUTOUPDATE" && AUTOUPDATE="@am_AUTOUPDATE@"
test -z "$MISSING" && MISSING=`pwd`/../lib/missing
# Use -Werror because this also turns some Perl warnings into error.
# (Tests for which this is inappropriate should use -Wno-error.)
@@ -104,18 +124,72 @@ echo "$PATH"
# (See note about `export' in the Autoconf manual.)
export PATH
+# We use a trap below for cleanup. This requires us to go through
+# hoops to get the right exit status transported through the signal.
+# So use `Exit STATUS' instead of `exit STATUS' inside of the tests.
+# Turn off errexit here so that we don't trip the bug with OSF1/Tru64
+# sh inside this function.
+Exit ()
+{
+ set +e
+ (exit $1)
+ exit $1
+}
+
+# Print warnings (e.g., about skipped and failed tests) to this file
+# number. Override by putting, say:
+# stderr_fileno_=9; export stderr_fileno_; exec 9>&2;
+# in the definition of AM_TESTS_ENVIRONMENT.
+# This is useful when using automake's parallel tests mode, to print the
+# reason for skip/failure to console, rather than to the *.log files.
+: ${stderr_fileno_=2}
+
+# Copied from Gnulib's `tests/init.sh'.
+warn_ () { echo "$@" 1>&$stderr_fileno_; }
+fail_ () { warn_ "$me: failed test: $@"; Exit 1; }
+skip_ () { warn_ "$me: skipped test: $@"; Exit 77; }
+fatal_ () { warn_ "$me: hard error: $@"; Exit 99; }
+framework_failure_ () { warn_ "$me: set-up failure: $@"; Exit 99; }
+
+# cross_compiling
+# ---------------
+# Tell whether we are cross-compiling. This is especially useful to skip
+# tests (or portions of them) that requires a native compiler.
+cross_compiling ()
+{
+ test x"$host_alias" != x
+}
+
+# So that we can force the use of correct gcc, g++ etc., consistently
+# with cross-compilation settings.
+if cross_compiling; then
+ am__tool_prefix="$host_alias-"
+else
+ am__tool_prefix=
+fi
+
for tool in : $required
do
# Check that each required tool is present.
case $tool in
:) ;;
- bison)
+ bison|yacc)
# Since bison is required, we pick YACC for ./configure.
YACC='bison -y'
export YACC
echo "$me: running bison --version"
( bison --version ) || exit 77
;;
+ flex|lex)
+ # Since flex is required, we pick LEX for ./configure.
+ LEX=flex
+ export LEX
+ echo "$me: running flex --version"
+ flex --version || exit 77
+ ;;
+ cc|c++|fortran|fortran77)
+ echo "$me: dummy requirement '$tool', no check done"
+ ;;
bzip2)
# Do not use --version, bzip2 still tries to compress stdin.
echo "$me: running bzip2 --help"
@@ -141,24 +215,48 @@ do
# always use it. This is important only when the user
# has defined CC in his environment, otherwise ./configure will
# prefer gcc to other compilers.
- CC=gcc
+ CC=${am__tool_prefix}gcc
export CC
echo "$me: running $CC --version"
( $CC --version ) || exit 77
;;
gcj)
- GCJ=gcj
+ GCJ=${am__tool_prefix}gcj
export GCJ
echo "$me: running $GCJ --version"
( $GCJ --version ) || exit 77
( $GCJ -v ) || exit 77
;;
g++)
- CXX=g++
+ CXX=${am__tool_prefix}g++
export CXX
echo "$me: running $CXX --version"
( $CXX --version ) || exit 77
;;
+ gfortran)
+ FC=${am__tool_prefix}gfortran
+ export FC
+ echo "$me: running $FC --version"
+ $FC --version || skip_ "GNU Fortran compiler not available"
+ echo "$me: running $FC -v"
+ $FC -v || skip_ "botched installation for GNU Fortran compiler"
+ case " $required " in
+ *\ g77\ *) ;;
+ *) F77=$FC; export F77;;
+ esac
+ ;;
+ g77)
+ F77=${am__tool_prefix}g77
+ export F77
+ echo "$me: running $F77 --version"
+ $F77 --version || skip_ "GNU Fortran 77 compiler not available"
+ echo "$me: running $F77 -v"
+ $F77 -v || skip_ "botched installation for GNU Fortran 77 compiler"
+ case " $required " in
+ *\ gfortran\ *) ;;
+ *) FC=$F77; export FC;;
+ esac
+ ;;
icc)
CC=icc
export CC
@@ -197,6 +295,9 @@ do
rm -f $priv_check_temp
test $overwrite_status = 0 && exit 77
;;
+ native)
+ cross_compiling && skip_ "doesn't work in cross-compile mode"
+ ;;
python)
# Python doesn't support --version, it has -V
echo "$me: running python -V"
@@ -260,18 +361,6 @@ case "$srcdir" in
;;
esac
-# We use a trap below for cleanup. This requires us to go through
-# hoops to get the right exit status transported through the signal.
-# So use `Exit STATUS' instead of `exit STATUS' inside of the tests.
-# Turn off errexit here so that we don't trip the bug with OSF1/Tru64
-# sh inside this function.
-Exit ()
-{
- set +e
- (exit $1)
- exit $1
-}
-
curdir=`pwd`
testSubDir=$me.dir
test ! -d $testSubDir || {
@@ -337,6 +426,8 @@ unset DESTDIR
unset prefix exec_prefix bindir datarootdir datadir docdir dvidir
unset htmldir includedir infodir libdir libexecdir localedir mandir
unset oldincludedir pdfdir psdir sbindir sharedstatedir sysconfdir
+# Unset variables that might change the "make distcheck" behaviour.
+unset DISTCHECK_CONFIGURE_FLAGS AM_DISTCHECK_CONFIGURE_FLAGS
# Also unset variables that control our test driver. While not
# conceptually independent, they cause some changed semantics we
# need to control (and test for) in some of the tests to ensure
@@ -427,6 +518,16 @@ is_newest ()
test -z "$is_newest_files"
}
+# using_gmake
+# -----------
+# Return success if $MAKE is GNU make, return failure otherwise.
+using_gmake ()
+{
+ # Use --version AND -v, because SGI Make doesn't fail on --version.
+ # Also grep for GNU because newer versions of FreeBSD make do
+ # not complain about `--version' (they seem to silently ignore it).
+ $MAKE --version -v | grep GNU
+}
# AUTOMAKE_run status [options...]
# --------------------------------
@@ -480,6 +581,7 @@ unindent ()
fi
sed "$sed_unindent_prog" ${1+"$@"}
}
+sed_unindent_prog="" # Avoid interferences from the environment.
# Turn on shell traces.
set -x
diff --git a/tests/depcomp8a.test b/tests/depcomp8a.test
index b4a0e3a..ea14c3f 100755
--- a/tests/depcomp8a.test
+++ b/tests/depcomp8a.test
@@ -1,5 +1,5 @@
#! /bin/sh
-# Copyright (C) 2010 Free Software Foundation, Inc.
+# Copyright (C) 2010, 2011 Free Software Foundation, Inc.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -35,7 +35,7 @@ END
mkdir sub
cat > foo.c << 'END'
-int main(void)
+int main (void)
{
extern int bar;
return bar;
@@ -53,10 +53,11 @@ grep 'include.*\./\$(DEPDIR)/bar\.P' Makefile.in
grep 'include.*/\./\$(DEPDIR)' Makefile.in && Exit 1
$AUTOCONF
-./configure
+# Don't reject slower dependency extractors, for better coverage.
+./configure --enable-dependency-tracking
$MAKE
./zardoz
-$MAKE distcheck
+DISTCHECK_CONFIGURE_FLAGS='--enable-dependency-tracking' $MAKE distcheck
# Try again with subdir-objects option.
@@ -71,9 +72,10 @@ grep 'include.*[^a-zA-Z0-9_/]sub/\$(DEPDIR)/bar\.P'
Makefile.in
$EGREP 'include.*/(\.|sub)/\$\(DEPDIR\)' Makefile.in && Exit 1
$AUTOCONF
-./configure
+# Don't reject slower dependency extractors, for better coverage.
+./configure --enable-dependency-tracking
$MAKE
./zardoz
-$MAKE distcheck
+DISTCHECK_CONFIGURE_FLAGS='--enable-dependency-tracking' $MAKE distcheck
:
diff --git a/tests/depcomp8b.test b/tests/depcomp8b.test
index 1ae7459..d36e754 100755
--- a/tests/depcomp8b.test
+++ b/tests/depcomp8b.test
@@ -1,5 +1,5 @@
#! /bin/sh
-# Copyright (C) 2010 Free Software Foundation, Inc.
+# Copyright (C) 2010, 2011 Free Software Foundation, Inc.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -49,9 +49,10 @@ grep 'include.*\./\$(DEPDIR)/bar\.P' Makefile.in
grep 'include.*/\./\$(DEPDIR)' Makefile.in && Exit 1
$AUTOCONF
-./configure
+# Don't reject slower dependency extractors, for better coverage.
+./configure --enable-dependency-tracking
$MAKE
-$MAKE distcheck
+DISTCHECK_CONFIGURE_FLAGS='--enable-dependency-tracking' $MAKE distcheck
# Try again with subdir-objects option.
@@ -66,8 +67,9 @@ grep 'include.*[^a-zA-Z0-9_/]sub/\$(DEPDIR)/bar\.P'
Makefile.in
$EGREP 'include.*/(\.|sub)/\$\(DEPDIR\)' Makefile.in && Exit 1
$AUTOCONF
-./configure
+# Don't reject slower dependency extractors, for better coverage.
+./configure --enable-dependency-tracking
$MAKE
-$MAKE distcheck
+DISTCHECK_CONFIGURE_FLAGS='--enable-dependency-tracking' $MAKE distcheck
:
diff --git a/tests/distcheck-configure-flags-am.test
b/tests/distcheck-configure-flags-am.test
new file mode 100755
index 0000000..a5cab6a
--- /dev/null
+++ b/tests/distcheck-configure-flags-am.test
@@ -0,0 +1,68 @@
+#! /bin/sh
+# Copyright (C) 2011 Free Software Foundation, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+# Check support for AM_DISTCHECK_CONFIGURE_FLAGS at "make distcheck"
+# time, and its interactions with DISTCHECK_CONFIGURE_FLAGS.
+
+. ./defs || Exit 1
+
+set -e
+
+cat >> configure.in << 'END'
+AC_ARG_ENABLE([success], [], [success=$enableval], [success=no])
+AS_IF([test $success = yes && test "$sentence" = 'it works :-)'],
+ [:],
+ [AC_MSG_ERROR([success='$success', sentence='$sentence'])])
+AC_OUTPUT
+END
+
+unset sentence || :
+
+cat > Makefile.am << 'END'
+AM_DISTCHECK_CONFIGURE_FLAGS = --enable-success sentence='it works :-)'
+END
+
+$ACLOCAL
+$AUTOMAKE
+$FGREP '$(DISTCHECK_CONFIGURE_FLAGS)' Makefile.in
+$FGREP '$(AM_DISTCHECK_CONFIGURE_FLAGS)' Makefile.in
+grep 'DISTCHECK_CONFIGURE_FLAGS.*AM_DISTCHECK_CONFIGURE_FLAGS' Makefile.in \
+ && Exit 1
+
+$AUTOCONF
+./configure --enable-success sentence='it works :-)'
+
+# The configure call in "make distcheck" should honour
+# $(AM_DISTCHECK_CONFIGURE_FLAGS).
+
+$MAKE distcheck
+
+# $(DISTCHECK_CONFIGURE_FLAGS) takes precedence over
+# $(AM_DISTCHECK_CONFIGURE_FLAGS)
+
+cat >> Makefile.am << 'END'
+AM_DISTCHECK_CONFIGURE_FLAGS += --disable-success
+END
+$AUTOMAKE Makefile
+./config.status Makefile
+
+$MAKE distcheck >output 2>&1 && { cat output; Exit 1; }
+cat output
+grep "^configure:.* success='no', sentence='it works :-)'" output
+
+$MAKE distcheck DISTCHECK_CONFIGURE_FLAGS="--enable-success=yes"
+
+:
diff --git a/tests/distcheck-configure-flags-subpkg.test
b/tests/distcheck-configure-flags-subpkg.test
new file mode 100755
index 0000000..695b47c
--- /dev/null
+++ b/tests/distcheck-configure-flags-subpkg.test
@@ -0,0 +1,83 @@
+#! /bin/sh
+# Copyright (C) 2011 Free Software Foundation, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+# Check AM_DISTCHECK_CONFIGURE_FLAGS and DISTCHECK_CONFIGURE_FLAGS
+# are not honored in a subpackage Makefile.am, but the flags from
+# AM_DISTCHECK_CONFIGURE_FLAGS and DISTCHECK_CONFIGURE_FLAGS are
+# passed down to the configure script of the subpackage. This is
+# explicitly documented in the manual.
+
+. ./defs || Exit 1
+
+set -e
+
+cat >> configure.in << 'END'
+AC_CONFIG_SUBDIRS([subpkg])
+if test $dc != ok || test $am_dc != ok; then
+ AC_MSG_ERROR([dc=$dc am_dc=$dc])
+fi
+AC_OUTPUT
+END
+
+mkdir subpkg
+
+sed <configure.in >subpkg/configure.in \
+ -e 's/^AC_INIT.*/AC_INIT([subpkg], [2.0])/' \
+ -e '/^AC_CONFIG_SUBDIRS/d' \
+
+cat configure.in
+cat subpkg/configure.in
+
+dc=KO am_dc=KO; export dc am_dc
+
+cat > Makefile.am << 'END'
+AM_DISTCHECK_CONFIGURE_FLAGS = am_dc=ok
+DISTCHECK_CONFIGURE_FLAGS = dc=ok
+END
+
+: > subpkg/Makefile.am
+
+$ACLOCAL
+$AUTOMAKE
+$AUTOCONF
+
+cd subpkg
+$ACLOCAL
+$AUTOMAKE
+$AUTOCONF
+cd ..
+
+# For debugging.
+$FGREP 'DISTCHECK_CONFIGURE_FLAGS' Makefile.in subpkg/Makefile.in
+
+grep '^AM_DISTCHECK_CONFIGURE_FLAGS =' Makefile.in
+grep '^DISTCHECK_CONFIGURE_FLAGS =' Makefile.in
+$EGREP '^(AM_)?DISTCHECK_CONFIGURE_FLAGS' subpkg/Makefile.in && Exit 1
+
+./configure dc=ok am_dc=ok
+
+# Flags in $(DISTCHECK_CONFIGURE_FLAGS) and $(AM_DISTCHECK_CONFIGURE_FLAGS)
+# should be passed down to the subpackage configure when "make distcheck"
+# is run from the top-level package ...
+$MAKE distcheck
+
+# ... but not when "make distcheck" is run from the subpackage.
+cd subpkg
+$MAKE distcheck >output 2>&1 && { cat output; Exit 1; }
+cat output
+grep '^configure:.* dc=KO am_dc=KO' output
+
+:
diff --git a/tests/distcheck-configure-flags.test
b/tests/distcheck-configure-flags.test
new file mode 100755
index 0000000..117d83c
--- /dev/null
+++ b/tests/distcheck-configure-flags.test
@@ -0,0 +1,56 @@
+#! /bin/sh
+# Copyright (C) 2011 Free Software Foundation, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+# Check support for DISTCHECK_CONFIGURE_FLAGS at "make distcheck" time.
+
+. ./defs || Exit 1
+
+set -e
+
+cat >> configure.in << 'END'
+AC_ARG_ENABLE([success], [], [success=$enableval], [success=no])
+AS_IF([test $success = yes && test "$sentence" = 'it works :-)'],
+ [:],
+ [AC_MSG_ERROR([success='$success', sentence='$sentence'])])
+AC_OUTPUT
+END
+
+unset sentence || :
+
+: > Makefile.am
+
+$ACLOCAL
+$AUTOMAKE
+$FGREP '$(DISTCHECK_CONFIGURE_FLAGS)' Makefile.in
+
+$AUTOCONF
+./configure --enable-success sentence='it works :-)'
+
+# It should be ok to define DISTCHECK_CONFIGURE_FLAGS either on the
+# make command line or in the environment.
+
+env DISTCHECK_CONFIGURE_FLAGS='--enable-success sentence=it\ works\ :-\)' \
+ $MAKE distcheck # Not `make -e' here, deliberately.
+
+$MAKE distcheck \
+ DISTCHECK_CONFIGURE_FLAGS="--enable-success=yes sentence='it works :-)'"
+
+# Sanity check.
+$MAKE distcheck >output 2>&1 && { cat output; Exit 1; }
+cat output
+grep "^configure:.* success='no', sentence=''" output
+
+:
diff --git a/tests/autodist-acconfig.test b/tests/distcheck-hook.test
similarity index 64%
copy from tests/autodist-acconfig.test
copy to tests/distcheck-hook.test
index 49ab2f0..9a2c384 100755
--- a/tests/autodist-acconfig.test
+++ b/tests/distcheck-hook.test
@@ -14,33 +14,40 @@
# 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 that `acconfig.h' is automatically distributed if it exists
-# (at automake runtime).
-# Related to automake bug#7819.
+# Check basic support for distcheck-hook.
. ./defs || Exit 1
set -e
-cat >> configure.in <<END
+cat >> configure.in << 'END'
AC_OUTPUT
END
cat > Makefile.am <<'END'
-.PHONY: test
-test: distdir
+distcheck-hook:
ls -l $(distdir)
- echo ' ' $(DIST_COMMON) ' ' | grep '[ /]acconfig\.h '
- test -f $(distdir)/acconfig.h
+ chmod u+w $(distdir)
+ : > $(distdir)/dc-hook-has-run
+ chmod a-w $(distdir)
+check-local:
+ ls -l $(srcdir)
+ test -f $(srcdir)/dc-hook-has-run
END
-: > acconfig.h
-
$ACLOCAL
$AUTOMAKE
-$AUTOCONF
+$FGREP 'distcheck-hook' Makefile.in
+$FGREP '$(MAKE) $(AM_MAKEFLAGS) distcheck-hook' Makefile.in
+grep '^distcheck-hook:' Makefile.in
+$AUTOCONF
./configure
-$MAKE test
+
+$MAKE
+$MAKE check && Exit 1
+$MAKE distdir
+test -f $distdir/dc-hook-has-run && Exit 1
+$MAKE distcheck
:
diff --git a/tests/subpkg3.test b/tests/distcheck-hook2.test
similarity index 51%
copy from tests/subpkg3.test
copy to tests/distcheck-hook2.test
index d57ee37..befc1d6 100755
--- a/tests/subpkg3.test
+++ b/tests/distcheck-hook2.test
@@ -1,5 +1,5 @@
#! /bin/sh
-# Copyright (C) 2006 Free Software Foundation, Inc.
+# Copyright (C) 2011 Free Software Foundation, Inc.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -14,44 +14,68 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
-# make sure different subpackages may share files and directories.
+# Check that no 'distcheck-hook' target is created automatically by
+# Automake, and that a used-defined 'distcheck-hook' is *not* honored
+# in a subpackage Makefile.am.
. ./defs || Exit 1
set -e
-cat >Makefile.am <<'END'
-SUBDIRS = subpkg
-EXTRA_DIST = subpkg/foobar
-END
-
-cat >>configure.in <<'END'
+cat >> configure.in << 'END'
AC_CONFIG_SUBDIRS([subpkg])
AC_OUTPUT
END
mkdir subpkg
-echo foobar >subpkg/foobar
-
-echo SUBDIRS = >subpkg/Makefile.am
-
-cat >subpkg/configure.in <<'END'
+cat > subpkg/configure.in << 'END'
AC_INIT([subpkg], [1.0])
AM_INIT_AUTOMAKE
AC_CONFIG_FILES([Makefile])
AC_OUTPUT
END
+cat > Makefile.am <<'END'
+distcheck-hook:
+ ls -l $(distdir)
+ chmod u+w $(distdir)
+ : > $(distdir)/dc-hook-has-run
+ chmod a-w $(distdir)
+check-local:
+ ls -l $(srcdir)
+ test -f $(srcdir)/dc-hook-has-run
+END
+
+cat > subpkg/Makefile.am <<'END'
+check-local:
+ ls -l $(srcdir)
+ test ! -r $(srcdir)/dc-hook-has-run
+END
+
$ACLOCAL
$AUTOMAKE
$AUTOCONF
-
cd subpkg
$ACLOCAL
$AUTOMAKE
$AUTOCONF
cd ..
+# For debugging.
+$FGREP 'distcheck-hook' Makefile.in subpkg/Makefile.in
+
+$FGREP 'distcheck-hook' subpkg/Makefile.in && Exit 1
+$FGREP '$(MAKE) $(AM_MAKEFLAGS) distcheck-hook' Makefile.in
+grep '^distcheck-hook:' Makefile.in
+
./configure
+
+$MAKE
+$MAKE check && Exit 1
+cd subpkg
+$MAKE check
+cd ..
$MAKE distcheck
+
+:
diff --git a/tests/gen-parallel-tests b/tests/gen-parallel-tests
index 39f5d1e..451fb77 100755
--- a/tests/gen-parallel-tests
+++ b/tests/gen-parallel-tests
@@ -19,6 +19,14 @@
# For each test in the TESTS list in this Makefile.am file, that itself
# tests features of the TESTS automake interface, generate a sibling
# test that does likewise, but with the option `parallel-tests' enabled.
+# Individual tests can prevent the creation of such a sibling by
+# explicitly setting the `$parallel_tests' variable to either "yes" or
+# "no". The rationale for this is that if the variable is set to "yes",
+# the test already uses the `parallel-tests' option, so that a sibling
+# would be just a duplicate; while if the variable is set to "no", the
+# test doesn't support, or is not meant to run with, the `parallel-tests'
+# option, and forcing it to do so in the sibling would likely cause a
+# spurious failure.
set -e
@@ -31,8 +39,7 @@ grep -v '.-p\.test' |
LC_ALL=C sort -u |
while read tst; do
if grep '^[^#]*parallel-tests' $tst >/dev/null \
- || grep "parallel_tests=yes" $tst >/dev/null \
- || grep "parallel_tests=['\"]yes" $tst >/dev/null
+ || grep "parallel_tests=" $tst >/dev/null
then :; else echo $tst; fi;
done |
{
diff --git a/tests/interp.test b/tests/interp.test
index af82e33..05464d2 100755
--- a/tests/interp.test
+++ b/tests/interp.test
@@ -18,17 +18,23 @@
. ./defs || Exit 1
+set -e
+
cat >> configure.in << 'END'
AC_PROG_CC
END
cat > Makefile.am << 'END'
-bin_PROGRAMS = qqq
-s1 = z.c
-qqq_SOURCES = $(s1)
+bin_PROGRAMS = foo
+xs = a.c b.c
+foo_SOURCES = c.c $(xs)
END
-$ACLOCAL || Exit 1
-$AUTOMAKE || Exit 1
+$ACLOCAL
+$AUTOMAKE
+
+$FGREP ' a.$(OBJEXT)' Makefile.in
+$FGREP ' b.$(OBJEXT)' Makefile.in
+$FGREP ' c.$(OBJEXT)' Makefile.in
-$FGREP 'z.$(OBJEXT)' Makefile.in
+:
diff --git a/tests/java3.test b/tests/java3.test
index 7895769..e1850a8 100755
--- a/tests/java3.test
+++ b/tests/java3.test
@@ -1,5 +1,5 @@
#! /bin/sh
-# Copyright (C) 2004 Free Software Foundation, Inc.
+# Copyright (C) 2004, 2011 Free Software Foundation, Inc.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -14,8 +14,8 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
-# Make sure that Java rules don't attempt to install *.java files when
-# there are none.
+# Make sure that Java rules don't attempt to compile or install
+# *.java files when there are none.
# Report from Johannes Nicolai (PR/441).
. ./defs || Exit 1
@@ -23,7 +23,7 @@
set -e
cat >> configure.in << 'END'
-AM_CONDITIONAL([WHO_CARES], false)
+AM_CONDITIONAL([WHO_CARES], [false])
AC_OUTPUT
END
@@ -32,13 +32,25 @@ if WHO_CARES
JAVA_FILES = MyClass1.java
endif
-dist_pkgdata_JAVA = $(JAVA_FILES)
+javadir = $(prefix)/java
+java_JAVA = $(JAVA_FILES)
END
-: >MyClass1.java
+cat > MyClass1.java << 'END'
+class MyClass1 { // Deliberately missing right curly bracket.
+END
$ACLOCAL
$AUTOCONF
$AUTOMAKE
-./configure
+
+cwd=`pwd` || Exit 1
+./configure --prefix="$cwd/_inst"
+$MAKE
+$MAKE install
+ls -l . _inst/java # For debugging.
+find . -name '*.class' | grep . && Exit 1
+$MAKE uninstall
$MAKE distcheck
+
+:
diff --git a/tests/libobj8.test b/tests/libobj8.test
index c06746b..206bca6 100755
--- a/tests/libobj8.test
+++ b/tests/libobj8.test
@@ -45,6 +45,6 @@ END
: > ansi2knr.c
$ACLOCAL || Exit 1
-$AUTOMAKE || Exit 1
+$AUTOMAKE -Wno-obsolete || Exit 1
grep 'strsignal_.c:' Makefile.in
diff --git a/tests/maintclean-vpath.test b/tests/maintclean-vpath.test
index 8dd2a95..4b93ab1 100755
--- a/tests/maintclean-vpath.test
+++ b/tests/maintclean-vpath.test
@@ -15,7 +15,7 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
# Make sure distclean and maintainer-clean erase the right files.
-# This test is for VPATH builds; see sister test `maintclean-vpath.test'
+# This test is for VPATH builds; see sister test `maintclean.test'
# for in-tree builds.
. ./defs || Exit 1
diff --git a/tests/mclean.test b/tests/mclean.test
deleted file mode 100755
index dcbe818..0000000
--- a/tests/mclean.test
+++ /dev/null
@@ -1,31 +0,0 @@
-#! /bin/sh
-# Copyright (C) 1999, 2001, 2002 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/>.
-
-# Make sure MAINTAINERCLEANFILES works.
-# Report from Paul D. Smith.
-
-. ./defs || Exit 1
-
-cat > Makefile.am << 'END'
-MAINTAINERCLEANFILES = foo
-END
-
-: > FOO
-
-$ACLOCAL || Exit 1
-$AUTOMAKE || Exit 1
-
-grep 'rm -f .*MAINTAINERCLEANFILES' Makefile.in
diff --git a/tests/parallel-tests-harderror.test
b/tests/parallel-tests-harderror.test
new file mode 100755
index 0000000..8680e29
--- /dev/null
+++ b/tests/parallel-tests-harderror.test
@@ -0,0 +1,98 @@
+#! /bin/sh
+# Copyright (C) 2011 Free Software Foundation, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+# Check parallel-tests features: DISABLE_HARD_ERRORS
+
+parallel_tests=yes
+. ./defs || Exit 1
+
+set -e
+
+cat >> configure.in << 'END'
+AC_CONFIG_FILES([sub/Makefile])
+AC_OUTPUT
+END
+
+mkdir sub
+
+cat > Makefile.am << 'END'
+SUBDIRS = . sub
+TESTS = foo.test
+XFAIL_TESTS = foo.test
+EXTRA_DIST = $(TESTS)
+END
+
+cat > sub/Makefile.am << 'END'
+TESTS = bar.test
+XFAIL_TESTS = $(TESTS)
+EXTRA_DIST = $(TESTS)
+END
+
+cat > foo.test <<'END'
+#! /bin/sh
+exit 99
+END
+chmod a+x foo.test
+cp foo.test sub/bar.test
+
+$ACLOCAL
+$AUTOCONF
+$AUTOMAKE -a
+
+./configure
+
+# DISABLE_HARD_ERRORS is not defined as a make variable, so that it
+# should be possible to define either from the environment or from
+# command-line, also when recursive make invocations are involved,
+# and also without using the `-e' make flag; this should work also
+# for non-GNU make. Moreover, it shouldn't be necessary to define
+# DISABLE_HARD_ERRORS to "yes" to really disable hard errors: any
+# non-empty value should do.
+$MAKE check DISABLE_HARD_ERRORS=yes
+DISABLE_HARD_ERRORS=x $MAKE check
+
+# But an empty values for DISABLE_HARD_ERRORS means that hard errors
+# are not to be counted like normal failures.
+
+$MAKE check DISABLE_HARD_ERRORS='' && Exit 1
+cat test-suite.log
+grep '^FAIL: foo\.test .*exit.*99' test-suite.log
+
+cd sub
+# The `-e' is wanted here.
+DISABLE_HARD_ERRORS='' $MAKE -e check && Exit 1
+cat test-suite.log
+grep '^FAIL: bar\.test .*exit.*99' test-suite.log
+cd ..
+
+# Check the distributions.
+$MAKE DISABLE_HARD_ERRORS=y distcheck
+
+# Finally, DISABLE_HARD_ERRORS should work also when the developer
+# sets it directly in Makefile.am or Makefile. And its effects
+# should remain local to that specific Makefile, obviously.
+
+echo 'DISABLE_HARD_ERRORS = yes' >> Makefile.am
+$AUTOMAKE Makefile
+./config.status Makefile
+VERBOSE=yes $MAKE check && Exit 1
+grep '^FAIL' test-suite.log && Exit 1
+grep '^FAIL: bar\.test .*exit.*99' sub/test-suite.log
+
+echo 'DISABLE_HARD_ERRORS = zardoz' >> sub/Makefile
+VERBOSE=yes $MAKE check
+
+:
diff --git a/tests/parallel-tests-log-compiler-example.test
b/tests/parallel-tests-log-compiler-example.test
new file mode 100755
index 0000000..746c128
--- /dev/null
+++ b/tests/parallel-tests-log-compiler-example.test
@@ -0,0 +1,71 @@
+#! /bin/sh
+# Copyright (C) 2011 Free Software Foundation, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+# Test the example of usage of generic and extension-specific
+# LOG_COMPILER and LOG_FLAGS given in the manual.
+
+parallel_tests=yes
+required=python
+. ./defs || Exit 1
+
+set -e
+
+cat >> configure.in <<END
+AC_SUBST([PERL], ['$PERL'])
+AM_PATH_PYTHON
+AC_OUTPUT
+END
+
+cat > Makefile.am << 'END'
+TESTS = foo.pl bar.py baz
+TEST_EXTENSIONS = .pl .py
+PL_LOG_COMPILER = $(PERL)
+AM_PL_LOG_FLAGS = -w
+PY_LOG_COMPILER = $(PYTHON)
+AM_PY_LOG_FLAGS = -v
+LOG_COMPILER = ./wrapper-script
+AM_LOG_FLAGS = -d
+END
+
+echo 'my $a =+ 2; exit (0);' > foo.pl
+echo 'import sys; sys.exit(0);' > bar.py
+: > baz
+
+cat > wrapper-script <<'END'
+#!/bin/sh
+echo "wrapper args: $*"
+END
+chmod a+x wrapper-script
+
+$ACLOCAL
+$AUTOCONF
+$AUTOMAKE -a
+
+./configure
+
+st=0
+$MAKE check || st=$?
+cat foo.log
+cat bar.log
+cat baz.log
+test $st -eq 0 || Exit $st
+
+# Check that the wrappers have been run with the expected flags.
+grep '[rR]eversed.*+=.*operator.*foo\.pl' foo.log
+grep '^# *[cC]lear.*sys\.argv' bar.log
+grep '^wrapper args:.* -d .*baz' baz.log
+
+:
diff --git a/tests/parallel-tests-log-override-1.test
b/tests/parallel-tests-log-override-1.test
new file mode 100755
index 0000000..6e98380
--- /dev/null
+++ b/tests/parallel-tests-log-override-1.test
@@ -0,0 +1,112 @@
+#! /bin/sh
+# Copyright (C) 2011 Free Software Foundation, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+# Check parallel-tests features: runtime redefinition of $(TEST_SUITE_LOG).
+
+parallel_tests=yes
+. ./defs || Exit 1
+
+set -e
+
+cat >> configure.in <<'END'
+AC_OUTPUT
+END
+
+cat > Makefile.am <<'END'
+TESTS = pass.test skip.test xfail.test
+XFAIL_TESTS = xfail.test
+EXTRA_DIST = $(TESTS)
+END
+
+cat > pass.test <<'END'
+#! /bin/sh
+exit 0
+END
+
+cat > skip.test <<'END'
+#! /bin/sh
+echo "% test skipped %"
+exit 77
+END
+
+cat > xfail.test <<'END'
+#! /bin/sh
+echo "# expected failure #"
+exit 1
+END
+
+chmod a+x *.test
+
+test_log_edit ()
+{
+ sed -e "s|^ *$me 1\.0:.*$| $me 1.0: ???|" \
+ -e "s|^=====*|=======================|" $*
+}
+
+test_log_expected ()
+{
+ test_log_edit orig > exp
+ test_log_edit $1 > got
+ diff exp got || Exit 1
+ rm -f exp got
+}
+
+$ACLOCAL
+$AUTOCONF
+$AUTOMAKE -a
+
+./configure
+
+$MAKE check
+ls -l
+cat test-suite.log
+cp test-suite.log orig
+
+$MAKE clean
+test -f test-suite.log && Exit 99 # Sanity check.
+
+# Check that we can override the testsuite log file at runtime.
+TEST_SUITE_LOG=zardoz.log $MAKE -e check
+ls -l
+test ! -f test-suite.log
+cat zardoz.log
+test_log_expected zardoz.log
+# Sanity check the distribution too (this also does minimal checks on
+# VPATH support).
+TEST_SUITE_LOG=zardoz.log $MAKE -e distcheck
+
+# Check that cleanup rules remove the correct file even when
+# user overrides are in place.
+cp orig test-suite.log
+TEST_SUITE_LOG=zardoz.log $MAKE -e clean
+ls -l
+test ! -f zardoz.log
+diff orig test-suite.log
+
+# Check that the default testsuite log doesn't get unduly modified.
+# Also check that the testsuite log file doesn't need to be named
+# accordingly to the `*.log' pattern.
+chmod a-w test-suite.log
+TEST_SUITE_LOG=TheLogFile $MAKE -e check
+ls -l
+diff orig test-suite.log
+test_log_expected TheLogFile
+TEST_SUITE_LOG=TheLogFile $MAKE -e clean
+ls -l
+test ! -f TheLogFile
+diff orig test-suite.log
+
+:
diff --git a/tests/parallel-tests-log-override-2.test
b/tests/parallel-tests-log-override-2.test
new file mode 100755
index 0000000..649360c
--- /dev/null
+++ b/tests/parallel-tests-log-override-2.test
@@ -0,0 +1,88 @@
+#! /bin/sh
+# Copyright (C) 2011 Free Software Foundation, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+# Check parallel-tests features: runtime redefinition of:
+# - $(TEST_SUITE_LOG) and $(TESTS)
+# - $(TEST_SUITE_LOG) and $(TEST_LOGS)
+
+parallel_tests=yes
+. ./defs || Exit 1
+
+set -e
+
+cat >> configure.in <<'END'
+AC_OUTPUT
+END
+
+cat > Makefile.am <<'END'
+TESTS = pass.test pass2.test skip.test skip2.test fail.test
+END
+
+cat > pass.test <<'END'
+#! /bin/sh
+exit 0
+END
+
+cp pass.test pass2.test
+
+cat > skip.test <<'END'
+#! /bin/sh
+echo "% skipped test %"
+exit 77
+END
+
+cp skip.test skip2.test
+
+cat > fail.test <<'END'
+#! /bin/sh
+exit 1
+END
+
+chmod a+x *.test
+
+$ACLOCAL
+$AUTOCONF
+$AUTOMAKE -a
+
+./configure
+
+for test_list_override in \
+ 'TESTS=pass.test skip.test' \
+ 'TEST_LOGS=pass.log skip.log'
+do
+ env TEST_SUITE_LOG=partial.log "$test_list_override" \
+ $MAKE -e check >stdout || { cat stdout; Exit 1; }
+ cat stdout
+ ls -l
+ cat pass.log
+ cat skip.log
+ cat partial.log
+ test ! -f test-suite.log
+ test ! -f pass2.log
+ test ! -f skip2.log
+ test ! -f fail.log
+ grep '^PASS: .*pass\.test' stdout
+ grep '^SKIP: .*skip\.test' stdout
+ $FGREP 'skip.test' partial.log
+ $FGREP '% skipped test %' partial.log
+ for t in pass2 skip2 fail; do
+ $FGREP "$t.test" stdout && Exit 1
+ $FGREP "$t.test" partial.log && Exit 1
+ done
+ rm -f *.log
+done
+
+:
diff --git a/tests/parallel-tests-log-override-recheck.test
b/tests/parallel-tests-log-override-recheck.test
new file mode 100755
index 0000000..8a50d29
--- /dev/null
+++ b/tests/parallel-tests-log-override-recheck.test
@@ -0,0 +1,92 @@
+#! /bin/sh
+# Copyright (C) 2011 Free Software Foundation, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+# Check parallel-tests features: runtime redefinition of $(TEST_SUITE_LOG)
+# for the recheck target.
+
+parallel_tests=yes
+. ./defs || Exit 1
+
+set -e
+
+cat >> configure.in <<'END'
+AC_OUTPUT
+END
+
+cat > Makefile.am <<'END'
+TESTS = foo.test bar.test baz.test
+END
+
+cat > foo.test <<'END'
+#! /bin/sh
+echo "this is $0"
+exit 0
+END
+
+cat > bar.test <<'END'
+#! /bin/sh
+echo "this is $0"
+exit 99
+END
+
+cat > baz.test <<'END'
+#! /bin/sh
+echo "this is $0"
+exit ${BAZ_EXIT_STATUS-1}
+END
+
+chmod a+x *.test
+
+unset BAZ_EXIT_STATUS || :
+
+$ACLOCAL
+$AUTOCONF
+$AUTOMAKE -a
+
+./configure
+$MAKE check >stdout && { cat stdout; Exit 1; }
+cat stdout
+
+chmod a-rw test-suite.log
+TEST_SUITE_LOG=my.log $MAKE -e recheck >stdout \
+ && { cat stdout; Exit 1; }
+cat stdout
+ls -l
+grep '^2 of 2 .*failed' stdout
+for x in stdout my.log; do
+ $FGREP foo.test $x && Exit 1
+ $FGREP bar.test $x
+ $FGREP baz.test $x
+done
+
+chmod a-rw my.log
+BAZ_EXIT_STATUS=0 TEST_SUITE_LOG=my2.log $MAKE -e recheck >stdout \
+ && { cat stdout; Exit 1; }
+cat stdout
+ls -l
+grep '^1 of 2 .*failed' stdout
+$FGREP foo.test stdout && Exit 1
+$FGREP bar.test stdout
+$FGREP baz.test stdout
+$FGREP foo.test my2.log && Exit 1
+$FGREP bar.test my2.log
+$FGREP baz.test my2.log && Exit 1
+
+chmod u+r test-suite.log my.log
+$FGREP baz.test test-suite.log
+$FGREP baz.test my.log
+
+:
diff --git a/tests/parallel-tests.test b/tests/parallel-tests.test
index 399b23b..54f0cd5 100755
--- a/tests/parallel-tests.test
+++ b/tests/parallel-tests.test
@@ -19,7 +19,6 @@
# - clean
# - TEST_SUITE_LOG
# - dependencies between tests
-# - DISABLE_HARD_ERRORS
# - TESTS
# - TEST_LOGS
# - RECHECK_LOGS
@@ -68,12 +67,13 @@ $AUTOCONF
$AUTOMAKE -a
./configure
-# No hard errors: all tests should be run, there should be one failure.
-env DISABLE_HARD_ERRORS=yes $MAKE -e check >stdout && { cat stdout; Exit 1; }
+
+$MAKE check >stdout && { cat stdout; Exit 1; }
cat stdout
-test `grep -c '^FAIL' stdout` -eq 1
+# There should be two errors: bar.test is a hard error.
+test `grep -c '^FAIL' stdout` -eq 2
test -f mylog.log
-test `grep -c '^FAIL' mylog.log` -eq 1
+test `grep -c '^FAIL' mylog.log` -eq 2
test -f baz.log
test -f bar.log
test -f foo.log
@@ -89,19 +89,11 @@ test ! -f foo.log
test ! -f mylog.log
test -f unrelated.log
-$MAKE clean
-$MAKE check >stdout && { cat stdout; Exit 1; }
-cat stdout
-# Now, there should be two errors: bar.test is a hard error.
-test `grep -c '^FAIL' stdout` -eq 2
-test `grep -c '^FAIL' mylog.log` -eq 2
-
# Check dependencies: baz.test needs to run before bar.test,
# but foo.test is not needed.
# Note that this usage has a problem: the summary will only
# take bar.log into account, because the $(TEST_SUITE_LOG) rule
# does not "see" baz.log. Hmm.
-$MAKE clean
env TESTS='bar.test' $MAKE -e check && Exit 1
test -f baz.log
test -f bar.log
diff --git a/tests/pr401.test b/tests/pr401.test
index b68b5ed..88f7733 100755
--- a/tests/pr401.test
+++ b/tests/pr401.test
@@ -17,6 +17,7 @@
# Check support for AC_CONFIG_LIBOBJ_DIR vs LIBOBJS.
# (pr401b.test and pr401c.test do the same for LTLIBOBJS and ALLOCA)
+parallel_tests=no
required=gcc
. ./defs || Exit 1
diff --git a/tests/pr401b.test b/tests/pr401b.test
index 8e296ef..0af4646 100755
--- a/tests/pr401b.test
+++ b/tests/pr401b.test
@@ -17,6 +17,7 @@
# Check support for AC_CONFIG_LIBOBJ_DIR vs LTLIBOBJS.
# (pr401.test and pr401c.test do the same for LIBOBJS and ALLOCA)
+parallel_tests=no
required='gcc libtoolize'
. ./defs || Exit 1
diff --git a/tests/pr401c.test b/tests/pr401c.test
index 8682dc0..b94bc16 100755
--- a/tests/pr401c.test
+++ b/tests/pr401c.test
@@ -17,6 +17,7 @@
# Check support for AC_CONFIG_LIBOBJ_DIR vs ALLOCA.
# (pr401.test and pr401b.test do the same for LIBOBJS and LTLIBOBJS)
+parallel_tests=no
required=gcc
. ./defs || Exit 1
diff --git a/tests/primary-prefix-couples-documented-valid.test
b/tests/primary-prefix-couples-documented-valid.test
new file mode 100755
index 0000000..645f318
--- /dev/null
+++ b/tests/primary-prefix-couples-documented-valid.test
@@ -0,0 +1,88 @@
+#! /bin/sh
+# Copyright (C) 2011 Free Software Foundation, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+# Check that the "uncommon" prefix/primary combinations used in
+# examples in the Automake manual do not cause obvious errors.
+# Please keep this test in sync with the automake manual.
+
+. ./defs || Exit 1
+
+set -e
+
+cat >> configure.in <<'END'
+AC_PROG_CC
+AC_PROG_RANLIB
+AC_PROG_LIBTOOL
+AM_PROG_GCJ
+AM_PATH_PYTHON
+END
+
+# Fake libtool availability.
+: > ltmain.sh
+cat > acinclude.m4 <<'END'
+AC_DEFUN([AC_PROG_LIBTOOL],
+ [AC_SUBST([LIBTOOL], [:])])
+END
+
+cat > Makefile.am <<'END'
+xmldir = $(datadir)/xml
+xml_DATA = file.xml
+
+data_DATA = file1 file2 file3
+data2dir = $(datadir)
+data2_DATA = file4 file5 file6
+
+aclocaldir = $(datadir)/aclocal
+aclocal_DATA = mymacro.m4 myothermacro.m4
+
+imagesdir = $(pkgdatadir)/images
+soundsdir = $(pkgdatadir)/sounds
+dist_images_DATA = images/vortex.pgm
+dist_sounds_DATA = sounds/whirl.ogg
+
+lisp_DATA = file1.el file2.el
+
+javadir = $(datadir)/java
+dist_java_JAVA = a.java b.java c.java
+
+pkgpython_PYTHON = foo.py
+
+pyexec_LTLIBRARIES = quaternion.la
+quaternion_la_SOURCES = quaternion.c support.c support.h
+quaternion_la_LDFLAGS = -avoid-version -module
+
+myexecbindir = /exec
+myexecbin_PROGRAMS = zardoz
+
+foodir = $(prefix)/foo
+barexecdir = $(prefix)/bar/binaries
+foo_SCRIPTS = foo.sh
+barexec_SCRIPTS = quux.pl
+
+my_execbindir = $(pkglibdir)
+my_doclibdir = $(docdir)
+my_execbin_PROGRAMS = foo
+my_doclib_LIBRARIES = libquux.a
+END
+
+$ACLOCAL
+
+# Both these two invocations are meant.
+# They exercise both code paths concerning auxiliary files.
+$AUTOMAKE -a
+$AUTOMAKE
+
+:
diff --git a/tests/primary-prefix-couples-force-valid.test
b/tests/primary-prefix-couples-force-valid.test
new file mode 100755
index 0000000..315ee4e
--- /dev/null
+++ b/tests/primary-prefix-couples-force-valid.test
@@ -0,0 +1,88 @@
+#! /bin/sh
+# Copyright (C) 2011 Free Software Foundation, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+# Check that a user who wants to use an invalid prefix/primary
+# combination can do so with a proper workaround.
+# For example, this:
+# lib_PROGRAMS = foo
+# is expected to cause an automake error, but this:
+# bardir = $(libdir)
+# bar_PROGRAMS = foo
+# should work.
+
+required=cc
+. ./defs || Exit 1
+
+set -e
+
+cat >> configure.in <<'END'
+AC_PROG_CC
+AC_PROG_RANLIB
+AC_OUTPUT
+END
+
+cat > Makefile.am <<'END'
+my_libdir = $(libdir)
+my_lib_PROGRAMS = foo
+
+foodir = $(bindir)
+foo_LIBRARIES = libquux.a
+
+xdir = $(libexecdir)
+x_HEADERS = bar.h
+
+installcheck-local: test
+.PHONY: test
+test:
+ (cd '$(prefix)' && find .);: For debugging.
+ ls -l '$(libdir)/foo'
+ test -f '$(libdir)/foo'
+ test -x '$(libdir)/foo'
+ ls -l '$(bindir)/libquux.a'
+ test -f '$(bindir)/libquux.a'
+ ls -l '$(libexecdir)/bar.h'
+ test -f '$(libexecdir)/bar.h'
+ test ! -x '$(libexecdir)/bar.h'
+END
+
+cat > foo.c <<'END'
+int main (void)
+{
+ return 0;
+}
+END
+
+cat > libquux.c <<'END'
+int quux(void)
+{
+ return 1;
+}
+END
+
+: > bar.h
+
+$ACLOCAL
+$AUTOMAKE
+$AUTOCONF
+
+cwd=`pwd` || fatal_ "cannot get current working directory"
+./configure --prefix="$cwd/_inst"
+
+$MAKE install
+$MAKE installcheck
+$MAKE distcheck
+
+:
diff --git a/tests/primary-prefix-invalid-couples.test
b/tests/primary-prefix-invalid-couples.test
new file mode 100755
index 0000000..88e0817
--- /dev/null
+++ b/tests/primary-prefix-invalid-couples.test
@@ -0,0 +1,187 @@
+#! /bin/sh
+# Copyright (C) 2011 Free Software Foundation, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+# Not all primaries/directories combinations are valid.
+# Automake should flag them as errors.
+# Originated from PR/294, extended later (following bug #7647) to
+# cover more cases.
+# See also test `primary-prefix-valid-couples.test'.
+
+. ./defs || Exit 1
+
+set -e
+
+oIFS=$IFS # Saved for later.
+
+: > ltmain.sh
+: > texinfo.tex
+: > elisp-comp
+: > py-compile
+: > config.guess
+: > config.sub
+
+cat >> configure.in <<'END'
+AC_PROG_CC
+AC_PROG_RANLIB
+AC_SUBST([LIBTOOL], [:]) dnl So that we don't have to require Libtool.
+AM_PROG_GCJ
+AM_PATH_PYTHON
+AM_PATH_LISPDIR
+END
+
+$ACLOCAL
+
+# Please keep this list in sync with the list of "Directory Variables"
+# in the GNU Coding Standards and with the list additional directory
+# variables provided by autoconf and/or automake (pkgdatadir, pkglibdir,
+# ...). See also the hash `%standard_prefix' in the automake script.
+prefixes='bin data dataroot doc dvi exec html include info lib libexec
+ lisp locale localstate man man1 man2 man3 man4 man5 man6 man7
+ man8 man9 oldinclude pdf pkgdata pkginclude pkglib pkglibexec
+ ps sbin sharedstate sysconf'
+# Please keep this list in sync with the list of primaries documented in
+# the Automake manual (see the "The Uniform Naming Scheme" section).
+primaries='PROGRAMS LIBRARIES LTLIBRARIES LISP PYTHON JAVA SCRIPTS DATA
+ HEADERS MANS TEXINFOS'
+
+# Use files, not variables, to hold the list of all the possible
+# prefix_PRIMARY couples and the list of those couples valid for
+# automake, to avoid having unreadable very verbose traces.
+
+set +x # Don't be overly verbose.
+
+for prefix in $prefixes; do
+ for primary in $primaries; do
+ echo ${prefix} ${primary}
+ done
+done >all.list
+
+for primary in $primaries; do
+ prefixes_ok=''
+ case $primary in
+ LIBRARIES|LTLIBRARIES)
+ prefixes_ok='lib pkglib'
+ ;;
+ PROGRAMS)
+ prefixes_ok='bin sbin libexec pkglibexec'
+ ;;
+ SCRIPTS)
+ prefixes_ok='bin sbin libexec pkgdata'
+ ;;
+ DATA)
+ prefixes_ok='data dataroot pkgdata doc html dvi pdf ps
+ sysconf sharedstate localstate lisp'
+ ;;
+ HEADERS)
+ prefixes_ok='include oldinclude pkginclude'
+ ;;
+ LISP)
+ prefixes_ok='lisp'
+ ;;
+ PYTHON)
+ prefixes_ok='python'
+ ;;
+ JAVA)
+ prefixes_ok='java'
+ ;;
+ MANS)
+ # FIXME: Here we'd like to have:
+ # prefixes_ok='man man1 man2 man3 man4 man5 man6 man7 man8 man9'
+ # but Automake currently fails on that, as it allows the MANS
+ # primary to be coupled to any prefix.
+ # See also Automake bug#7656.
+ # We should dig out how automake had come to behave this way, and
+ # if such a behaviour can be safely changed.
+ prefixes_ok=$prefixes
+ ;;
+ TEXINFOS)
+ # FIXME: Here we'd like to have:
+ # prefixes_ok='info'
+ # but Automake currently fails on that, as it allows the use of
+ # `foo_TEXINFOS' to declare extra Texinfo sources for the `foo'
+ # Texinfo manual, as in e.g.:
+ # info_TEXINFOS = foo.texi
+ # foo_TEXINFOS = gpl.texi
+ # See also Automake bug#7657.
+ prefixes_ok=$prefixes
+ ;;
+ *)
+ fatal_ "unrecognized primary '$primary'"
+ ;;
+ esac
+ for prefix in $prefixes_ok; do
+ echo ${prefix}_${primary}
+ done
+done >allow.list
+
+# `html_TEXINFOS' is not yet supported, and might never be.
+grep -v '^html TEXINFOS$' all.list | awk '{print NR, $0}' > t
+mv -f t all.list
+
+# For debugging.
+echo '=== all.list ==='
+cat all.list
+echo '=== allow.list ==='
+cat allow.list
+
+# Create the Makefile.am.
+while read lineno prefix primary; do
+ test -n "$prefix" && test -n "$primary" && test 0 -lt $lineno \
+ || fatal_ "internal error in 'all.list'"
+ pfx='' ext=''
+ case $primary in
+ LTLIBRARIES) pfx=lib ext=la;;
+ LIBRARIES) pfx=lib ext=a;;
+ MANS) ext=man;;
+ HEADERS) ext=h;;
+ JAVA) ext=java;;
+ PYTHON) ext=py;;
+ LISP) ext=el;;
+ TEXINFOS) ext=texi;;
+ esac
+ test -z "$ext" || ext=.$ext
+ if test $primary = TEXINFOS; then
+ echo @setfilename foo$lineno.info > foo$lineno.texi
+ fi
+ echo ${prefix}_${primary} = ${pfx}foo${lineno}${ext}
+done <all.list >Makefile.am
+
+# For debugging.
+echo '=== Makefile.am ==='
+cat Makefile.am
+
+set -x # Restore shell xtraces from now on.
+
+AUTOMAKE_fails -a
+
+while read lineno prefix primary; do
+ test -n "$prefix" && test -n "$primary" && test 0 -lt $lineno \
+ || fatal_ "internal error in 'all.list'"
+ grep "^${prefix}_${primary}$" allow.list >/dev/null && continue
+ errmsg_rx=".*${prefix}dir.* not a legitimate directory .*$primary"
+ grep "^Makefile\\.am:$lineno: $errmsg_rx" stderr || Exit 1
+done <all.list
+
+# Check that automake really failed only for the expected reason(s).
+grep -v 'dir.* not a legitimate directory' stderr && Exit 1
+
+# Check that the same failures are present without the `--add-missing'
+# option.
+mv stderr stderr.old
+AUTOMAKE_fails
+diff stderr.old stderr
+
+:
diff --git a/tests/primary-prefix-valid-couples.test
b/tests/primary-prefix-valid-couples.test
new file mode 100755
index 0000000..f326808
--- /dev/null
+++ b/tests/primary-prefix-valid-couples.test
@@ -0,0 +1,90 @@
+#! /bin/sh
+# Copyright (C) 2011 Free Software Foundation, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+# Test for valid prefix/primary combinations.
+# See also test `primary-prefix-invalid-couples.test'.
+
+. ./defs || Exit 1
+
+set -e
+
+cat >> configure.in <<'END'
+AC_PROG_CC
+AC_PROG_RANLIB
+AC_PROG_LIBTOOL
+AM_PROG_GCJ
+AM_PATH_PYTHON
+AM_PATH_LISPDIR
+END
+
+# Fake libtool availability.
+: > ltmain.sh
+: > config.sub
+: > config.guess
+cat > acinclude.m4 <<'END'
+AC_DEFUN([AC_PROG_LIBTOOL],
+ [AC_SUBST([LIBTOOL], [:])])
+END
+
+# Other required files.
+echo '@setfilename foo' > foo.texi
+: > texinfo.tex
+: > py-compile
+: > elisp-comp
+
+# Setup Makefile.am.
+
+: > Makefile.am
+
+for p in bin sbin libexec pkglibexec; do
+ echo "${p}_PROGRAMS = prog-$p" >> Makefile.am
+done
+
+for p in lib pkglib; do
+ echo "${p}_LIBRARIES = libs-$p.a" >> Makefile.am
+ echo "${p}_LTLIBRARIES = libd-$p.la" >> Makefile.am
+done
+
+for p in bin sbin libexec pkgdata; do
+ echo "${p}_SCRIPTS = $p.sh" >> Makefile.am
+done
+
+for p in data dataroot pkgdata doc html dvi pdf ps sysconf \
+ sharedstate localstate lisp; do
+ echo "${p}_DATA = $p.dat" >> Makefile.am
+done
+
+for p in include oldinclude pkginclude; do
+ echo "${p}_HEADERS = $p.h" >> Makefile.am
+done
+
+for p in man man1 man2 man3 man4 man5 man6 man7 man8 man9; do
+ echo "${p}_MANS = bar.$p"
+done
+
+echo "info_TEXINFOS = foo.texi" >> Makefile.am
+echo "lisp_LISP = foo.el" >> Makefile.am
+echo "python_PYTHON = foo.py" >> Makefile.am
+echo "java_JAVA = foo.java" >> Makefile.am
+
+awk '{print NR ":" $0}' Makefile.am # For debugging.
+
+# Go with the tests.
+
+$ACLOCAL
+$AUTOMAKE
+
+:
diff --git a/tests/gcj6.test b/tests/remake-subdir-from-subdir.test
similarity index 58%
copy from tests/gcj6.test
copy to tests/remake-subdir-from-subdir.test
index be5f49c..1e369f8 100755
--- a/tests/gcj6.test
+++ b/tests/remake-subdir-from-subdir.test
@@ -14,40 +14,43 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
-# AM_PROG_GCJ should cause OBJEXT and EXEEXT to be set.
+# Check that remake rules works for adding a new subdirectory from a
+# pre-existing subdirectory.
-required='gcj'
. ./defs || Exit 1
set -e
-cat >> configure.in << 'END'
-AM_PROG_GCJ
+cat >> configure.in <<'END'
+m4_include([subdirs.m4])
+AC_SUBST([MAGIC], [magic])
AC_OUTPUT
END
-cat > Makefile.am << 'END'
-noinst_PROGRAMS = test
-test_SOURCES = Test.java
-test_LDFLAGS = --main=Test
-END
+echo 'AC_CONFIG_FILES([sub/Makefile])' > subdirs.m4
+echo 'SUBDIRS = sub' > Makefile.am
-cat >Test.java << 'END'
-public class Test {
- public static void main(String[] argv) {
- System.out.println("Hello, automake!");
- }
-}
-END
+mkdir sub
+: > sub/Makefile.am
$ACLOCAL
-$AUTOMAKE
$AUTOCONF
+$AUTOMAKE
+
./configure
+$MAKE
-# These fail without e.g., AC_PROG_CC.
+cd sub
+$sleep
+echo 'AC_CONFIG_FILES([sub/subsub/Makefile])' >> ../subdirs.m4
+echo 'SUBDIRS = subsub' >> Makefile.am
+mkdir subsub
+cat > subsub/Makefile.am <<'END'
+all-local:
+ : > ok-it-works
+END
+using_gmake || $MAKE Makefile
$MAKE
-grep "OBJEXT = " Makefile
-grep "EXEEXT = " Makefile
+test -f subsub/ok-it-works
:
diff --git a/tests/remake-subdir-gnu.test b/tests/remake-subdir-gnu.test
new file mode 100755
index 0000000..cc683f3
--- /dev/null
+++ b/tests/remake-subdir-gnu.test
@@ -0,0 +1,80 @@
+#! /bin/sh
+# Copyright (C) 2011 Free Software Foundation, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+# Check that remake rules works from subdirectories, even using
+# `GNUmakefile' as makefiles name. This obviously requires GNU
+# make.
+
+required=GNUmake
+. ./defs || Exit 1
+
+set -e
+
+magic1='::MagicString::One::'
+magic2='__MagicString__Two__'
+
+debug_info ()
+{
+ grep -i magic configure GNUmakefile.in GNUmakefile \
+ sub/GNUmakefile.in sub/GNUmakefile
+}
+
+cat > configure.in <<END
+AC_INIT([$me], [1.0])
+AM_INIT_AUTOMAKE
+AC_CONFIG_FILES([GNUmakefile sub/GNUmakefile])
+AC_SUBST([MAGIC], [magic])
+AC_OUTPUT
+END
+
+cat > GNUmakefile.am <<'END'
+SUBDIRS = sub
+END
+
+mkdir sub
+: > sub/GNUmakefile.am
+
+$ACLOCAL
+$AUTOCONF
+$AUTOMAKE
+
+./configure
+$MAKE
+debug_info
+
+$sleep
+sed "s|magic|$magic1|" configure.in > t
+mv -f t configure.in
+cd sub
+$MAKE
+cd ..
+debug_info
+$FGREP $magic1 configure
+$FGREP $magic1 GNUmakefile
+$FGREP $magic1 sub/GNUmakefile
+
+$sleep
+cd sub
+echo MAGIC = $magic2 >> GNUmakefile.am
+$MAKE
+cd ..
+debug_info
+$FGREP $magic2 sub/GNUmakefile
+$FGREP $magic2 sub/GNUmakefile.in
+$FGREP $magic1 sub/GNUmakefile sub/GNUmakefile.in && Exit 1
+$FGREP $magic2 GNUmakefile GNUmakefile.in && Exit 1
+
+:
diff --git a/tests/remake-subdir-long-time.test
b/tests/remake-subdir-long-time.test
new file mode 100755
index 0000000..18ba732
--- /dev/null
+++ b/tests/remake-subdir-long-time.test
@@ -0,0 +1,116 @@
+#! /bin/sh
+# Copyright (C) 2011 Free Software Foundation, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+# Check that remake rules from subdirectories do not hang or cycle
+# endlessly, even with build systems that takes several seconds to
+# rebuild the Makefiles.
+# This test tries to ensure a long-enough rebuild time by introducing
+# an explicit delay in the build process.
+# Suggestion by Ralf Wildenhues.
+
+. ./defs || Exit 1
+
+set -e
+
+cat > configure.in <<END
+AC_INIT([$me], [1.0])
+AM_INIT_AUTOMAKE([foreign -Wall -Werror])
+AC_CONFIG_FILES([Makefile sub/Makefile])
+AC_SUBST([MAGIC], [magic])
+AC_OUTPUT
+END
+
+echo SUBDIRS = sub > Makefile.am
+mkdir sub
+: > sub/Makefile.am
+
+# Both aclocal and automake are expected to run one and just one time.
+# Create and use wrappers that will verify that.
+
+ocwd=`pwd` || fatal_ "cannot get current working directory"
+
+mkdir bin
+
+cat > bin/automake <<END
+#!/bin/sh
+set -e
+PATH='$PATH'; export PATH
+sentinel='$ocwd/automake-has-run'
+if test -f "\$sentinel"; then
+ echo "Automake has been run more than one time" >&2
+ exit 1
+else
+ echo automake has run > "\$sentinel"
+fi
+$sleep; $sleep;
+exec $AUTOMAKE \${1+"\$@"}
+END
+chmod a+x bin/automake
+
+cat > bin/aclocal <<END
+#!/bin/sh
+set -e
+PATH='$PATH'; export PATH
+sentinel='$ocwd/aclocal-has-run'
+if test -f "\$sentinel"; then
+ echo "Aclocal has been run more than one time" >&2
+ exit 1
+else
+ echo aclocal has run > "\$sentinel"
+fi
+$sleep; $sleep;
+exec $ACLOCAL \${1+"\$@"}
+END
+chmod a+x bin/aclocal
+
+# Just to be sure.
+cp bin/automake bin/automake-$APIVERSION
+cp bin/aclocal bin/aclocal-$APIVERSION
+
+PATH=$ocwd/bin$PATH_SEPARATOR$PATH; export PATH
+
+AUTOMAKE=automake ACLOCAL=aclocal; export AUTOMAKE ACLOCAL
+
+$ACLOCAL # Should use or just-defined wrapper.
+$AUTOMAKE # Likewise.
+$AUTOCONF
+
+# Sanity check: the wrappers have been used.
+test -f automake-has-run
+test -f aclocal-has-run
+rm -f automake-has-run aclocal-has-run
+
+./configure
+# Sanity check: Makefile doesn't get updated uselessly.
+ACLOCAL=false AUTOMAKE=false AUTOCONF=false $MAKE -e
+
+$sleep
+sed "s|magic|magic2|" configure.in > t
+mv -f t configure.in
+
+cd sub
+AUTOMAKE="$AUTOMAKE" ACLOCAL="$ACLOCAL" $MAKE -e Makefile
+cd ..
+
+# For debugging.
+ls -l . sub
+grep -i magic configure Makefile.in Makefile sub/Makefile.in sub/Makefile
+# Sanity checks.
+$FGREP magic2 configure
+$FGREP magic2 Makefile
+$FGREP magic2 sub/Makefile
+
+:
diff --git a/tests/autodist-acconfig-no-subdir.test b/tests/remake-subdir.test
similarity index 51%
copy from tests/autodist-acconfig-no-subdir.test
copy to tests/remake-subdir.test
index e6bd5a9..5bbc345 100755
--- a/tests/autodist-acconfig-no-subdir.test
+++ b/tests/remake-subdir.test
@@ -14,45 +14,68 @@
# 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 that `acconfig.h' is *not* automatically distributed when
-# placed in a subdirectory.
-# Related to automake bug#7819.
+# Check that remake rules works from subdirectories, even with non-GNU
+# make implementations.
. ./defs || Exit 1
set -e
-cat >> configure.in <<END
+if using_gmake; then
+ remake=$MAKE
+else
+ remake="$MAKE Makefile"
+fi
+
+magic1='::MagicString::One::'
+magic2='__MagicString__Two__'
+
+debug_info ()
+{
+ grep -i magic configure Makefile.in Makefile sub/Makefile.in sub/Makefile
+}
+
+cat >> configure.in <<'END'
AC_CONFIG_FILES([sub/Makefile])
+AC_SUBST([MAGIC], [magic])
AC_OUTPUT
END
cat > Makefile.am <<'END'
SUBDIRS = sub
-sub/acconfig.h:
- echo target $@ should not be built >&2; exit 1
-check-local: distdir
- ls -l $(distdir)/sub
- test ! -f $(distdir)/sub/acconfig.h
END
mkdir sub
-
-cat > sub/Makefile.am <<'END'
-acconfig.h:
- echo target $@ should not be built >&2; exit 1
-check-local:
- echo $(DISTFILES) | grep 'acconfig\.h' && exit 1; :
- echo $(DIST_COMMON) | grep 'acconfig\.h' && exit 1; :
-END
-
-: > sub/acconfig.h
+: > sub/Makefile.am
$ACLOCAL
-$AUTOMAKE
$AUTOCONF
+$AUTOMAKE
./configure
-$MAKE check
+$MAKE
+debug_info
+
+$sleep
+sed "s|magic|$magic1|" configure.in > t
+mv -f t configure.in
+cd sub
+$remake
+cd ..
+debug_info
+$FGREP $magic1 configure
+$FGREP $magic1 Makefile
+$FGREP $magic1 sub/Makefile
+
+$sleep
+cd sub
+echo MAGIC = $magic2 >> Makefile.am
+$remake
+cd ..
+debug_info
+$FGREP $magic2 sub/Makefile
+$FGREP $magic2 sub/Makefile.in
+$FGREP $magic1 sub/Makefile sub/Makefile.in && Exit 1
+$FGREP $magic2 Makefile Makefile.in && Exit 1
:
diff --git a/tests/remake-subdir2.test b/tests/remake-subdir2.test
new file mode 100755
index 0000000..09d1a36
--- /dev/null
+++ b/tests/remake-subdir2.test
@@ -0,0 +1,82 @@
+#! /bin/sh
+# Copyright (C) 2011 Free Software Foundation, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+# Check that remake rules works from subdirectories, even when makefiles
+# are not named "Makefile".
+
+. ./defs || Exit 1
+
+set -e
+
+magic1='::MagicString::One::'
+magic2='__MagicString__Two__'
+
+debug_info ()
+{
+ grep -i magic configure build.in build.mk sub/build.in sub/build.mk
+}
+
+cat > configure.in <<END
+AC_INIT([$me], [1.0])
+AM_INIT_AUTOMAKE
+AC_CONFIG_FILES([build.mk:build.in])
+AC_CONFIG_FILES([sub/build.mk:sub/build.in])
+AC_SUBST([MAGIC], [magic])
+AC_OUTPUT
+END
+
+cat > build.am <<'END'
+AM_MAKEFLAGS = -f build.mk
+SUBDIRS = sub
+END
+
+mkdir sub
+cat > sub/build.am <<'END'
+AM_MAKEFLAGS = -f build.mk
+END
+
+$ACLOCAL
+$AUTOCONF
+$AUTOMAKE
+./configure
+ls -l # For debugging.
+
+$MAKE -f build.mk
+debug_info
+
+$sleep
+sed "s|magic|$magic1|" configure.in > t
+mv -f t configure.in
+cd sub
+$MAKE -f build.mk build.mk
+cd ..
+debug_info
+$FGREP $magic1 configure
+$FGREP $magic1 build.mk
+$FGREP $magic1 sub/build.mk
+
+$sleep
+cd sub
+echo MAGIC = $magic2 >> build.am
+$MAKE -f build.mk build.mk
+cd ..
+debug_info
+$FGREP $magic2 sub/build.mk
+$FGREP $magic2 sub/build.in
+$FGREP $magic1 sub/build.in sub/build.mk && Exit 1
+$FGREP $magic2 build.in build.mk && Exit 1
+
+:
diff --git a/tests/dirforbid.test b/tests/self-check-env-sanitize.test
similarity index 57%
rename from tests/dirforbid.test
rename to tests/self-check-env-sanitize.test
index 3ab319d..9d18d9e 100755
--- a/tests/dirforbid.test
+++ b/tests/self-check-env-sanitize.test
@@ -1,5 +1,5 @@
#! /bin/sh
-# Copyright (C) 2002, 2003 Free Software Foundation, Inc.
+# Copyright (C) 2011 Free Software Foundation, Inc.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -14,25 +14,17 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
-# All primaries cannot be used with all directories.
-# Automake should flag them as errors.
-# For PR/294
+# Sanity check for the automake testsuite.
+# Make sure that the testsuite initialization code complains when
+# some testsuite-influential variables are set in the environment.
-. ./defs || Exit 1
+set -x
-set -e
-
-cat >> configure.in <<'END'
-AC_PROG_CC
-END
-
-# Try some (not all) disallowed variables
-for i in data_PROGRAMS lib_HEADERS ; do
- cat > Makefile.am << END
-$i = foo
-END
- $ACLOCAL
- AUTOMAKE_fails -a
- grep 'Makefile.am:1:.*directory' stderr
+exec 5>&1
+for var in me parallel_tests required; do
+ env "$var=foo" /bin/sh -c '. ./defs' foo.test && exit 1
+ env "$var=foo" /bin/sh -c '. ./defs' foo.test 2>&1 1>&5 \
+ | grep "variable \`$var' is set in the environment.*unsafe" || exit 1
done
+
:
diff --git a/tests/self-check-report.test b/tests/self-check-report.test
new file mode 100755
index 0000000..639319a
--- /dev/null
+++ b/tests/self-check-report.test
@@ -0,0 +1,47 @@
+#! /bin/sh
+# Copyright (C) 2011 Free Software Foundation, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+# Sanity check for the automake testsuite.
+# Test subroutines to report warnings, and to signal failures, skips
+# and hard errors.
+
+. ./defs || Exit 1
+
+set +e
+
+exec 5>&1
+
+(warn_ foobar) 2>&1 1>&5 | grep '^foobar$' || Exit 1
+(fail_ foo); test $? -eq 1 || Exit 1
+(fail_ foo) 2>&1 1>&5 | grep "^$me: failed test: foo" || Exit 1
+(skip_ foo); test $? -eq 77 || Exit 1
+(skip_ foo) 2>&1 1>&5 | grep "^$me: skipped test: foo" || Exit 1
+(framework_failure_ foo); test $? -eq 99 || Exit 1
+(framework_failure_ foo) 2>&1 1>&5 \
+ | grep "^$me: set-up failure: foo" || Exit 1
+
+stderr_fileno_=6
+
+(warn_ foobar) 6>&1 1>&5 | grep '^foobar$' || Exit 1
+(fail_ foo); test $? -eq 1 || Exit 1
+(fail_ foo) 6>&1 1>&5 | grep "^$me: failed test: foo" || Exit 1
+(skip_ foo); test $? -eq 77 || Exit 1
+(skip_ foo) 6>&1 1>&5 | grep "^$me: skipped test: foo" || Exit 1
+(framework_failure_ foo); test $? -eq 99 || Exit 1
+(framework_failure_ foo) 6>&1 1>&5 \
+ | grep "^$me: set-up failure: foo" || Exit 1
+
+:
diff --git a/tests/silent-configsite.test b/tests/silent-configsite.test
new file mode 100755
index 0000000..a0255f5
--- /dev/null
+++ b/tests/silent-configsite.test
@@ -0,0 +1,86 @@
+#!/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 that the user can control default mode of silent-rules
+# from config.site, and that this default can be overridden from
+# either the ./configure or make command line.
+
+. ./defs || Exit 1
+
+set -e
+
+cat >> configure.in <<'EOF'
+AM_SILENT_RULES
+AC_OUTPUT
+EOF
+
+cat > Makefile.am <<'EOF'
+.PHONY: test-silent test-nosilent
+test-silent:
+ test x'$(AM_DEFAULT_VERBOSITY)' = x'0'
+test-nosilent:
+ test x'$(AM_DEFAULT_VERBOSITY)' = x'1'
+EOF
+
+unset enable_silent_rules || :
+
+: 'No explicit default in configure.in, enable by default in config.site'
+
+$ACLOCAL
+$AUTOCONF
+$AUTOMAKE --add-missing
+echo "enable_silent_rules=\${enable_silent_rules-yes}" > config.site
+CONFIG_SITE=./config.site ./configure
+$MAKE test-silent
+$MAKE distclean
+# Command line should win over default values in config.site.
+CONFIG_SITE=./config.site ./configure --disable-silent-rules
+$MAKE test-nosilent
+$MAKE distclean
+
+: 'Disable by default in configure.in, enable by default in config.site'
+
+sed 's/^AM_SILENT_RULES/&([no])/' configure.in > configure.tmp
+mv -f configure.tmp configure.in
+$ACLOCAL
+$AUTOCONF
+$AUTOMAKE --add-missing
+echo "enable_silent_rules=\${enable_silent_rules-yes}" > config.site
+CONFIG_SITE=./config.site ./configure
+$MAKE test-silent
+# Command line should win over default values in config.site.
+$MAKE distclean
+CONFIG_SITE=./config.site ./configure --disable-silent-rules
+$MAKE test-nosilent
+$MAKE distclean
+
+: 'Enable by default in configure.in, disable by default in config.site'
+
+sed 's/^AM_SILENT_RULES/&([yes])/' configure.in > configure.tmp
+mv -f configure.tmp configure.in
+$ACLOCAL
+$AUTOCONF
+$AUTOMAKE --add-missing
+echo "enable_silent_rules=\${enable_silent_rules-no}" > config.site
+CONFIG_SITE=./config.site ./configure
+$MAKE test-nosilent
+$MAKE distclean
+# Command line should win over default values in config.site.
+CONFIG_SITE=./config.site ./configure --enable-silent-rules
+$MAKE test-silent
+$MAKE distclean
+
+:
diff --git a/tests/specflg8.test b/tests/specflg8.test
index 1abcaa2..79daa15 100755
--- a/tests/specflg8.test
+++ b/tests/specflg8.test
@@ -1,5 +1,5 @@
#! /bin/sh
-# Copyright (C) 2002, 2004 Free Software Foundation, Inc.
+# Copyright (C) 2002, 2004, 2011 Free Software Foundation, Inc.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -34,25 +34,18 @@ END
# different flags.
cat > Makefile.am << 'END'
-FALSESOURCE = false.c
+TRUESOURCE = true.c
bin_PROGRAMS = false true
-true_SOURCES = $(FALSESOURCE)
-true_CPPFLAGS = -DAM_TRUE
-false_SOURCES = $(FALSESOURCE)
-false_CPPFLAGS = -DAM_FALSE
+true_SOURCES = $(TRUESOURCE)
+true_CPPFLAGS = -DEXIT_CODE=0
+false_SOURCES = $(TRUESOURCE)
+false_CPPFLAGS = -DEXIT_CODE=1
END
-cat > false.c << 'END'
-#include <stdio.h>
-int
-main (int argc, char *argv[])
+cat > true.c << 'END'
+int main (void)
{
-#ifdef AM_TRUE
- puts ("true");
-#else
- puts ("false");
-#endif
- return 0;
+ return EXIT_CODE;
}
END
@@ -62,5 +55,11 @@ $AUTOMAKE -a
./configure
$MAKE
-./true | grep true
-./false | grep false
+
+./true
+./false && Exit 1
+
+test -f ./true-true.o
+test -f ./true-true.o
+
+:
diff --git a/tests/check-tests_environment.test
b/tests/tests-environment-backcompat.test
similarity index 53%
copy from tests/check-tests_environment.test
copy to tests/tests-environment-backcompat.test
index a07ab95..ecf1b16 100755
--- a/tests/check-tests_environment.test
+++ b/tests/tests-environment-backcompat.test
@@ -14,26 +14,40 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
-# "Simple Tests" testsuite driver: check TESTS_ENVIRONMENT support.
+# With old serial testsuite driver, TESTS_ENVIRONMENT can be used to
+# define the "test runner", i.e. the program that the test scripts must
+# be run by (with the parallel-tests driver one should use LOG_COMPILER
+# for this). The behaviour tested here is also documented in the manual.
+parallel_tests=no
. ./defs || Exit 1
set -e
-cat >> configure.in << 'END'
+cat >> configure.in <<END
+AC_SUBST([PERL], ['$PERL'])
AC_OUTPUT
END
cat > Makefile.am << 'END'
-TESTS = foo.test
+TESTS_ENVIRONMENT = $(PERL) -Mstrict -w
+TESTS = foo.pl bar.pl baz.pl
+XFAIL_TESTS = baz.pl
EXTRA_DIST = $(TESTS)
END
-cat > foo.test << 'END'
-#! /bin/sh
-test x"$FOO" = x"ok"
+echo 'exit (0);' > foo.pl
+echo 'exit (0);' > bar.pl
+
+cat > baz.pl << 'END'
+# With "use strict" enacted, this will cause an error, since the
+# variable `$x' is not declared with `my' nor specified with an
+# explicit package name.
+$x = 0;
+exit ($x);
END
-chmod a+x foo.test
+
+chmod a+x *.pl
$ACLOCAL
$AUTOCONF
@@ -41,7 +55,7 @@ $AUTOMAKE -a
./configure
-FOO=bad TESTS_ENVIRONMENT='FOO=ok' $MAKE check
-FOO=ok TESTS_ENVIRONMENT='FOO=bad' $MAKE check && Exit 1
+$MAKE check
+$MAKE distcheck
:
diff --git a/tests/txinfo21.test b/tests/txinfo21.test
index 4bbce4a..ae1d985 100755
--- a/tests/txinfo21.test
+++ b/tests/txinfo21.test
@@ -95,11 +95,11 @@ test -d sub/main2.html
test -d rec/main3.html
# Rebuilding main.html should cause its timestamp to be updated.
-test `ls -1td main.texi main.html | sed 1q` = main.html
+is_newest main.html main.texi
$sleep
touch main.texi
$MAKE html
-test `ls -1td main.texi main.html | sed 1q` = main.html
+is_newest main.html main.texi
$MAKE clean
test ! -d main.html
@@ -118,8 +118,8 @@ test ! -f rec/main3.html
# Make sure AM_MAKEINFOHTMLFLAGS is supported, and override AM_MAKEINFO.
cat >>Makefile.am <<\EOF
-AM_MAKEINFOHTMLFLAGS=--no-split
-AM_MAKEINFOFLAGS=--unsupported-option
+AM_MAKEINFOHTMLFLAGS = --no-headers --no-split
+AM_MAKEINFOFLAGS = --unsupported-option
EOF
$AUTOMAKE
./configure --prefix "`pwd`"
hooks/post-receive
--
GNU Automake
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Automake-commit] [SCM] GNU Automake branch, branch-1.11, updated. v1.11.1-455-gd5c4481,
Ralf Wildenhues <=