autoconf-patches
[Top][All Lists]
Advanced

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

Re: [BUG] autoupdate vs aclocal m4_include


From: Ralf Wildenhues
Subject: Re: [BUG] autoupdate vs aclocal m4_include
Date: Fri, 7 Apr 2006 20:25:19 +0200
User-agent: Mutt/1.5.9i

* Ralf Wildenhues wrote on Tue, Apr 04, 2006 at 10:10:31AM CEST:
> * Noah Misch wrote on Tue, Apr 04, 2006 at 12:50:47AM CEST:
> > On Mon, Apr 03, 2006 at 11:07:14PM +0200, Stepan Kasal wrote:
> > >   * bin/autoupdate.in (handle_autoconf_patches): Change the way we
> > >     distinguish m4sugar macros.

I think just copying the stuff (instead of symlinking it) is sufficient
for this test, no?

I've applied the patch as below.

Cheers,
Ralf

2006-04-07  Stepan Kasal  <address@hidden>,
            Ralf Wildenhues <address@hidden>

        * bin/autoupdate.in (handle_autoconf_patches): Change the way we
        distinguish m4sugar macros.
        * tests/tools.at (autoupdating with aclocal and m4_include):
        New test.  Bug reported by Gary V. Vaughan <address@hidden>,
        test case by Noah Misch <address@hidden>.

Index: bin/autoupdate.in
===================================================================
RCS file: /cvsroot/autoconf/autoconf/bin/autoupdate.in,v
retrieving revision 1.60
diff -u -r1.60 autoupdate.in
--- bin/autoupdate.in   1 Apr 2006 15:58:43 -0000       1.60
+++ bin/autoupdate.in   3 Apr 2006 21:01:36 -0000
@@ -145,21 +145,11 @@
     {
       chomp;
       my ($domain, $file, $macro) = /^(AC|AU):(.*):([^:]*)$/ or next;
-      # ../lib/m4sugar/m4sugar.m4  -> m4sugar
-      # ../lib/m4sugar/version.m4  -> m4sugar
-      # ../lib/autoconf/general.m4 -> autoconf
-      # aclocal.m4 -> aclocal
-      # ../lib/m4sugar/m4sh.m4     -> m4sh
-      my $set = basename (dirname ($file));
-      $set = 'aclocal' if $file eq 'aclocal.m4';
-      $set = 'm4sh' if basename($file) eq 'm4sh.m4';
-      error "unknown set: $set: $_"
-       unless $set =~ /^(m4sugar|m4sh|aclocal|autoconf)$/;
       if ($domain eq "AU")
        {
          $au_macros{$macro} = 1;
        }
-      elsif ($set eq "m4sugar")
+      elsif ($file =~ /(^|\/)m4sugar\/(m4sugar|version)\.m4$/)
        {
          # Add the m4sugar macros to m4_builtins.
          $m4_builtins{$macro} = 1;
Index: tests/tools.at
===================================================================
RCS file: /cvsroot/autoconf/autoconf/tests/tools.at,v
retrieving revision 1.81
diff -u -r1.81 tools.at
--- tests/tools.at      1 Apr 2006 15:57:02 -0000       1.81
+++ tests/tools.at      6 Apr 2006 23:36:18 -0000
@@ -719,3 +719,32 @@
 AT_CHECK([[grep ' 1 2 3 4 5 6' stdout]], 0, [ignore], [ignore])
 
 AT_CLEANUP
+
+
+# autoupdating with aclocal and m4_include
+# ----------------------------------------
+AT_SETUP([autoupdating with aclocal and m4@&address@hidden)
+
+# We use aclocal.
+AT_CHECK([aclocal --version || exit 77], [], [ignore], [ignore])
+
+mkdir m4 aclocal
+AT_DATA([configure.in],
+[[AC_INIT(x,0)
+AC_UNCHANGED_MACRO
+AC_OLD_MACRO
+AC_OUTPUT
+]])
+AT_DATA([m4/stuff.m4],
+[[AU_ALIAS([AC_OLD_MACRO], [AC_NEW_MACRO])
+AC_DEFUN([AC_NEW_MACRO], [echo hi])
+AC_DEFUN([AC_UNCHANGED_MACRO], [echo one])
+]])
+cp m4/stuff.m4 aclocal/stuff.m4
+AT_CHECK([aclocal -I aclocal], [0], [ignore], [ignore])
+# Checking `autoupdate'.
+AT_CHECK_AUTOUPDATE
+AT_CHECK([aclocal -I m4], [0], [ignore], [ignore])
+AT_CHECK_AUTOUPDATE
+
+AT_CLEANUP




reply via email to

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