From 4422005e3bc62f9103e964dceda7007bddb667ce Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=A9r=C3=A9mie=20Galarneau?= Date: Mon, 11 Jan 2021 12:09:05 -0500 Subject: [PATCH] Fix: configure: support Autoconf 2.70 MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit The newly-released autoconf 2.70 introduces a number of breaking changes [1] and is being rolled-out by some distros. Amongst those changes, the AC_PROG_CC_STDC macro is marked as obsolete and was merged into AC_PROG_CC, which we already use. On 2.70, this results in a warning which we handle as an error. A version check is added to invoke the AC_PROG_CC_STDC macro only when running a pre-2.70 version of autoconf, fixing the issue. [1] https://lwn.net/Articles/839395/ [ Backport by Mathieu Desnoyers: removed ax_pthread.m4 bits which are not present in stable-2.12 and prior. ] Signed-off-by: Jérémie Galarneau Signed-off-by: Mathieu Desnoyers Change-Id: I2f4eac788638924aa4960b54374d09de73957925 --- configure.ac | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index d140b086..7f5efdd8 100644 --- a/configure.ac +++ b/configure.ac @@ -53,7 +53,8 @@ AC_REQUIRE_AUX_FILE([tap-driver.sh]) AC_USE_SYSTEM_EXTENSIONS AC_SYS_LARGEFILE AC_PROG_CC -AC_PROG_CC_STDC +# AC_PROG_CC_STDC was merged in AC_PROG_CC in autoconf 2.70 +m4_version_prereq([2.70], [], [AC_PROG_CC_STDC]) AC_PROG_CXX RW_PROG_CXX_WORKS AM_CONDITIONAL([CXX_WORKS], [test "x$rw_cv_prog_cxx_works" = "xyes"]) -- 2.34.1