automake-commit
[Top][All Lists]
Advanced

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

[Automake-commit] [SCM] GNU Automake branch, maint, updated. v1.13.1b-96


From: Stefano Lattarini
Subject: [Automake-commit] [SCM] GNU Automake branch, maint, updated. v1.13.1b-96-gb4dbcb7
Date: Thu, 21 Feb 2013 16:03:07 +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=b4dbcb75f1c70d648c96dd0ec95aac6eaafecdef

The branch, maint has been updated
       via  b4dbcb75f1c70d648c96dd0ec95aac6eaafecdef (commit)
       via  d5f83b89cc4d2da9078669018877b3bac5c2fadc (commit)
       via  a8933e87ca570f3e710559b12cddad4473525c19 (commit)
       via  7a3d7cee2b3270443bcd3b91e7e4ada8a1a858a1 (commit)
       via  c83c133556205402d44e81d492efb0b2fe3e3584 (commit)
      from  b4f36584ba52eea885fcd89e5f404f09312ae430 (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 -----------------------------------------------------------------
-----------------------------------------------------------------------

Summary of changes:
 NEWS                                       |    7 +++
 PLANS/obsolete-removed/am-prog-mkdir-p.txt |    8 +--
 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                                     |    1 +
 aclocal.in                                 |   56 ++++++++++++++++++++++++----
 automake.in                                |    2 +-
 t/aclocal-macrodir.tap                     |   34 +++++++++++++++-
 t/aclocal-macrodirs.tap                    |   39 +++++++++++++++++--
 11 files changed, 143 insertions(+), 40 deletions(-)

diff --git a/NEWS b/NEWS
index fbd5761..167f3df 100644
--- a/NEWS
+++ b/NEWS
@@ -194,6 +194,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 d5b7695..20d5cf5 100644
--- a/PLANS/obsolete-removed/am-prog-mkdir-p.txt
+++ b/PLANS/obsolete-removed/am-prog-mkdir-p.txt
@@ -1,6 +1,4 @@
-The macro AM_PROG_MKDIR_P is no longer going to be removed in Automake 1.14
-(and in fact, any plan to remove it "evenatually" has been dropped as well).
-
+The macro AM_PROG_MKDIR_P is no longer going to be removed from Automake.
 Let's see a bit of history to understand why.
 
 I had already scheduled the removal of the long-deprecated AM_PROG_MKDR_P
@@ -46,14 +44,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 d591d14..c8ec3fd 100644
--- a/THANKS
+++ b/THANKS
@@ -298,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 13e9aa5..ba30479 100644
--- a/aclocal.in
+++ b/aclocal.in
@@ -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_AUTOMAKE, 1, @automake_includes);
-  scan_m4_dirs (FT_SYSTEM,   1, @system_includes);
+  scan_m4_dirs (FT_AUTOMAKE, SCAN_M4_DIRS_ERROR, @automake_includes);
+  scan_m4_dirs (FT_SYSTEM, SCAN_M4_DIRS_ERROR, @system_includes);
 
   # Construct a new function that does the searching.  We use a
   # function (instead of just evaluating $search in the loop) so that
diff --git a/automake.in b/automake.in
index 44d67b4..13811f7 100644
--- a/automake.in
+++ b/automake.in
@@ -1711,7 +1711,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.
diff --git a/t/aclocal-macrodir.tap b/t/aclocal-macrodir.tap
index 44af05f..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
diff --git a/t/aclocal-macrodirs.tap b/t/aclocal-macrodirs.tap
index ac594bb..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,6 +381,26 @@ 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 2.0, once we require Autoconf 2.70.
 if echo 'AC_INIT AC_CONFIG_MACRO_DIRS' | $AUTOCONF -o/dev/null -; then


hooks/post-receive
-- 
GNU Automake



reply via email to

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