summaryrefslogtreecommitdiff
path: root/cmake
diff options
context:
space:
mode:
Diffstat (limited to 'cmake')
-rw-r--r--cmake/ssl.cmake5
1 files changed, 3 insertions, 2 deletions
diff --git a/cmake/ssl.cmake b/cmake/ssl.cmake
index c5985a38621..c76e73927c0 100644
--- a/cmake/ssl.cmake
+++ b/cmake/ssl.cmake
@@ -170,7 +170,7 @@ MACRO (MYSQL_CHECK_SSL)
REGEX "^#define[\t ]+OPENSSL_VERSION_NUMBER[\t ]+0x[0-9].*"
)
STRING(REGEX REPLACE
- "^.*OPENSSL_VERSION_NUMBER[\t ]+0x([0-9]).*$" "\\1"
+ "^.*OPENSSL_VERSION_NUMBER[\t ]+0x([0-9][0-9][0-9]).*$" "\\1"
OPENSSL_MAJOR_VERSION "${OPENSSL_VERSION_NUMBER}"
)
INCLUDE(CheckSymbolExists)
@@ -182,7 +182,8 @@ MACRO (MYSQL_CHECK_SSL)
SET(OPENSSL_FOUND FALSE)
ENDIF()
- IF(OPENSSL_FOUND AND HAVE_SHA512_DIGEST_LENGTH)
+ IF(OPENSSL_FOUND AND OPENSSL_MAJOR_VERSION STRLESS "101" AND
+ HAVE_SHA512_DIGEST_LENGTH)
MESSAGE(STATUS "OPENSSL_INCLUDE_DIR = ${OPENSSL_INCLUDE_DIR}")
MESSAGE(STATUS "OPENSSL_LIBRARIES = ${OPENSSL_LIBRARIES}")
MESSAGE(STATUS "CRYPTO_LIBRARY = ${CRYPTO_LIBRARY}")