build: Fix checking for OpenSSL 1.1 functions

Fixes #1920
This commit is contained in:
Patrick Griffis 2017-01-05 12:48:37 -05:00
parent dfaf0e31c7
commit eddaf8c396
1 changed files with 8 additions and 2 deletions

View File

@ -374,8 +374,6 @@ AS_IF([test "$openssl" != no], [
openssl=yes
COMMON_LIBS="$COMMON_LIBS $OPENSSL_LIBS"
COMMON_CFLAGS="$COMMON_CFLAGS $OPENSSL_CFLAGS"
dnl Test for various functions that are not available in LibreSSL
AC_CHECK_FUNCS([SSL_CTX_get_ssl_method X509_get_signature_nid DH_set0_pqg DH_get0_key DH_set0_key])
], [
unset openssl_path ac_cv_lib_ssl_SSL_new ac_cv_header_openssl_ssl_h
AS_IF([test "$openssl" != yes], [
@ -406,6 +404,14 @@ AS_IF([test "$openssl" != no], [
])
LIBS=$SAVED_LIBS
])
AS_IF([test "$openssl" = yes], [
dnl Test for various functions that are not available in LibreSSL
SAVED_LIBS="$LIBS"
LIBS="$OPENSSL_LIBS"
AC_CHECK_FUNCS([SSL_CTX_get_ssl_method X509_get_signature_nid DH_set0_pqg DH_get0_key DH_set0_key])
LIBS="$SAVED_LIBS"
])
])
dnl *********************************************************************