[hybrid] [PATCH] Fix autoconf script for SSL support
Michael Wobst
wobst.michael at web.de
Mon Jul 2 14:29:39 EDT 2012
This is most likely due to a static ssl library. I just came up with a
different fix for that issue.
You might want to try the lastest SVN version/snapshot tarball to see if
it works for you.
-Michael
Brad Smith schrieb:
> On Sun, Jul 01, 2012 at 06:07:14PM +0200, Michael Wobst wrote:
>> Prepending "-lcrypto -ssl" to LIBS as well as defining
>> "HAVE_LIBCRYPTO" is already done by the AC_CHECK_LIB macro calls
>> when the ssl and crypto libraries are tested for existence.
>> So adding these two lines just makes things redundant, because this
>> is exactly what AC_CHECK_LIB's job is.
>>
>> Anyway, I'll take a look on how the configure script behaves on OpenBSD.
>> You could also send me the configure.log of the original, unmodified
>> configure script.
>>
>> -Michael
>
> I see you're right about the setting of HAVE_LIBCRYPTO.
>
> The issue is when you link libssl you have to include libcrypto
> otherwise there are undefined symbols from the libcrypto functions
> utilized within libssl.
>
> Here is a more appropriate diff to fix the autoconf script.
>
>
> --- configure.ac.orig Mon May 28 09:47:48 2012
> +++ configure.ac Sun Jul 1 20:19:58 2012
> @@ -131,7 +131,7 @@ AS_IF([test "$cf_enable_openssl" != "no"],
> AS_IF([test "$cf_openssl_version_ok" = "yes"],
> [AC_MSG_RESULT(found)
>
> - AC_CHECK_LIB(ssl, SSL_connect)
> + AC_CHECK_LIB(ssl, SSL_connect,,, -lcrypto)
> AS_IF([test "$ac_cv_lib_ssl_SSL_connect" = "yes"],
> [AC_CHECK_LIB(crypto, RSA_free)])
> ],[AC_MSG_RESULT(no - OpenSSL support disabled)
>
More information about the hybrid
mailing list