From f934e350a800760e17d9f6ae93e848c6bc7a7dfb Mon Sep 17 00:00:00 2001 From: dmiller Date: Sat, 7 Mar 2015 05:37:40 +0000 Subject: [PATCH] Keep -lssl and friends out of LIBS for Ncat, allows overriding with static libs --- ncat/configure | 14 ++------------ ncat/configure.ac | 6 +++--- 2 files changed, 5 insertions(+), 15 deletions(-) diff --git a/ncat/configure b/ncat/configure index a1ad13d57..a8463619b 100755 --- a/ncat/configure +++ b/ncat/configure @@ -4672,12 +4672,7 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_BIO_int_ctrl" >&5 $as_echo "$ac_cv_lib_crypto_BIO_int_ctrl" >&6; } if test "x$ac_cv_lib_crypto_BIO_int_ctrl" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBCRYPTO 1 -_ACEOF - - LIBS="-lcrypto $LIBS" - + use_openssl="yes" else use_openssl="no" { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed to find libcrypto so OpenSSL will not be used. @@ -4726,12 +4721,7 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ssl_SSL_new" >&5 $as_echo "$ac_cv_lib_ssl_SSL_new" >&6; } if test "x$ac_cv_lib_ssl_SSL_new" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBSSL 1 -_ACEOF - - LIBS="-lssl $LIBS" - + use_openssl="yes" else use_openssl="no" { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed to find libssl so OpenSSL will not be used. diff --git a/ncat/configure.ac b/ncat/configure.ac index d00ef0de7..b7df9d387 100644 --- a/ncat/configure.ac +++ b/ncat/configure.ac @@ -86,7 +86,7 @@ if test "$use_openssl" = "yes" -a -z "$specialssldir" ; then if test "$use_openssl" = "yes"; then AC_CHECK_LIB(crypto, BIO_int_ctrl, - [], + [ use_openssl="yes"], [ use_openssl="no" AC_MSG_WARN([Failed to find libcrypto so OpenSSL will not be used. If it is installed you can try the --with-openssl=DIR argument]) ]) @@ -94,7 +94,7 @@ if test "$use_openssl" = "yes" -a -z "$specialssldir" ; then if test "$use_openssl" = "yes"; then AC_CHECK_LIB(ssl, SSL_new, - [], + [ use_openssl="yes"], [ use_openssl="no" AC_MSG_WARN([Failed to find libssl so OpenSSL will not be used. If it is installed you can try the --with-openssl=DIR argument]) ]) @@ -111,7 +111,7 @@ if test "$use_openssl" = "yes"; then AC_SUBST(HAVE_OPENSSL) fi -AC_SUBST(OPENSSL_LIBS) +AC_SUBST(OPENSSL_LIBS) libpcapdir=../libpcap AC_SUBST(libpcapdir)