From: Ralf Wildenhues Date: Fri, 7 Apr 2006 18:25:30 +0000 (+0000) Subject: * bin/autoupdate.in (handle_autoconf_patches): Change the way we X-Git-Tag: AUTOCONF-2.59c~42 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=aefd74ee25e34e446e760bf39eba09dc02adaf05;p=thirdparty%2Fautoconf.git * 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 , test case by Noah Misch . --- diff --git a/ChangeLog b/ChangeLog index a4ba4b0c8..b5acaa3f3 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,12 @@ +2006-04-07 Stepan Kasal , + Ralf Wildenhues + + * 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 , + test case by Noah Misch . + 2006-04-07 Stepan Kasal Revert my change from 2006-03-17, in other words: diff --git a/bin/autoupdate.in b/bin/autoupdate.in index ef1e7bf63..2d6a9384b 100644 --- a/bin/autoupdate.in +++ b/bin/autoupdate.in @@ -145,21 +145,11 @@ sub handle_autoconf_macros () { 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; diff --git a/tests/tools.at b/tests/tools.at index 78f993609..29eb658a4 100644 --- a/tests/tools.at +++ b/tests/tools.at @@ -719,3 +719,32 @@ AT_CHECK_CONFIGURE([], [0], [stdout]) 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@&t@_include]) + +# 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