]> git.ipfire.org Git - thirdparty/autoconf.git/commitdiff
* bin/autoreconf.in (&autoreconf): Set `$aclocal_flags' to ''.
authorAkim Demaille <akim@epita.fr>
Fri, 2 Nov 2001 16:28:33 +0000 (16:28 +0000)
committerAkim Demaille <akim@epita.fr>
Fri, 2 Nov 2001 16:28:33 +0000 (16:28 +0000)
Don't run aclocal when aclocal.m4 is not from aclocal.
From Ezra Peisach.
Don't run libtoolize and gettextize if --install is not given.

ChangeLog
bin/autoreconf.in
man/autoreconf.1

index 20d1c1edbdccd35773c44cade889485f576b1e65..9f901013220d7a22ba3805014b535df98aa3a678 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,10 +1,17 @@
+2001-11-02  Akim Demaille  <akim@epita.fr>
+
+       * bin/autoreconf.in (&autoreconf): Set `$aclocal_flags' to ''.
+       Don't run aclocal when aclocal.m4 is not from aclocal.
+       From Ezra Peisach.
+       Don't run libtoolize and gettextize if --install is not given.
+
 2001-11-01  Paul Eggert  <eggert@twinsun.com>
 
        * lib/m4sugar/m4sh.m4 (AS_SHELL_SANITIZE): _AS_CR_PREPARE needs to
        be invoked before _AS_LINENO_PREPARE.
         (_AS_LINENO_PREPARE): Use as_cr_digits and as_cr_alnum rather
        than character ranges.
-       
+
        * lib/m4sugar/m4sh.m4 (AS_SHELL_SANITIZE): Fix NLS before
        invoking AS_BASENAME.  Set the locale variables to 'C' if
        possible, as POSIX requires this to get the traditional
index 1c87b2e9c7efa309b809a569e8f179111c95ce5b..2e5f0a74c4dd486b9960bea7d1f2e0ec8adf4dfd 100644 (file)
@@ -212,6 +212,7 @@ sub autoreconf ($)
   my $uses_gettext;
   my $uses_libtool;
   my $uses_autoheader;
+  my $uses_aclocal;
   while ($_ = $configure_ac_file->getline)
      {
        $uses_autoconf = 1
@@ -254,10 +255,14 @@ sub autoreconf ($)
     {
       verbose "$configure_ac: not running gettextize: `intl' is already present";
     }
-  else
+  elsif ($install)
     {
       xsystem ($gettextize);
     }
+  else
+    {
+      verbose "$configure_ac: not running gettextize: --install not given";
+    }
 
 
   # -------------------- #
@@ -268,37 +273,61 @@ sub autoreconf ($)
     {
       verbose "$configure_ac: not using Libtool";
     }
-  else
+  elsif ($install)
     {
       xsystem ($libtoolize);
     }
+  else
+    {
+      verbose "$configure_ac: not running libtoolize: --install not given";
+    }
 
 
   # ----------------- #
   # Running aclocal.  #
   # ----------------- #
 
-  # Always run aclocal.  Tracking its sources for up-to-dateness
-  # is too complex and too error prone.  The best we can do is
-  # avoiding nuking the time stamp.
+  # Always run aclocal.  Tracking its sources for up-to-dateness is
+  # too complex and too error prone.  The best we can do is avoiding
+  # nuking the time stamp.
+  $uses_aclocal = 1;
+
+  # Nevertheless, if aclocal.m4 exists and is not made by aclocal,
+  # don't run aclocal.
+
+  if (-f 'aclocal.m4')
+    {
+      my $aclocal_m4 = new Autom4te::XFile 'aclocal.m4';
+      $_ = $aclocal_m4->getline;
+      $uses_aclocal = 0
+       unless /generated.*by aclocal/;
+    }
 
   # If there are flags for aclocal in Makefile.am, use them.
-  my $aclocal_flags;
+  my $aclocal_flags = '';
   if (-f 'Makefile.am')
     {
-      my $aclocal_m4 = new Autom4te::XFile 'Makefile.am';
-      while ($_ = $aclocal_m4->getline)
+      my $makefile = new Autom4te::XFile 'Makefile.am';
+      while ($_ = $makefile->getline)
        {
          if (/^ACLOCAL_[A-Z_]*FLAGS\s*=\s*(.*)/)
            {
              $aclocal_flags = $1;
+             $uses_aclocal = 1;
              last;
            }
        }
     }
 
-  xsystem ("$aclocal $aclocal_flags --output=aclocal.m4t");
-  update_file ('aclocal.m4t', 'aclocal.m4');
+  if (!$uses_aclocal)
+    {
+      verbose "$configure_ac: not using aclocal";
+    }
+  else
+    {
+      xsystem ("$aclocal $aclocal_flags --output=aclocal.m4t");
+      update_file ('aclocal.m4t', 'aclocal.m4');
+    }
 
   # ------------------ #
   # Running automake.  #
index 615698f66427649c9eed744fee4637b92354ee86..d9c77a285951f2418de4ff1c77f10fc684139736 100644 (file)
@@ -1,5 +1,5 @@
 .\" DO NOT MODIFY THIS FILE!  It was generated by help2man 1.24.
-.TH AUTORECONF "1" "October 2001" "GNU Autoconf 2.52e" FSF
+.TH AUTORECONF "1" "November 2001" "GNU Autoconf 2.52e" FSF
 .SH NAME
 autoreconf \- Update generated configuration files
 .SH SYNOPSIS