automake-patches
[Top][All Lists]
Advanced

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

FYI: fix for PR/303


From: Alexandre Duret-Lutz
Subject: FYI: fix for PR/303
Date: 07 Mar 2002 22:02:10 +0100
User-agent: Gnus/5.0808 (Gnus v5.8.8) Emacs/20.7

I'm checking this in.  &version_check assumed the version it was
given was always coming from AUTOMAKE_OPTIONS.

Index: ChangeLog
===================================================================
RCS file: /cvs/automake/automake/ChangeLog,v
retrieving revision 1.1779
diff -u -r1.1779 ChangeLog
--- ChangeLog   2002/03/07 12:26:39     1.1779
+++ ChangeLog   2002/03/07 20:57:48
@@ -1,5 +1,12 @@
 2002-03-07  Alexandre Duret-Lutz  <address@hidden>
 
+       Fix for PR automake/303:
+       * automake.in (version_check): Move the error message ...
+       (process_option_list): ... here, so we can distinguish between
+       global and local options.
+
+2002-03-07  Alexandre Duret-Lutz  <address@hidden>
+
        * tests/pr300-lib.test, tests/pr300-ltlib.test,
        tests/pr300-prog.test: Use AC_OUTPUT, not AC_OUTPUT(Makefile), so
        Autoconf doesn't complain about Makefile being output twice.
Index: automake.in
===================================================================
RCS file: /cvs/automake/automake/automake.in,v
retrieving revision 1.1281
diff -u -r1.1281 automake.in
--- automake.in 2002/03/05 21:34:13     1.1281
+++ automake.in 2002/03/07 20:58:13
@@ -1420,8 +1420,6 @@
            && $ralpha gt $talpha)
        || ($rfork ne '' && $rfork ne $tfork))
     {
-       macro_error ('AUTOMAKE_OPTIONS',
-                    "require version $_, but have $VERSION");
        return 1;
     }
 
@@ -1474,6 +1472,19 @@
            # Got a version number.
            if (version_check ($1, $2, $3, $4))
            {
+               if ($config)
+               {
+                   file_error ($seen_init_automake,
+                               "require version $_, but have $VERSION");
+                   # Arrange to process this global option only once, otherwise
+                   # the error message would be printed for each Makefile.
+                   $global_options =~ s/(?:^| )$_(?: |$)/ /g;
+               }
+               else
+               {
+                   macro_error ('AUTOMAKE_OPTIONS',
+                                "require version $_, but have $VERSION");
+               }
                return 1;
            }
        }
-- 
Alexandre Duret-Lutz




reply via email to

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