Changeset 4966


Ignore:
Timestamp:
Dec 3, 2014 4:16:24 AM (6 years ago)
Author:
nanang
Message:

Misc (re #1782): Fixed OpenSSL detection in configure script due to incomplete dependencies and bad library order, which causes OpenSSL detection failure on some platform such as Android mips and arm64.

Location:
pjproject/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk/aconfigure

    r4953 r4966  
    76767676else 
    76777677  ac_check_lib_save_LIBS=$LIBS 
    7678 LIBS="-lcrypto $LIBS" 
     7678LIBS="-lcrypto -ldl -lz $LIBS" 
    76797679cat confdefs.h - <<_ACEOF >conftest.$ac_ext 
    76807680/* end confdefs.h.  */ 
     
    77077707$as_echo "$ac_cv_lib_crypto_ERR_load_BIO_strings" >&6; } 
    77087708if test "x$ac_cv_lib_crypto_ERR_load_BIO_strings" = xyes; then : 
    7709   libcrypto_present=1 && LIBS="$LIBS -lcrypto" 
     7709  libcrypto_present=1 && LIBS="-lcrypto -ldl -lz $LIBS" 
    77107710fi 
    77117711 
     
    77477747$as_echo "$ac_cv_lib_ssl_SSL_library_init" >&6; } 
    77487748if test "x$ac_cv_lib_ssl_SSL_library_init" = xyes; then : 
    7749   libssl_present=1 && LIBS="$LIBS -lssl" 
     7749  libssl_present=1 && LIBS="-lssl $LIBS" 
    77507750fi 
    77517751 
  • pjproject/trunk/aconfigure.ac

    r4953 r4966  
    15331533                AC_SUBST(libcrypto_present) 
    15341534                AC_CHECK_HEADER(openssl/ssl.h,[openssl_h_present=1]) 
    1535                 AC_CHECK_LIB(crypto,ERR_load_BIO_strings,[libcrypto_present=1 && LIBS="$LIBS -lcrypto"]) 
    1536                 AC_CHECK_LIB(ssl,SSL_library_init,[libssl_present=1 && LIBS="$LIBS -lssl"]) 
     1535                AC_CHECK_LIB(crypto,ERR_load_BIO_strings,[libcrypto_present=1 && LIBS="-lcrypto -ldl -lz $LIBS"],,-ldl -lz) 
     1536                AC_CHECK_LIB(ssl,SSL_library_init,[libssl_present=1 && LIBS="-lssl $LIBS"]) 
    15371537                if test "x$openssl_h_present" = "x1" -a "x$libssl_present" = "x1" -a "x$libcrypto_present" = "x1"; then 
    15381538                        AC_MSG_RESULT([OpenSSL library found, SSL support enabled]) 
Note: See TracChangeset for help on using the changeset viewer.