Re #1943: Fixed incorrect configure script.

git-svn-id: https://svn.pjsip.org/repos/pjproject/trunk@5414 74dad513-b988-da41-8d7b-12977e46ad98
This commit is contained in:
Sauw Ming 2016-08-08 11:19:35 +00:00
parent 528c374870
commit 77a12fccab
2 changed files with 43 additions and 2 deletions

View File

@ -7953,7 +7953,47 @@ fi
$as_echo "OpenSSL library found, SSL support enabled" >&6; }
# Check if SRTP should be compiled with OpenSSL
# support, to enable cryptos such as AES GCM AC_CHECK_LIB(crypto,EVP_aes_128_gcm,[ac_ssl_has_aes_gcm=1])
# support, to enable cryptos such as AES GCM
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for EVP_aes_128_gcm in -lssl" >&5
$as_echo_n "checking for EVP_aes_128_gcm in -lssl... " >&6; }
if ${ac_cv_lib_ssl_EVP_aes_128_gcm+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-lssl $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
builtin and then its argument prototype would still apply. */
#ifdef __cplusplus
extern "C"
#endif
char EVP_aes_128_gcm ();
int
main ()
{
return EVP_aes_128_gcm ();
;
return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
ac_cv_lib_ssl_EVP_aes_128_gcm=yes
else
ac_cv_lib_ssl_EVP_aes_128_gcm=no
fi
rm -f core conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ssl_EVP_aes_128_gcm" >&5
$as_echo "$ac_cv_lib_ssl_EVP_aes_128_gcm" >&6; }
if test "x$ac_cv_lib_ssl_EVP_aes_128_gcm" = xyes; then :
ac_ssl_has_aes_gcm=1
fi
if test "x$ac_ssl_has_aes_gcm" = "x1"; then
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: OpenSSL has AES GCM support, SRTP will use OpenSSl version" >&5
$as_echo "OpenSSL has AES GCM support, SRTP will use OpenSSl version" >&6; }

View File

@ -1603,7 +1603,8 @@ AC_ARG_ENABLE(ssl,
AC_MSG_RESULT([OpenSSL library found, SSL support enabled])
# Check if SRTP should be compiled with OpenSSL
# support, to enable cryptos such as AES GCM AC_CHECK_LIB(crypto,EVP_aes_128_gcm,[ac_ssl_has_aes_gcm=1])
# support, to enable cryptos such as AES GCM
AC_CHECK_LIB(crypto,EVP_aes_128_gcm,[ac_ssl_has_aes_gcm=1])
if test "x$ac_ssl_has_aes_gcm" = "x1"; then
AC_MSG_RESULT([OpenSSL has AES GCM support, SRTP will use OpenSSl version])
else