]> git.ipfire.org Git - thirdparty/openvpn.git/commitdiff
Fix ENABLE_CRYPTO_OPENSSL set to YES even with --disable-crypto set
authorArne Schwabe <arne@rfc2549.org>
Sat, 17 Sep 2016 11:16:46 +0000 (13:16 +0200)
committerGert Doering <gert@greenie.muc.de>
Sat, 17 Sep 2016 11:52:22 +0000 (13:52 +0200)
On OS X openssl/x509.h is not in the standard include path and the
files still try to include since the includes only depend on on
ENABLE_CRYPTO_OPENSSL.

Acked-by: Gert Doering <gert@greenie.muc.de>
Message-Id: <1474111006-16401-1-git-send-email-arne@rfc2549.org>
URL: http://www.mail-archive.com/search?l=mid&q=1474111006-16401-1-git-send-email-arne@rfc2549.org

Signed-off-by: Gert Doering <gert@greenie.muc.de>
configure.ac

index 2d578f41d76d382aaf69f3cad3e7cb78640d1d92..1337f84e67969a05957756c200d829668c51a5af 100644 (file)
@@ -790,7 +790,7 @@ PKG_CHECK_MODULES(
        []
 )
 
-if test "${with_crypto_library}" = "openssl"; then
+if test "${enable_crypto}" = "yes" -a "${with_crypto_library}" = "openssl"; then
        AC_ARG_VAR([OPENSSL_CFLAGS], [C compiler flags for OpenSSL])
        AC_ARG_VAR([OPENSSL_LIBS], [linker flags for OpenSSL])
 
@@ -844,7 +844,7 @@ if test "${with_crypto_library}" = "openssl"; then
        AC_DEFINE([ENABLE_CRYPTO_OPENSSL], [1], [Use OpenSSL library])
        CRYPTO_CFLAGS="${OPENSSL_CFLAGS}"
        CRYPTO_LIBS="${OPENSSL_LIBS}"
-elif test "${with_crypto_library}" = "mbedtls"; then
+elif test "${enable_crypto}" = "yes" -a "${with_crypto_library}" = "mbedtls"; then
        AC_ARG_VAR([MBEDTLS_CFLAGS], [C compiler flags for mbedtls])
        AC_ARG_VAR([MBEDTLS_LIBS], [linker flags for mbedtls])
 
@@ -927,7 +927,7 @@ elif test "${with_crypto_library}" = "mbedtls"; then
        AC_DEFINE([ENABLE_CRYPTO_MBEDTLS], [1], [Use mbed TLS library])
        CRYPTO_CFLAGS="${MBEDTLS_CFLAGS}"
        CRYPTO_LIBS="${MBEDTLS_LIBS}"
-else
+elif test "${enable_crypto}" = "yes"; then
        AC_MSG_ERROR([Invalid crypto library: ${with_crypto_library}])
 fi