automake-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Automake-commit] [SCM] GNU Automake branch, master, updated. v1.13.1b-1


From: Stefano Lattarini
Subject: [Automake-commit] [SCM] GNU Automake branch, master, updated. v1.13.1b-148-ga5ed87e
Date: Thu, 21 Feb 2013 16:03:18 +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=a5ed87e7944deaea33914230e3d67ff08eb18382

The branch, master has been updated
       via  a5ed87e7944deaea33914230e3d67ff08eb18382 (commit)
       via  b4dbcb75f1c70d648c96dd0ec95aac6eaafecdef (commit)
       via  d5f83b89cc4d2da9078669018877b3bac5c2fadc (commit)
       via  a8933e87ca570f3e710559b12cddad4473525c19 (commit)
       via  7a3d7cee2b3270443bcd3b91e7e4ada8a1a858a1 (commit)
       via  b4f36584ba52eea885fcd89e5f404f09312ae430 (commit)
       via  5daad7029bfc62932b84517b49c73b38bd5c750c (commit)
       via  b7ac9a37b3c7c78db1ba2beb32cf10bda9db996b (commit)
       via  c83c133556205402d44e81d492efb0b2fe3e3584 (commit)
       via  8234bfb0c0fa62b2c43b9c8f0a5ab5fc5316ff4c (commit)
       via  436d6f6f75f08f77f26f857c9b883d64c5061898 (commit)
       via  97aaf121e92767dc06385d020dd30cdfaa86126f (commit)
       via  4356484dc4b1ff15760a735025877a174c85fe0f (commit)
      from  5e074aa5e14c7debc33f01ff9f40283278d06128 (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 a5ed87e7944deaea33914230e3d67ff08eb18382
Merge: 5e074aa b4dbcb7
Author: Stefano Lattarini <address@hidden>
Date:   Thu Feb 21 16:39:22 2013 +0100

    Merge branch 'maint' into master
    
    * maint:
      maint: more adjustments to the new versioning scheme
      aclocal: fix for more-than-once specified directories
      aclocal: just warn if the primary local m4 dir doesn't exist (don't error)
      coverage: expose automake bug#13760
      tests: refactor/enhance tests about make dry-run mode
      maint: describe new versioning and branching scheme, and adjust to it
      cosmetics: fix some "docstring-like" comments in automake
    
    Signed-off-by: Stefano Lattarini <address@hidden>

-----------------------------------------------------------------------

Summary of changes:
 HACKING                                    |   85 +++++++++++++++++---
 NEWS                                       |   66 +++++++++++++--
 PLANS/obsolete-removed/am-prog-mkdir-p.txt |    4 +-
 PLANS/obsolete-removed/configure.in.txt    |   10 +-
 PLANS/rm-f-without-args.txt                |   10 +-
 PLANS/subdir-objects.txt                   |   10 +-
 PLANS/texi/drop-split-info-files.txt       |    6 +-
 THANKS                                     |    2 +
 aclocal.in                                 |   64 ++++++++++++---
 automake.in                                |  117 ++++++---------------------
 lib/Automake/Options.pm                    |    4 +-
 m4/internal/ac-config-macro-dirs.m4        |    2 +-
 t/aclocal-acdir.sh                         |    2 +-
 t/aclocal-macrodir.tap                     |   36 +++++++-
 t/aclocal-macrodirs.tap                    |   41 ++++++++--
 t/make-dryrun.tap                          |  123 ++++++++++++++++------------
 16 files changed, 373 insertions(+), 209 deletions(-)

diff --git a/HACKING b/HACKING
index a4f89bd..b526600 100644
--- a/HACKING
+++ b/HACKING
@@ -100,6 +100,48 @@
   The use of & prevents prototypes from being checked.
 
 ============================================================================
+= Automake versioning and compatibility scheme
+
+* There are three kinds of automake releases:
+
+    - new major releases (e.g., 2.0, 5.0)
+    - new minor releases (e.g., 1.14, 2.1)
+    - micro a.k.a. "bug-fixing" releases (e.g., 1.13.2, 2.0.1, 3.5.17).
+
+  A new major release should have the major version number bumped, and
+  the minor and micro version numbers reset to zero.  A new minor release
+  should have the major version number unchanged, the minor version number
+  bumped, and the micro version number reset to zero.  Finally, a new
+  micro version should have the major and minor version numbers unchanged,
+  and the micro version number bumped.
+
+  For example, the first minor version after 1.13.2 will be 1.14; the
+  first bug-fixing version after 1.14 that will be 1.14.1; the first
+  new major version after all such releases will be 2.0; the first
+  bug-fixing version after 2.0 will be 2.0.1; and a further bug-fixing
+  version after 2.0.1 will be 2.0.2.
+
+* Micro releases should be just bug-fixing releases; no new features
+  should be added, and ideally, only trivial bugs, recent regressions,
+  or documentation issues should be addressed by them.
+
+* Minor releases can introduce new "safe" features, do non-trivial
+  but mostly safe code clean-ups, and even add new runtime warnings
+  (rigorously non-fatal); but they shouldn't include any backward
+  incompatible change, nor contain any potentially destabilizing
+  refactoring or sweeping change, nor introduce new features whose
+  implementation might be liable to cause bugs or regressions in
+  existing code.
+
+* Major releases can introduce backward-incompatibilities (albeit
+  such incompatibilities should be announced well in advance, and
+  a smooth transition plan prepared for them), and try more risking
+  and daring refactorings and code cleanups.
+
+* For more information, refer to the extensive discussion associated
+  with automake bug#13578.
+
+============================================================================
 = Working with git
 
 * To regenerate dependent files created by aclocal and automake,
@@ -110,22 +152,43 @@
   latest stable version of Autoconf installed and available early
   in your PATH.
 
-* The Automake git tree currently carries two basic branches: 'master' for
-  the current development, and 'maint' for maintenance and bug fixes.  The
-  maint branch should be kept regularly merged into the master branch.
-  It is advisable to merge only after a set of related commits have been
-  applied, to avoid introducing too much noise in the history.
+* The Automake git tree currently carries three basic branches: 'maint',
+  'master' and 'next'.
+
+* The 'maint' branch, reserved to changes that should go into the next
+  micro release; so it will just see fixes for regressions, trivial
+  bugs, or documentation issues, and no "active" development whatsoever.
+  Since emergency regression-fixing or security releases could be cut
+  from this branch at any time, it should always be kept in a releasable
+  state.
+
+* The 'master' branch is where the development of the next minor release
+  takes place.  It should be kept in a stable, almost-releasable state,
+  to simplify testing and deploying of new minor version.  Note that
+  this is not a hard rule, and such "stability" is not expected to be
+  absolute (emergency releases are cut from maint anyway).
+
+* The 'next' branch is reserved for the development of the next major
+  release.  Experimenting a little here is OK, but don't let the branch
+  grow too unstable; if you need to do exploratory programming
+  or over-arching change, you should use a dedicated topic branch, and
+  only merge that back once it is reasonably stable.
+
+* The 'maint' branch should be kept regularly merged into the 'master'
+  branch, and the 'master' branch into the 'next' branch.  It is advisable
+  to merge only after a set of related commits have been applied, to avoid
+  introducing too much noise in the history.
 
 * There may be a number of longer-lived feature branches for new
   developments.  They should be based off of a common ancestor of all
   active branches to which the feature should or might be merged later.
-  In the future, we might introduce a special branch named 'next' that
-  may serve as common ground for feature merging and testing, should
-  they not yet be ready for master.
 
-* After a major release is done, the master branch is to be merged into
-  the maint branch, and then a "new" master branch created stemming
-  from the resulting commit.
+* After a new minor release is done, the 'master' branch is to be merged
+  into the 'maint' branch, and then a "new" 'master' branch created
+  stemming from the resulting commit.
+  Similarly, after a new major release is done, the 'next' branch is to
+  be merged into both the 'master' and 'maint' branch, and then "new"
+  'master' and 'next' branches created stemming from the resulting commit.
 
 * When fixing a bug (especially a long-standing one), it may be useful
   to commit the fix to a new temporary branch based off the commit that
diff --git a/NEWS b/NEWS
index 2e26485..861991c 100644
--- a/NEWS
+++ b/NEWS
@@ -49,25 +49,62 @@ New in 1.14:
 
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
-New in 1.13.2:
+* WARNING: New versioning scheme for Automake.
+
+  - Starting with this version onward, Automake will use an update and
+    more rational versioning scheme, one that will allow users to know
+    which kind of changes can be expected from a new version, based on
+    its version number.
+
+    + Micro versions (e.g., 1.13.3, 2.0.1, 3.2.8) will introduce only
+      documentation updates and bug and regression fixes; they will
+      not introduce new features, nor any backward-incompatibility (any
+      such incompatibility would be considered a bug, to be fixed with
+      a further  micro release).
+
+    + Minor versions (e.g., 1.14, 2.1) can introduce new backward
+      compatible features; the only backward-incompatibilities allowed
+      in such a release are new *non-fatal* deprecations and warnings,
+      and possibly fixes for old or non-trivial bugs (or even inefficient
+      behaviours) that could unfortunately have been seen, and used, by
+      some developers as "corner case features".  This kind of fixes
+      should hopefully be quite rare.
+
+    + Major versions (now expected to be released every 18 or 24 months,
+      and not more often) can introduce new big features (possibly with
+      rough edges and not-fully-stabilized APIs), removal of deprecated
+      features, backward-incompatible changes of behaviour, and possibly
+      major refactorings (that, while ideally transparent to the user,
+      could introduce new bugs).  Incompatibilities should however not
+      be introduced gratuitously and abruptly; a proper deprecation path
+      should be duly implemented in the preceding minor releases.
+
+  - According to this new scheme, the next major version of Automake
+    (the one that has until now been labelled as '1.14') will actually
+    become "Automake 2.0".  Automake 1.14 will be the next minor version,
+    which will introduce new features and deprecation, but no backward
+    incompatibility.
+
+  - See discussion about automake bug#13578 for more details and
+    background: <http://debbugs.gnu.org/cgi/bugreport.cgi?bug=13578>
 
 * WARNING: Future backward-incompatibilities!
 
-  - Automake 1.14 will require Autoconf 2.70 or later (which is still
+  - Automake 2.0 will require Autoconf 2.70 or later (which is still
     unreleased at the moment of writing, but is planned to be released
-    before Automake 1.14 is).
+    before Automake 2.0 is).
 
-  - Automake 1.14 will drop support for the long-deprecated 'configure.in'
+  - Automake 2.0 will drop support for the long-deprecated 'configure.in'
     name for the Autoconf input file.  You are advised to start using the
     recommended name 'configure.ac' instead, ASAP.
 
   - The ACLOCAL_AMFLAGS special make variable will be fully deprecated
-    in Automake 1.14 (where it will raise warnings in the "obsolete"
+    in Automake 2.0 (where it will raise warnings in the "obsolete"
     category).  You are advised to start relying on the new Automake
     support for AC_CONFIG_MACRO_DIRS instead (which was introduced in
     Automake 1.13).
 
-  - Automake 1.14 will remove support for automatic dependency tracking
+  - Automake 2.0 will remove support for automatic dependency tracking
     with the SGI C/C++ compilers on IRIX.  The SGI depmode has been
     reported broken "in the wild" already, and we don't think investing
     time in debugging and fixing is worthwhile, especially considering
@@ -81,16 +118,20 @@ New in 1.13.2:
     modern Windows versions will continue to be fully supported.
 
   - Automake-provided scripts and makefile recipes might (finally!)
-    start assuming a POSIX shell in Automake 1.14.
+    start assuming a POSIX shell in Automake 2.0.
 
-  - Starting from Automake 1.14, third-party m4 files located in the
+  - Starting from Automake 2.0, third-party m4 files located in the
     system-wide aclocal directory, as well as in any directory listed
     in the ACLOCAL_PATH environment variable, will take precedence
     over "built-in" Automake macros.  For example (assuming Automake
     is installed in the /usr/local hierarchy), a definition of the
     AM_PROG_VALAC macro found in '/usr/local/share/aclocal/my-vala.m4'
     should take precedence over the same-named automake-provided macro
-    (defined in '/usr/local/share/aclocal-1.14/vala.m4').
+    (defined in '/usr/local/share/aclocal-2.0/vala.m4').
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+New in 1.13.2:
 
 * C compilation, and the AC_PROG_CC and AM_PROG_CC_C_O macros:
 
@@ -204,6 +245,13 @@ New in 1.13.2:
     Automake 1.13, has turned out to be a similarly very bad idea,
     for exactly the same reason.
 
+  - Aclocal no longer error out if the first local m4 directory (as
+    specified by the '-I' option or the 'AC_CONFIG_MACRO_DIRS' or
+    'AC_CONFIG_MACRO_DIR' macros) doesn't exist; it merely report a
+    warning in the 'unsupported' category.  This is done to support
+    some pre-existing real-world usages; refer to automake bug#13514
+    for more details.
+
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
 New in 1.13.1:
diff --git a/PLANS/obsolete-removed/am-prog-mkdir-p.txt 
b/PLANS/obsolete-removed/am-prog-mkdir-p.txt
index 40bc69f..3fe720e 100644
--- a/PLANS/obsolete-removed/am-prog-mkdir-p.txt
+++ b/PLANS/obsolete-removed/am-prog-mkdir-p.txt
@@ -54,14 +54,14 @@ out, and we lose.  That already happened in practice:
     <http://lists.gnu.org/archive/html/bug-grep/2013-01/msg00003.html>
 
 Moreover, while I might see it as not unreasonable to ask a developer
-using Automake 1.14 to also update Gettext to 1.18.2, that would not
+using Automake 2.0 to also update Gettext to 1.18.2, that would not
 be enough; in order for gettext to use the correct data files, that
 developer would have to update his configure.ac to read:
 
     AM_GNU_GETTEXT_VERSION([0.18.2])
 
 thus requiring *all* of his co-developers to install Gettext 1.18.2,
-even if they are still using, say, Automake 1.13.  Bad.
+even if they are still using, say, Automake 1.13 or 1.14.  Bad.
 
 So I decided to re-instate this macro as a simple alias for AC_PROG_MKDIR_P
 (plus a non-fatal runtime warning in the 'obsolete' category), and drop
diff --git a/PLANS/obsolete-removed/configure.in.txt 
b/PLANS/obsolete-removed/configure.in.txt
index baed853..180f92c 100644
--- a/PLANS/obsolete-removed/configure.in.txt
+++ b/PLANS/obsolete-removed/configure.in.txt
@@ -13,16 +13,16 @@ present in the development version of autoconf so far 
(scheduled to
 become Autoconf 2.70).  So ...
 
 
-For Automake 1.14
------------------
+For Automake 2.0
+----------------
 
 ... we have decided to wait until 2.70 is out before really removing
 'configure.in' support.  Since we plan to require Autoconf 2.70 in
-Automake 1.14 (so that we can remove the hacky code emulating
+Automake 2.0 (so that we can remove the hacky code emulating
 AC_CONFIG_MACRO_DIRS for older autoconf versions), we are quite sure
 that Autoconf will actually have started deprecating 'configure.in'
-by the time Automake 1.14 is released.
+by the time Automake 2.0 is released.
 
 Note that the removal of 'configure.in' has already been implemented
-in our master branch (from where the 1.14 release will be finally
+in our 'next' branch (from where the 2.0 release will be finally
 cut); see commits 'v1.13-17-gbff57c8' and 'v1.13-21-g7626e63'.
diff --git a/PLANS/rm-f-without-args.txt b/PLANS/rm-f-without-args.txt
index 5362f98..918e049 100644
--- a/PLANS/rm-f-without-args.txt
+++ b/PLANS/rm-f-without-args.txt
@@ -21,20 +21,20 @@ the no-args "rm -f" usage is supported on the system 
configure is
 being run on; complain loudly if this is not the case, and tell the
 user to report the situation to us.
 
-For Automake 1.14
------------------
+For Automake 2.0
+----------------
 
 Make any failure in the configure-time probe check introduced by the
 previous point fatal; and in case of failure, also suggest to the user
 to install an older version of GNU coreutils to work around the
 limitation of his system (this version should be old enough not to
-be bootstrapped with Automake 1.14, otherwise the user will face a
+be bootstrapped with Automake 2.0, otherwise the user will face a
 bootstrapping catch-22).
 
 In all our recipes, start assuming "rm -f" with no argument is OK;
 simplify and de-uglify the recipes accordingly.
 
-For Automake 1.15
------------------
+For Automake 3.0
+----------------
 
 Remove the runtime probe altogether.
diff --git a/PLANS/subdir-objects.txt b/PLANS/subdir-objects.txt
index e4e6e25..8647403 100644
--- a/PLANS/subdir-objects.txt
+++ b/PLANS/subdir-objects.txt
@@ -2,7 +2,7 @@ Summary
 -------
 
 We want to make the behaviour currently enabled by the 'subdir-objects'
-the default one, and in fact the *only* one, in Automake 1.14.
+the default one, and in fact the *only* one, in Automake 2.0.
 See automake bug#13378: <http://debbugs.gnu.org/13351>.
 
 Details
@@ -38,8 +38,8 @@ C compilation rules mistakenly passed the "-c -o" options 
combination
 unconditionally (even to losing compiler) when the 'subdir-objects' was
 used but sources were only present in the top-level directory.
 
-TODO for automake 1.13.2
-------------------------
+TODO for automake 1.14
+----------------------
 
 Give a warning in the category 'unsupported' if the 'subdir-objects'
 option is not specified.  This should give the users enough forewarning
@@ -50,8 +50,8 @@ Be sure to avoid the warning when it would be irrelevant, 
i.e., if all
 source files sit in "current" directory (thanks to Peter Johansson for
 suggesting this).
 
-For automake 1.14
------------------
+For automake 2.0
+----------------
 
 Remove the copy & paste of Autoconf internals in our AC_PROG_CC rewrite
 See the first patch in the series:
diff --git a/PLANS/texi/drop-split-info-files.txt 
b/PLANS/texi/drop-split-info-files.txt
index 7084331..8b36ecb 100644
--- a/PLANS/texi/drop-split-info-files.txt
+++ b/PLANS/texi/drop-split-info-files.txt
@@ -1,7 +1,7 @@
-For automake 1.14
------------------
+For automake 2.0
+----------------
 
-We want to drop split info files in Automake 1.14.
+We want to drop split info files in Automake 2.0.
 See automake bug#13351: <http://debbugs.gnu.org/13351>.
 
 Basically, it has been confirmed that the original reason behind
diff --git a/THANKS b/THANKS
index 66498d4..c8ec3fd 100644
--- a/THANKS
+++ b/THANKS
@@ -48,6 +48,7 @@ Bob Friesenhahn                 address@hidden
 Bob Proulx                      address@hidden
 Bob Rossi                       address@hidden
 Bobby Jack                      address@hidden
+Boris Kolpackov                 address@hidden
 Braden N. McDaniel              address@hidden
 Brandon Black                   address@hidden
 Brendan O'Dea                   address@hidden
@@ -297,6 +298,7 @@ Paul Jarc                       address@hidden
 Paul Lunau                      address@hidden
 Paul Martinolich                address@hidden
 Paul Thomas                     address@hidden
+Pavel Raiskup                   address@hidden
 Pavel Roskin                    address@hidden
 Pavel Sanda                     address@hidden
 Per Bothner                     address@hidden
diff --git a/aclocal.in b/aclocal.in
index 98f606f..df60d9c 100644
--- a/aclocal.in
+++ b/aclocal.in
@@ -46,7 +46,7 @@ use File::Path ();
 # Some globals.
 
 # Support AC_CONFIG_MACRO_DIRS also with older autoconf.
-# FIXME: To be removed in Automake 1.14, once we can assume autoconf
+# FIXME: To be removed in Automake 2.0, once we can assume autoconf
 #        2.70 or later.
 # FIXME: keep in sync with 'internal/ac-config-macro-dirs.m4'.
 my $ac_config_macro_dirs_fallback =
@@ -165,6 +165,11 @@ my @ac_config_macro_dirs;
 # If set, names a temporary file that must be erased on abnormal exit.
 my $erase_me;
 
+# Constants for the $ERR_LEVEL parameter of the 'scan_m4_dirs' function.
+use constant SCAN_M4_DIRS_SILENT => 0;
+use constant SCAN_M4_DIRS_WARN => 1;
+use constant SCAN_M4_DIRS_ERROR => 2;
+
 ################################################################
 
 # Prototypes for all subroutines.
@@ -335,21 +340,42 @@ sub list_compare (address@hidden@)
 
 ################################################################
 
-# scan_m4_dirs($TYPE, $ERR_ON_NONEXISTING, @DIRS)
+# scan_m4_dirs($TYPE, $ERR_LEVEL, @DIRS)
 # -----------------------------------------------
 # Scan all M4 files installed in @DIRS for new macro definitions.
 # Register each file as of type $TYPE (one of the FT_* constants).
+# If a directory in @DIRS cannot be read:
+#  - fail hard                if $ERR_LEVEL == SCAN_M4_DIRS_ERROR
+#  - just print a warning     if $ERR_LEVEL == SCAN_M4_DIRS_WA
+#  - continue silently        if $ERR_LEVEL == SCAN_M4_DIRS_SILENT
 sub scan_m4_dirs ($$@)
 {
-  my ($type, $err_on_nonexisting, @dirlist) = @_;
+  my ($type, $err_level, @dirlist) = @_;
 
   foreach my $m4dir (@dirlist)
     {
       if (! opendir (DIR, $m4dir))
        {
          # TODO: maybe avoid complaining only if errno == ENONENT?
-         next unless $err_on_nonexisting;
-         fatal "couldn't open directory '$m4dir': $!";
+          my $message = "couldn't open directory '$m4dir': $!";
+
+          if ($err_level == SCAN_M4_DIRS_ERROR)
+            {
+              fatal $message;
+            }
+          elsif ($err_level == SCAN_M4_DIRS_WARN)
+            {
+              msg ('unsupported', $message);
+              next;
+            }
+          elsif ($err_level == SCAN_M4_DIRS_SILENT)
+            {
+              next; # Silently ignore.
+            }
+          else
+            {
+               prog_error "invalid \$err_level value '$err_level'";
+            }
        }
 
       # We reverse the directory contents so that foo2.m4 gets
@@ -386,13 +412,27 @@ sub scan_m4_files ()
 
   if (@user_includes)
     {
+      # Don't explore the same directory multiple times.  This is here not
+      # only for speedup purposes.  We need this when the user has e.g.
+      # specified 'ACLOCAL_AMFLAGS = -I m4' and has also set
+      # AC_CONFIG_MACRO_DIR[S]([m4]) in configure.ac.  This makes the 'm4'
+      # directory to occur twice here and fail on the second call to
+      # scan_m4_dirs([m4]) when the 'm4' directory doesn't exist.
+      # TODO: Shouldn't there be rather a check in scan_m4_dirs for
+      #       @user_includes[0]?
+      @user_includes = uniq @user_includes;
+
       # Don't complain if the first user directory doesn't exist, in case
       # we need to create it later (can happen if '--install' was given).
-      scan_m4_dirs (FT_USER, !$install, $user_includes[0]);
-      scan_m4_dirs (FT_USER, 1, @user_includes[1..$#user_includes]);
+      scan_m4_dirs (FT_USER,
+                    $install ? SCAN_M4_DIRS_SILENT : SCAN_M4_DIRS_WARN,
+                    $user_includes[0]);
+      scan_m4_dirs (FT_USER,
+                    SCAN_M4_DIRS_ERROR,
+                   @user_includes[1..$#user_includes]);
     }
-  scan_m4_dirs (FT_SYSTEM,   1, @system_includes);
-  scan_m4_dirs (FT_AUTOMAKE, 1, @automake_includes);
+  scan_m4_dirs (FT_SYSTEM, SCAN_M4_DIRS_ERROR, @system_includes);
+  scan_m4_dirs (FT_AUTOMAKE, SCAN_M4_DIRS_ERROR, @automake_includes);
 
   # Construct a new function that does the searching.  We use a
   # function (instead of just evaluating $search in the loop) so that
@@ -724,7 +764,7 @@ sub trace_used_macros ()
   # a bug in option parsing code of autom4te 2.68 and earlier will cause
   # it to read standard input last, even if the "-" argument is specified
   # early.
-  # FIXME: To be removed in Automake 1.14, once we can assume autoconf
+  # FIXME: To be removed in Automake 2.0, once we can assume autoconf
   #        2.70 or later.
   $traces .= "$automake_includes[0]/internal/ac-config-macro-dirs.m4 ";
 
@@ -743,7 +783,7 @@ sub trace_used_macros ()
                     'AC_CONFIG_MACRO_DIR_TRACE',
                      # FIXME: Tracing the next two macros is a hack for
                      # compatibility with older autoconf.  Remove this in
-                     # Automake 1.14, when we can assume Autoconf 2.70 or
+                     # Automake 2.0, when we can assume Autoconf 2.70 or
                      # later.
                     'AC_CONFIG_MACRO_DIR',
                     '_AM_CONFIG_MACRO_DIRS')),
@@ -800,7 +840,7 @@ sub trace_used_macros ()
   # FIXME: in Autoconf >= 2.70, AC_CONFIG_MACRO_DIR calls
   # AC_CONFIG_MACRO_DIR_TRACE behind the scenes, which could
   # leave unwanted duplicates in @ac_config_macro_dirs.
-  # Remove this in Automake 1.14, when we'll stop tracing
+  # Remove this in Automake 2.0, when we'll stop tracing
   # AC_CONFIG_MACRO_DIR explicitly.
   @ac_config_macro_dirs = uniq @ac_config_macro_dirs;
 
diff --git a/automake.in b/automake.in
index 02c6d41..2843904 100644
--- a/automake.in
+++ b/automake.in
@@ -1061,11 +1061,9 @@ sub define_verbose_var ($$;$)
       if (! vardef ($verbose_var, TRUE));
 }
 
-# Above should not be needed in the general automake code.
-
 # verbose_flag (NAME)
 # -------------------
-# Contents of %VERBOSE%: variable to expand before rule command.
+# Contents of '%VERBOSE%' variable to expand before rule command.
 sub verbose_flag ($)
 {
     my ($name) = @_;
@@ -1095,8 +1093,6 @@ sub define_verbose_tagvar ($)
     define_verbose_var ($name, '@echo "  '. $name . ' ' x (8 - length ($name)) 
. '" $@;');
 }
 
-# define_verbose_texinfo
-# ----------------------
 # Engage the needed silent rules machinery for assorted texinfo commands.
 sub define_verbose_texinfo ()
 {
@@ -1109,8 +1105,6 @@ sub define_verbose_texinfo ()
   define_verbose_var('texidevnull', '> /dev/null');
 }
 
-# define_verbose_libtool
-# ----------------------
 # Engage the needed silent rules machinery for 'libtool --silent'.
 sub define_verbose_libtool ()
 {
@@ -1708,7 +1702,7 @@ sub handle_single_transform ($$$$$%)
                 }
               else
                 {
-                  # Since the next major version of automake (1.14) will
+                  # Since the next major version of automake (2.0) will
                   # make the behaviour so far only activated with the
                   # 'subdir-object' option mandatory, it's better if we
                   # start warning users not using that option.
@@ -2062,7 +2056,7 @@ sub handle_source_transform ($$$$%)
        msg_var ('unsupported', $ext_var, $ext_var->name . " can assume at most 
one value")
          if $default_source_ext =~ /[\t ]/;
        (my $default_source = $unxformed) =~ 
s,(\.[^./\\]*)?$,$default_source_ext,;
-       # TODO: Remove this backward-compatibility hack in Automake 1.14.
+       # TODO: Remove this backward-compatibility hack in Automake 2.0.
        if ($old_default_source ne $default_source
            && !$ext_var
            && (rule $old_default_source
@@ -2293,7 +2287,7 @@ sub handle_ALLOCA ($$$)
   saw_extension ('.c');
 }
 
-# Canonicalize the input parameter
+# Canonicalize the input parameter.
 sub canonicalize ($)
 {
     my ($string) = @_;
@@ -2320,9 +2314,6 @@ sub check_canonical_spelling ($@)
   return $xname;
 }
 
-
-# handle_compile ()
-# -----------------
 # Set up the compile suite.
 sub handle_compile ()
 {
@@ -2377,8 +2368,6 @@ sub handle_compile ()
     $output_rules .= "$coms$rules";
 }
 
-# handle_libtool ()
-# -----------------
 # Handle libtool rules.
 sub handle_libtool ()
 {
@@ -2406,9 +2395,7 @@ sub handle_libtool ()
                                   LTRMS => join ("\n", @libtool_rms));
 }
 
-# handle_programs ()
-# ------------------
-# Handle C programs.
+
 sub handle_programs ()
 {
   my @proglist = am_install_var ('progs', 'PROGRAMS',
@@ -2498,9 +2485,6 @@ sub handle_programs ()
 }
 
 
-# handle_libraries ()
-# -------------------
-# Handle libraries.
 sub handle_libraries ()
 {
   my @liblist = am_install_var ('libs', 'LIBRARIES',
@@ -2611,9 +2595,6 @@ sub handle_libraries ()
 }
 
 
-# handle_ltlibraries ()
-# ---------------------
-# Handle shared libraries.
 sub handle_ltlibraries ()
 {
   my @liblist = am_install_var ('ltlib', 'LTLIBRARIES',
@@ -2883,7 +2864,6 @@ sub check_typos ()
 }
 
 
-# Handle scripts.
 sub handle_scripts ()
 {
     # NOTE we no longer automatically clean SCRIPTS, because it is
@@ -2895,8 +2875,6 @@ sub handle_scripts ()
 }
 
 
-
-
 ## ------------------------ ##
 ## Handling Texinfo files.  ##
 ## ------------------------ ##
@@ -3055,7 +3033,7 @@ sub output_texinfo_build_rules ($$$@)
 # ($MOSTLYCLEAN, $TEXICLEAN, $MAINTCLEAN)
 # handle_texinfo_helper ($info_texinfos)
 # --------------------------------------
-# Handle all Texinfo source; helper for handle_texinfo.
+# Handle all Texinfo source; helper for 'handle_texinfo'.
 sub handle_texinfo_helper ($)
 {
   my ($info_texinfos) = @_;
@@ -3375,9 +3353,6 @@ EOF
 }
 
 
-# handle_texinfo ()
-# -----------------
-# Handle all Texinfo source.
 sub handle_texinfo ()
 {
   reject_var 'TEXINFOS', "'TEXINFOS' is an anachronism; use 'info_TEXINFOS'";
@@ -3406,7 +3381,6 @@ sub handle_texinfo ()
 }
 
 
-# Handle any man pages.
 sub handle_man_pages ()
 {
   reject_var 'MANS', "'MANS' is an anachronism; use 'man_MANS'";
@@ -3545,7 +3519,7 @@ sub handle_man_pages ()
     unless option 'no-installman';
 }
 
-# Handle DATA variables.
+
 sub handle_data ()
 {
     am_install_var ('-noextra', '-candist', 'data', 'DATA',
@@ -3554,7 +3528,7 @@ sub handle_data ()
                     'pkgdata', 'lisp', 'noinst', 'check');
 }
 
-# Handle TAGS.
+
 sub handle_tags ()
 {
     my @config;
@@ -3622,8 +3596,6 @@ sub user_phony_rule ($)
 }
 
 
-# handle_dist
-# -----------
 # Handle 'dist' target.
 sub handle_dist ()
 {
@@ -3816,9 +3788,7 @@ sub check_directories_in_var ($)
      skip_ac_subst => 1);
 }
 
-# handle_subdirs ()
-# -----------------
-# Handle subdirectories.
+
 sub handle_subdirs ()
 {
   my $subdirs = var ('SUBDIRS');
@@ -3866,7 +3836,7 @@ sub scan_aclocal_m4 ()
 }
 
 
-# Helper function for substitute_ac_subst_variables.
+# Helper function for 'substitute_ac_subst_variables'.
 sub substitute_ac_subst_variables_worker($)
 {
   my ($token) = @_;
@@ -4095,8 +4065,8 @@ sub handle_configure ($$$@)
   # Distribute and define mkinstalldirs only if it is already present
   # in the package, for backward compatibility (some people may still
   # use $(mkinstalldirs)).
-  # TODO: start warning about this in Automake 1.13.2, and have
-  # TODO: Automake 1.14 or 1.15 drop it (and the mkinstalldirs script
+  # TODO: start warning about this in Automake 1.14, and have
+  # TODO: Automake 2.0 drop it (and the mkinstalldirs script
   # TODO: as well).
   my $mkidpath = "$config_aux_dir/mkinstalldirs";
   if (-f $mkidpath)
@@ -4272,7 +4242,6 @@ sub handle_configure ($$$@)
                          @actual_other_vpath_files);
 }
 
-# Handle C headers.
 sub handle_headers ()
 {
     my @r = am_install_var ('-defaultdist', 'header', 'HEADERS', 'include',
@@ -4341,7 +4310,7 @@ sub handle_gettext ()
   require_file ($ac_gettext_location, GNU, 'ABOUT-NLS');
 }
 
-# Handle footer elements.
+# Emit makefile footer.
 sub handle_footer ()
 {
     reject_rule ('.SUFFIXES',
@@ -4393,7 +4362,7 @@ sub handle_install ()
 }
 
 
-# Deal with all and all-am.
+# Deal with 'all' and 'all-am'.
 sub handle_all ($)
 {
     my ($makefile) = @_;
@@ -4454,7 +4423,7 @@ sub handle_all ($)
       }
 }
 
-# Generate helper targets for user recursion, where needed.
+# Generate helper targets for user-defined recursive targets, where needed.
 sub handle_user_recursion ()
 {
   return unless @extra_recursive_targets;
@@ -4481,8 +4450,6 @@ sub handle_user_recursion ()
 }
 
 
-# do_check_merge_target ()
-# ------------------------
 # Handle check merge target specially.
 sub do_check_merge_target ()
 {
@@ -4519,8 +4486,6 @@ sub do_check_merge_target ()
     if var ('BUILT_SOURCES');
 }
 
-# handle_clean ($MAKEFILE)
-# ------------------------
 # Handle all 'clean' targets.
 sub handle_clean ($)
 {
@@ -4590,8 +4555,6 @@ sub target_cmp
 }
 
 
-# handle_factored_dependencies ()
-# -------------------------------
 # Handle everything related to gathered targets.
 sub handle_factored_dependencies ()
 {
@@ -4678,8 +4641,6 @@ sub handle_factored_dependencies ()
 }
 
 
-# handle_tests_dejagnu ()
-# -----------------------
 sub handle_tests_dejagnu ()
 {
     push (@check_tests, 'check-DEJAGNU');
@@ -4749,7 +4710,7 @@ sub is_valid_test_extension ($)
   return 0;
 }
 
-# Handle TESTS variable and other checks.
+
 sub handle_tests ()
 {
   if (option 'dejagnu')
@@ -4883,7 +4844,6 @@ sub handle_tests ()
     }
 }
 
-# Handle Emacs Lisp.
 sub handle_emacs_lisp ()
 {
   my @elfiles = am_install_var ('-candist', 'lisp', 'LISP',
@@ -4904,7 +4864,6 @@ sub handle_emacs_lisp ()
                     'EMACS', 'lispdir');
 }
 
-# Handle Python
 sub handle_python ()
 {
   my @pyfiles = am_install_var ('-defaultdist', 'python', 'PYTHON',
@@ -4916,7 +4875,6 @@ sub handle_python ()
   define_variable ('py_compile', "$am_config_aux_dir/py-compile", INTERNAL);
 }
 
-# Handle Java.
 sub handle_java ()
 {
     my @sourcelist = am_install_var ('-candist',
@@ -4961,7 +4919,6 @@ sub handle_java ()
 }
 
 
-# Handle some of the minor options.
 sub handle_minor_options ()
 {
   if (option 'readme-alpha')
@@ -5067,8 +5024,6 @@ sub scan_autoconf_config_files ($$)
 }
 
 
-# scan_autoconf_traces ($FILENAME)
-# --------------------------------
 sub scan_autoconf_traces ($)
 {
   my ($filename) = @_;
@@ -5364,9 +5319,7 @@ EOF
 }
 
 
-# scan_autoconf_files ()
-# -----------------------
-# Scan it (and possibly 'aclocal.m4') for interesting things.
+# Scan 'configure.ac' (and possibly 'aclocal.m4') for interesting things.
 # We must scan aclocal.m4 because there might be AC_SUBSTs and such there.
 sub scan_autoconf_files ()
 {
@@ -5896,9 +5849,7 @@ sub derive_suffix ($$)
 }
 
 
-################################################################
-
-# Pretty-print something and append to output_rules.
+# Pretty-print something and append to '$output_rules'.
 sub pretty_print_rule ($$@)
 {
     $output_rules .= makefile_wrap (shift, shift, @_);
@@ -6123,9 +6074,6 @@ sub define_compiler_variable ($)
 }
 
 
-# define_linker_variable ($LANG)
-# ------------------------------
-# Define linker variables.
 sub define_linker_variable ($)
 {
     my ($lang) = @_;
@@ -6505,8 +6453,6 @@ sub read_am_file ($$)
 }
 
 
-# define_standard_variables ()
-# ----------------------------
 # A helper for read_main_am_file which initializes configure variables
 # and variables from header-vars.am.
 sub define_standard_variables ()
@@ -6524,7 +6470,6 @@ sub define_standard_variables ()
   $output_vars .= $comments . $rules;
 }
 
-# Read main am file.
 sub read_main_am_file ($$)
 {
     my ($amfile, $infile) = @_;
@@ -6552,9 +6497,6 @@ sub read_main_am_file ($$)
 
 ################################################################
 
-# $FLATTENED
-# flatten ($STRING)
-# -----------------
 # Flatten the $STRING and return the result.
 sub flatten ($)
 {
@@ -6570,7 +6512,7 @@ sub flatten ($)
 
 
 # transform_token ($TOKEN, \%PAIRS, $KEY)
-# =======================================
+# ---------------------------------------
 # Return the value associated to $KEY in %PAIRS, as used on $TOKEN
 # (which should be ?KEY? or any of the special %% requests)..
 sub transform_token ($$$)
@@ -6583,7 +6525,7 @@ sub transform_token ($$$)
 
 
 # transform ($TOKEN, \%PAIRS)
-# ===========================
+# ---------------------------
 # If ($TOKEN, $VAL) is in %PAIRS:
 #   - replaces %KEY% with $VAL,
 #   - enables/disables ?KEY? and ?!KEY?,
@@ -7015,6 +6957,9 @@ sub am_primary_prefixes ($$@)
 }
 
 
+# am_install_var (-OPTION..., file, HOW, where...)
+# ------------------------------------------------
+#
 # Handle 'where_HOW' variable magic.  Does all lookups, generates
 # install code, and possibly generates code to define the primary
 # variable.  The first argument is the name of the .am file to munge,
@@ -7029,7 +6974,6 @@ sub am_primary_prefixes ($$@)
 # FIXME: this should be rewritten to be cleaner.  It should be broken
 # up into multiple functions.
 #
-# Usage is: am_install_var (OPTION..., file, HOW, where...)
 sub am_install_var (@)
 {
   my (@args) = @_;
@@ -7288,7 +7232,7 @@ sub locate_aux_dir ()
 
 
 # push_required_file ($DIR, $FILE, $FULLFILE)
-# -------------------------------------------------
+# -------------------------------------------
 # Push the given file onto DIST_COMMON.
 sub push_required_file ($$$)
 {
@@ -7684,7 +7628,7 @@ sub require_build_directory_maybe ($)
 
 ################################################################
 
-# Push a list of files onto dist_common.
+# Push a list of files onto '@dist_common'.
 sub push_dist_common (@)
 {
   prog_error "push_dist_common run after handle_dist"
@@ -7934,7 +7878,6 @@ sub print_autodist_files (@)
 }
 
 
-# Print usage information.
 sub usage ()
 {
     print "Usage: $0 [OPTION]... [Makefile]...
@@ -7985,9 +7928,6 @@ General help using GNU software: 
<http://www.gnu.org/gethelp/>.
 }
 
 
-# version ()
-# ----------
-# Print version information
 sub version ()
 {
   print <<EOF;
@@ -8071,9 +8011,6 @@ sub parse_arguments ()
 }
 
 
-# handle_makefile ($MAKEFILE_IN)
-# ------------------------------
-# Deal with $MAKEFILE_IN.
 sub handle_makefile ($)
 {
   my ($file) =  @_;
@@ -8094,8 +8031,6 @@ sub handle_makefile ($)
     }
 }
 
-# handle_makefiles_serial ()
-# --------------------------
 # Deal with all makefiles, without threads.
 sub handle_makefiles_serial ()
 {
@@ -8105,8 +8040,6 @@ sub handle_makefiles_serial ()
     }
 }
 
-# get_number_of_threads ()
-# ------------------------
 # Logic for deciding how many worker threads to use.
 sub get_number_of_threads ()
 {
diff --git a/lib/Automake/Options.pm b/lib/Automake/Options.pm
index 3932798..191e9d5 100644
--- a/lib/Automake/Options.pm
+++ b/lib/Automake/Options.pm
@@ -316,7 +316,7 @@ sub _process_option_list (\%@)
         {
           set_strictness ($_);
         }
-      # TODO: Remove this special check in Automake 1.14 or 1.15.
+      # TODO: Remove this special check in Automake 3.0.
       elsif (/^(.*\/)?ansi2knr$/)
         {
           # Obsolete (and now removed) de-ANSI-fication support.
@@ -328,7 +328,7 @@ sub _process_option_list (\%@)
         {
           error $where, "support for Cygnus-style trees has been removed";
         }
-      # TODO: Remove this special check in Automake 1.14 or 1.15.
+      # TODO: Remove this special check in Automake 3.0.
       elsif ($_ eq 'dist-lzma')
         {
           error ($where, "support for lzma-compressed distribution " .
diff --git a/m4/internal/ac-config-macro-dirs.m4 
b/m4/internal/ac-config-macro-dirs.m4
index 4ddcef3..2684883 100644
--- a/m4/internal/ac-config-macro-dirs.m4
+++ b/m4/internal/ac-config-macro-dirs.m4
@@ -1,5 +1,5 @@
 # Support AC_CONFIG_MACRO_DIRS with older autoconf.     -*- Autoconf -*-
-# FIXME: To be removed in Automake 1.14, once we can assume autoconf
+# FIXME: To be removed in Automake 2.0, once we can assume autoconf
 #        2.70 or later.
 # FIXME: keep in sync with the contents of the variable
 #        '$ac_config_macro_dirs_fallback' in aclocal.in.
diff --git a/t/aclocal-acdir.sh b/t/aclocal-acdir.sh
index 94faad6..e363e67 100755
--- a/t/aclocal-acdir.sh
+++ b/t/aclocal-acdir.sh
@@ -21,7 +21,7 @@
 . test-init.sh
 
 mkdir am sys
-# FIXME: remove in Automake 1.14.
+# FIXME: remove in Automake 2.0
 mkdir am/internal
 : > am/internal/ac-config-macro-dirs.m4
 
diff --git a/t/aclocal-macrodir.tap b/t/aclocal-macrodir.tap
index 3c66e53..fb80609 100755
--- a/t/aclocal-macrodir.tap
+++ b/t/aclocal-macrodir.tap
@@ -20,7 +20,7 @@
 am_create_testdir=empty
 . test-init.sh
 
-plan_ 6
+plan_ 7
 
 ocwd=$(pwd) || fatal_ "getting current working directory"
 ACLOCAL_PATH=; unset ACLOCAL_PATH
@@ -157,16 +157,44 @@ test_end
 
 #---------------------------------------------------------------------------
 
-test_begin "AC_CONFIG_MACRO_DIR([non-existent]) errors out (1)"
+test_begin "AC_CONFIG_MACRO_DIR([non-existent]) warns with -Wunsupported"
 
 cat > configure.ac << 'END'
 AC_INIT([oops], [1.0])
 AC_CONFIG_MACRO_DIR([non-existent])
+AM_INIT_AUTOMAKE
 END
 
-not $ACLOCAL -Wnone 2>stderr \
+$ACLOCAL -Wno-error 2>stderr \
   && cat stderr >&2 \
   && grep "couldn't open directory 'non-existent'" stderr \
+  && test -f aclocal.m4 \
+  || r='not ok'
+
+rm -rf aclocal.m4 autom4te*.cache
+
+$ACLOCAL -Werror -Wno-unsupported \
+  && test -f aclocal.m4 \
+  || r='not ok'
+
+test_end
+
+#---------------------------------------------------------------------------
+
+test_begin "AC_CONFIG_MACRO_DIR([not-exist]) and ACLOCAL_AMFLAGS = -I 
not-exist"
+
+cat > configure.ac << 'END'
+AC_INIT([oops], [1.0])
+AC_CONFIG_MACRO_DIR([not-exist])
+END
+
+cat > Makefile.am << 'END'
+ACLOCAL_AMFLAGS = -I not-exist
+END
+
+$ACLOCAL -Wno-error 2>stderr \
+  && cat stderr >&2 \
+  && test $(grep -c "couldn't open directory 'not-exist'" stderr) -eq 1 \
   || r='not ok'
 
 test_end
@@ -174,7 +202,7 @@ test_end
 #---------------------------------------------------------------------------
 
 # Avoid spurious failures with pre-2.70 autoconf.
-# FIXME: remove this in automake 1.14, once we require Autoconf 2.70.
+# FIXME: remove this in automake 2.0, once we require Autoconf 2.70.
 if echo 'AC_INIT AC_CONFIG_MACRO_DIRS' | $AUTOCONF -o/dev/null -; then
 
   test_begin "AC_CONFIG_MACRO_DIR interaction with AC_REQUIRE"
diff --git a/t/aclocal-macrodirs.tap b/t/aclocal-macrodirs.tap
index 89e424d..0898c29 100755
--- a/t/aclocal-macrodirs.tap
+++ b/t/aclocal-macrodirs.tap
@@ -20,7 +20,7 @@
 am_create_testdir=empty
 . test-init.sh
 
-plan_ 14
+plan_ 15
 
 ocwd=$(pwd) || fatal_ "getting current working directory"
 ACLOCAL_PATH=; unset ACLOCAL_PATH
@@ -317,23 +317,31 @@ test_end
 
 #---------------------------------------------------------------------------
 
-test_begin "AC_CONFIG_MACRO_DIRS([non-existent]) errors out (1)"
+test_begin "AC_CONFIG_MACRO_DIRS([non-existent]) warns (1)"
 
 cat > configure.ac << 'END'
 AC_INIT([oops], [1.0])
 AC_CONFIG_MACRO_DIRS([non-existent])
+AM_INIT_AUTOMAKE
 END
 
-not $ACLOCAL 2>stderr \
+$ACLOCAL -Wno-error 2>stderr \
   && cat stderr >&2 \
   && grep "couldn't open directory 'non-existent'" stderr \
+  && test -f aclocal.m4 \
+  || r='not ok'
+
+rm -rf aclocal.m4 autom4te*.cache
+
+$ACLOCAL -Werror -Wno-unsupported \
+  && test -f aclocal.m4 \
   || r='not ok'
 
 test_end
 
 #---------------------------------------------------------------------------
 
-test_begin "AC_CONFIG_MACRO_DIRS([non-existent]) errors out (2)"
+test_begin "AC_CONFIG_MACRO_DIRS([non-existent]) warns (2)"
 
 cat > configure.ac << 'END'
 AC_INIT([oops], [1.0])
@@ -346,13 +354,14 @@ not $ACLOCAL 2>stderr \
   && cat stderr >&2 \
   && grep "couldn't open directory 'dir-ko'" stderr \
   && not grep "dir-ok" stderr \
+  && test ! -e aclocal.m4 \
   || r='not ok'
 
 test_end
 
 #---------------------------------------------------------------------------
 
-test_begin "AC_CONFIG_MACRO_DIRS([non-existent]) errors out (tricky setup)"
+test_begin "AC_CONFIG_MACRO_DIRS([existent non-existent]) errors out"
 
 cat > configure.ac << 'END'
 AC_INIT([oops], [1.0])
@@ -372,8 +381,28 @@ test_end
 
 #---------------------------------------------------------------------------
 
+test_begin "AC_CONFIG_MACRO_DIRS([not-exist]) and ACLOCAL_AMFLAGS = -I 
not-exist"
+
+cat > configure.ac << 'END'
+AC_INIT([oops], [1.0])
+AC_CONFIG_MACRO_DIRS([not-exist])
+END
+
+cat > Makefile.am << 'END'
+ACLOCAL_AMFLAGS = -I not-exist
+END
+
+$ACLOCAL -Wno-error 2>stderr \
+  && cat stderr >&2 \
+  && test $(grep -c "couldn't open directory 'not-exist'" stderr) -eq 1 \
+  || r='not ok'
+
+test_end
+
+#---------------------------------------------------------------------------
+
 # Avoid spurious failures with pre-2.70 autoconf.
-# FIXME: remove this in automake 1.14, once we require Autoconf 2.70.
+# FIXME: remove this in automake 2.0, once we require Autoconf 2.70.
 if echo 'AC_INIT AC_CONFIG_MACRO_DIRS' | $AUTOCONF -o/dev/null -; then
 
   test_begin "AC_CONFIG_MACRO_DIRS interaction with AC_REQUIRE"
diff --git a/t/make-dryrun.tap b/t/make-dryrun.tap
index 14d379a..1459a9f 100755
--- a/t/make-dryrun.tap
+++ b/t/make-dryrun.tap
@@ -18,15 +18,20 @@
 
 . test-init.sh
 
-plan_ 14
+plan_ 18
 
-if echo "all: ; @+printf %sbb%s aa cc" | $MAKE -n -f - | grep aabbcc; then
+if echo "all: ; address@hidden %sbb%s aa cc" | $MAKE -n -f - | grep aabbcc; 
then
   make_plus_silence () { return 0; }
 else
   make_plus_silence () { return 1; }
 fi
 
-mkdir sub
+mkdir none
+if echo nil: | $MAKE -I none -f -; then
+  make_supports_option_I () { return 0; }
+else
+  make_supports_option_I () { return 1; }
+fi
 
 echo AC_OUTPUT >> configure.ac
 
@@ -35,14 +40,48 @@ all:
        : Dummy, nothing to do.
 foo:
        $(MAKE) all
-notdry:
+run:
        @echo ":: $$MAKEFLAGS ::"; : For debugging.
-       $(am__make_dryrun) && exit 1; exit 0
+       $(am__make_dryrun) && exit 1; echo ok > from-run
 dry:
        address@hidden ":: $$MAKEFLAGS ::"; : For debugging.
-       +$(am__make_dryrun) || exit 1; echo ok > from-dry-mode
+       +$(am__make_dryrun) || exit 1; echo ok > from-dry
 END
 
+check_make ()
+{
+  r=ok msg= mode= condition=: directive= reason= skip_reason=
+  case $1 in
+    --dry) mode=dry;;
+    --run) mode=run;;
+    *) fatal_ "check_run: invalid usage";;
+  esac
+  shift
+  while test $# -gt 0; do
+    case $1 in
+      -C) condition=$2 skip_reason=$3; shift; shift;;
+      -M) msg=$2; shift;;
+      -X) directive=TODO;;
+      --) shift; break;;
+       *) break;;
+    esac
+    shift
+  done
+  msg=${mode}${msg:+" [$msg]"}
+  if $condition; then
+    $MAKE "$mode" ${1+"$@"} || r='not ok'
+    test -f from-$mode      || r='not ok'
+    test ! -e bad           || r='not ok'
+    rm -f bad from-*        || fatal_ "cleaning up"
+  else
+    directive=SKIP reason=$skip_reason
+  fi
+  result_ "$r" -D "$directive" -r "$reason" "$msg"
+  unset r msg mode condition directive reason skip_reason
+}
+
+# ----------------------------------------------------------------------
+
 $ACLOCAL    || fatal_ "aclocal failed"
 $AUTOCONF   || fatal_ "autoconf failed"
 $AUTOMAKE   || fatal_ "automake failed"
@@ -50,48 +89,40 @@ $AUTOMAKE   || fatal_ "automake failed"
 
 # ----------------------------------------------------------------------
 
-check_no_dryrun ()
-{
-  command_ok_ "dry-run ($cnt)" $MAKE notdry ${1+"$@"}
-  cnt=$(($cnt + 1))
-}
-cnt=1
-
-check_no_dryrun
+check_make --run
 
 # Test against a known regression.  This was especially heinous, since
 # make running in normal mode was sometimes mistaken for make running
 # in dry mode.
-check_no_dryrun TESTS="n1.test n2.test"
-check_no_dryrun TESTS="n1 n2" AM_MAKEFLAGS="TESTS='n1 n2'"
-check_no_dryrun TESTS="n1 n2" AM_MAKEFLAGS='TESTS="n1 n2"'
-check_no_dryrun FOOFLAGS="-n -n -knf2 n --none -n"
-check_no_dryrun MYFLAGS="-n --dryrun -n --dry-run -n"
+check_make --run TESTS="n1.test n2.test"
+check_make --run TESTS="n1 n2" AM_MAKEFLAGS="TESTS='n1 n2'"
+check_make --run TESTS="n1 n2" AM_MAKEFLAGS='TESTS="n1 n2"'
+check_make --run FOOFLAGS="-n -n -knf2 n --none -n"
+check_make --run MYFLAGS="-n --dryrun -n --dry-run -n"
 
 # ----------------------------------------------------------------------
 
-check_dryrun ()
-{
-  r=ok directive=
-  case $1 in
-    -C) condition=$2 reason=$3; shift; shift; shift;;
-     *) condition=: reason=;;
-  esac
-  if $condition; then
-    $MAKE dry ${1+"$@"}   || r='not ok'
-    test -f from-dry-mode || r='not ok'
-    rm -f from-dry-mode   || fatal_ "cleaning up"
-  else
-    directive=SKIP
-  fi
-  result_ "$r" -D "$directive" -r "$reason" "not dry-run ($cnt)"
-  unset r directive reason
-  cnt=$(($cnt + 1))
-}
-cnt=1
+check_make --dry -C make_plus_silence 'recipe prefix "+" unsupported' -n
+check_make --dry -C using_gmake "\$MAKE is not GNU make" --dry-run -k
+
+# ----------------------------------------------------------------------
 
-check_dryrun -C make_plus_silence 'recipe prefix "+" unsupported' -n
-check_dryrun -C using_gmake "\$MAKE is not GNU make" --dry-run -k
+# Automake bug#13760: the "n" in "none" used to confound am__make_dryrun
+# into thinking the '-n' option had been passed.
+
+pr='bug#13760'
+
+check_make --run -X -C make_supports_option_I "-I make option unsupported" \
+                 -M "$pr" -I none
+
+check_make --run -X -C using_gmake "\$MAKE is not GNU make" \
+                 -M "$pr" -I none --include dry-run 
+
+check_make --dry -C make_supports_option_I "-I make option unsupported" \
+                 -M "$pr" -I none -n
+
+check_make --dry -C using_gmake "\$MAKE is not GNU make" \
+                 -M "$pr" --dry-run -I none --include dry-run
 
 # ----------------------------------------------------------------------
 
@@ -99,18 +130,8 @@ check_dryrun -C using_gmake "\$MAKE is not GNU make" 
--dry-run -k
 
 check_metachars ()
 {
-  r=ok
-  $MAKE notdry ${1+"$@"} || r='not ok'
-  if test -f bad; then
-    r='not ok'
-  else
-    rm -f bad || fatal_ "cleaning up"
-  fi
-  result_ "$r" "dry-run, with shell metachars ($cnt)"
-  unset r
-  cnt=$(($cnt + 1))
+  check_make --run -M "metachars" "$@"
 }
-cnt=1
 
 check_metachars MYFLAGS="-n \"n\" '-n' --none -n"
 check_metachars MYFLAGS='-knf2\ n\ \\n'


hooks/post-receive
-- 
GNU Automake



reply via email to

[Prev in Thread] Current Thread [Next in Thread]