diff --git a/ConfigureChecks.cmake b/ConfigureChecks.cmake index 384e7856..93038c59 100644 --- a/ConfigureChecks.cmake +++ b/ConfigureChecks.cmake @@ -104,6 +104,10 @@ if (OPENSSL_FOUND) set(CMAKE_REQUIRED_LIBRARIES ${OPENSSL_CRYPTO_LIBRARIES}) check_function_exists(EVP_KDF_CTX_new_id HAVE_OPENSSL_EVP_KDF_CTX_NEW_ID) + set(CMAKE_REQUIRED_INCLUDES ${OPENSSL_INCLUDE_DIR}) + set(CMAKE_REQUIRED_LIBRARIES ${OPENSSL_CRYPTO_LIBRARIES}) + check_function_exists(EVP_KDF_CTX_new HAVE_OPENSSL_EVP_KDF_CTX_NEW) + set(CMAKE_REQUIRED_INCLUDES ${OPENSSL_INCLUDE_DIR}) set(CMAKE_REQUIRED_LIBRARIES ${OPENSSL_CRYPTO_LIBRARIES}) check_function_exists(FIPS_mode HAVE_OPENSSL_FIPS_MODE) @@ -159,6 +163,11 @@ if (NOT WITH_GCRYPT AND NOT WITH_MBEDTLS) if (HAVE_OPENSSL_ECC) set(HAVE_ECC 1) endif (HAVE_OPENSSL_ECC) + + if (HAVE_OPENSSL_EVP_KDF_CTX_NEW_ID OR HAVE_OPENSSL_EVP_KDF_CTX_NEW) + set(HAVE_OPENSSL_EVP_KDF_CTX 1) + endif (HAVE_OPENSSL_EVP_KDF_CTX_NEW_ID OR HAVE_OPENSSL_EVP_KDF_CTX_NEW) + endif () if (WITH_DSA) diff --git a/config.h.cmake b/config.h.cmake index 34690304..5c358fb4 100644 --- a/config.h.cmake +++ b/config.h.cmake @@ -114,8 +114,8 @@ /* Define to 1 if you have the `EVP_chacha20' function. */ #cmakedefine HAVE_OPENSSL_EVP_CHACHA20 1 -/* Define to 1 if you have the `EVP_KDF_CTX_new_id' function. */ -#cmakedefine HAVE_OPENSSL_EVP_KDF_CTX_NEW_ID 1 +/* Define to 1 if you have the `EVP_KDF_CTX_new_id' or `EVP_KDF_CTX_new` function. */ +#cmakedefine HAVE_OPENSSL_EVP_KDF_CTX 1 /* Define to 1 if you have the `FIPS_mode' function. */ #cmakedefine HAVE_OPENSSL_FIPS_MODE 1