[Openvpn-devel,v1] configure: Call AC_PROG_CC before AC_USE_SYSTEM_EXTENSIONS

Message ID 20261022123500.27256-1-gert@greenie.muc.de
State New
Headers
Series [Openvpn-devel,v1] configure: Call AC_PROG_CC before AC_USE_SYSTEM_EXTENSIONS |

Commit Message

Gert Doering Oct. 22, 2026, 12:34 p.m. UTC
  From: Razvan Cojocaru <razvanc@mailbox.org>

AC_USE_SYSTEM_EXTENSIONS requires AC_PROG_CC, so the later explicit
call expanded it a second time and repeated the C standard checks
as "(cached)".

Change-Id: I20d367dd8251bf39856ae521f380cfdc8df64177
Signed-off-by: Razvan Cojocaru <razvanc@mailbox.org>
Acked-by: Arne Schwabe <arne-openvpn@rfc2549.org>
Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/2028
---

This change was reviewed on Gerrit and approved by at least one
developer. I request to merge it to master.

Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/2028
This mail reflects revision 1 of this Change.

Acked-by according to Gerrit (reflected above):
Arne Schwabe <arne-openvpn@rfc2549.org>
  

Comments

Gert Doering Oct. 22, 2026, 1:18 p.m. UTC | #1
Lightly tested, seems to improve things :-)

Your patch has been applied to the master and release/2.7 branch
("build system improvements").

commit 74ba58631ae2b53668c2b5d372e4f7ed28e02223 (master)
commit cddfc8cbdc4d200e0540ed6be79fd23afb1ffe77 (release/2.7)
Author: Razvan Cojocaru
Date:   Thu Oct 22 14:34:55 2026 +0200

     configure: Call AC_PROG_CC before AC_USE_SYSTEM_EXTENSIONS

     Signed-off-by: Razvan Cojocaru <razvanc@mailbox.org>
     Acked-by: Arne Schwabe <arne-openvpn@rfc2549.org>
     Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/2028
     Message-Id: <20261022123500.27256-1-gert@greenie.muc.de>
     URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg40092.html
     Signed-off-by: Gert Doering <gert@greenie.muc.de>


--
kind regards,

Gert Doering
  

Patch

diff --git a/configure.ac b/configure.ac
index e31a7ff..0ac61b4 100644
--- a/configure.ac
+++ b/configure.ac
@@ -45,6 +45,11 @@ 
 AM_INIT_AUTOMAKE(foreign subdir-objects 1.16) dnl NB: Do not [quote] this parameter.
 AM_SILENT_RULES([yes])
 AC_CANONICAL_HOST
+AC_PROG_CC
+# AC_PROG_CC doesn't output any useful information
+AC_MSG_CHECKING([compiler version])
+CC_version=$($CC --version | head -n1)
+AC_MSG_RESULT([$CC_version])
 AC_USE_SYSTEM_EXTENSIONS
 
 AM_EXTRA_RECURSIVE_TARGETS([build-tests])
@@ -380,11 +385,6 @@ 
 	pkg_config_found="(${PKG_CONFIG})"
 fi
 
-AC_PROG_CC
-# AC_PROG_CC doesn't output any useful information
-AC_MSG_CHECKING([compiler version])
-CC_version=$($CC --version | head -n1)
-AC_MSG_RESULT([$CC_version])
 AC_PROG_CPP
 AC_PROG_INSTALL
 AC_PROG_LN_S