]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
Remove AX_CHECK_OPENSSL macro
authorOndřej Surý <ondrej@isc.org>
Thu, 2 Sep 2021 11:24:46 +0000 (13:24 +0200)
committerOndřej Surý <ondrej@isc.org>
Mon, 5 Aug 2024 10:23:59 +0000 (10:23 +0000)
OpenSSL supports pkg-config method since the 0.9.8 version and we
already require pkg-config for other mandatory libraries.  Also
the way the AX_CHECK_OPENSSL macro was integrated into the configure
script was confusing - the macro would be used only if the libcrypto.pc
and libssl.pc file are not usable, so calling ./configure
--with-openssl=/usr/local would have no effect when PKG_CHECK_MODULES
would be successful.

configure.ac

index a7fa50ef78f616a3b4d62d31b7ec1ac33fc6451b..f764eb15490390984057d014e810b1e59eefa643 100644 (file)
@@ -653,25 +653,14 @@ CRYPTO=OpenSSL
 #
 # OpenSSL/LibreSSL is mandatory
 #
-PKG_CHECK_MODULES([OPENSSL], [libssl >= 1.1.1 libcrypto >= 1.1.1], [PKG_CHECK_VERSION([OPENSSL_VERSION], [openssl])],
-                 [AX_CHECK_OPENSSL([:], [AC_MSG_FAILURE([OpenSSL/LibreSSL not found])])])
+PKG_CHECK_MODULES([OPENSSL], [libssl >= 1.1.1 libcrypto >= 1.1.1])
+PKG_CHECK_VERSION([OPENSSL_VERSION], [openssl])
 
 AX_SAVE_FLAGS([openssl])
 
 CFLAGS="$OPENSSL_CFLAGS $CFLAGS"
 LIBS="$OPENSSL_LIBS $LIBS"
 
-AC_MSG_CHECKING([for OpenSSL >= 1.1.1 or LibreSSL >= 2.7.0])
-AC_COMPILE_IFELSE(
-    [AC_LANG_PROGRAM([[#include <openssl/opensslv.h>]],
-                    [[#if (!defined(LIBRESSL_VERSION_NUMBER) && (OPENSSL_VERSION_NUMBER < 0x01010100fL)) || \\
-                          (defined(LIBRESSL_VERSION_NUMBER) && (LIBRESSL_VERSION_NUMBER < 0x02070000fL))
-                      #error OpenSSL >= 1.1.1 or LibreSSL >= 2.7.0 required
-                      #endif
-                     ]])],
-    [AC_MSG_RESULT([yes])],
-    [AC_MSG_FAILURE([not found])])
-
 #
 # Check for functions added in OpenSSL or LibreSSL
 #