On 9/26/20 10:47 AM, Zack Weinberg wrote:
Would it be right to say that this should be changed in Gnulib,
otherwise any project using that file with Gnulib will have errors
from the new autoconf?
Yes, indeed. All of the Gnulib and Autoconf Macro Archive macros need
to be checked for problems like this. I'm cc:ing gnulib-bugs.
Thanks for reporting that. I installed the attached patch into Gnulib; it works
for me on simple tests (I did reproduce the bug).
Gavin, could you please give the latest Gnulib a try?
>From 43710542d7b1ae457160355adc8cf50fe8070416 Mon Sep 17 00:00:00 2001
From: Paul Eggert <egg...@cs.ucla.edu>
Date: Sat, 26 Sep 2020 19:18:08 -0700
Subject: [PATCH] extensions: require AC_GNU_SOURCE only for <=2.63
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Problem reported by Gavin Smith in:
https://lists.gnu.org/r/autoconf/2020-09/msg00012.html
* m4/extensions.m4 ([gl_USE_SYSTEM_EXTENSIONS]):
Require AC_GNU_SOURCE only for Autoconf 2.63 and earlier, since it
shouldn’t be needed after that, and Autoconf 2.70 complains about
it being obsolete.
---
ChangeLog | 10 ++++++++++
m4/extensions.m4 | 4 ++--
2 files changed, 12 insertions(+), 2 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index d5cabb487..8c06171aa 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,13 @@
+2020-09-26 Paul Eggert <egg...@cs.ucla.edu>
+
+ extensions: require AC_GNU_SOURCE only for <=2.63
+ Problem reported by Gavin Smith in:
+ https://lists.gnu.org/r/autoconf/2020-09/msg00012.html
+ * m4/extensions.m4 ([gl_USE_SYSTEM_EXTENSIONS]):
+ Require AC_GNU_SOURCE only for Autoconf 2.63 and earlier, since it
+ shouldn’t be needed after that, and Autoconf 2.70 complains about
+ it being obsolete.
+
2020-09-26 Bruno Haible <br...@clisp.org>
regex-tests: Make test more robust.
diff --git a/m4/extensions.m4 b/m4/extensions.m4
index d7c95effd..22fdb03e3 100644
--- a/m4/extensions.m4
+++ b/m4/extensions.m4
@@ -1,4 +1,4 @@
-# serial 18 -*- Autoconf -*-
+# serial 19 -*- Autoconf -*-
# Enable extensions on systems that normally disable them.
# Copyright (C) 2003, 2006-2020 Free Software Foundation, Inc.
@@ -183,7 +183,7 @@ AC_DEFUN_ONCE([gl_USE_SYSTEM_EXTENSIONS],
dnl warning: "AC_COMPILE_IFELSE was called before AC_USE_SYSTEM_EXTENSIONS".
dnl Note: We can do this only for one of the macros AC_AIX, AC_GNU_SOURCE,
dnl AC_MINIX. If people still use AC_AIX or AC_MINIX, they are out of luck.
- AC_REQUIRE([AC_GNU_SOURCE])
+ m4_version_prereq([2.64], [], [AC_REQUIRE([AC_GNU_SOURCE])])
AC_REQUIRE([AC_USE_SYSTEM_EXTENSIONS])
])
--
2.17.1