apparently a merge removed the openssl checks - ugh.

svn path=/trunk/; revision=14940
This commit is contained in:
Jeffrey Stedfast
2001-12-07 21:41:18 +00:00
parent d0053fd3c7
commit 2292afbc44
2 changed files with 68 additions and 0 deletions

View File

@ -16,6 +16,7 @@
#undef NEED_KRB_SENDAUTH_PROTO
#undef HAVE_KRB5
#undef HAVE_NSS
#undef HAVE_OPENSSL
#undef HAVE_SSL
#undef USE_DOT
#undef USE_FCNTL

View File

@ -928,6 +928,73 @@ AC_SUBST(NSPR_LDFLAGS)
AC_SUBST(NSS_CFLAGS)
AC_SUBST(NSS_LDFLAGS)
dnl ******************************
dnl OpenSSL
dnl ******************************
if test "$msg_ssl" = "no"; then
AC_ARG_WITH(openssl-includes, [ --with-openssl-includes=PREFIX Location of OpenSSL includes.],
with_openssl_includes="$withval", with_openssl_includes="/usr/include")
have_openssl_includes="no"
if test "x${with_openssl_includes}" != "xno"; then
CPPFLAGS_save="$CPPFLAGS"
AC_MSG_CHECKING(for OpenSSL includes)
AC_MSG_RESULT("")
CPPFLAGS="$CPPFLAGS -I$with_openssl_includes"
AC_CHECK_HEADERS(openssl/ssl.h openssl/x509.h, [ openssl_includes="yes" ])
CPPFLAGS="$CPPFLAGS_save"
if test "x{$openssl_includes}" != "xno" -a "x{$openssl_includes}" != "x"; then
have_openssl_includes="yes"
OPENSSL_CFLAGS="-I$with_openssl_includes"
else
OPENSSL_CFLAGS=""
fi
else
AC_MSG_CHECKING(for OpenSSL includes)
AC_MSG_RESULT(no)
fi
AC_ARG_WITH(openssl-libs, [ --with-openssl-libs=PREFIX Location of OpenSSL libs.],
with_openssl_libs="$withval")
if test "x${with_openssl_libs}" != "xno" -a "x${have_openssl_includes}" != "xno"; then
LDFLAGS_save="$LDFLAGS"
case $with_openssl_libs in
""|-L*) ;;
*) with_openssl_libs="-L$with_openssl_libs" ;;
esac
AC_CHECK_LIB(dl, dlopen, DL_LDFLAGS="-ldl", DL_LDFLAGS="")
AC_CACHE_CHECK([for OpenSSL libraries], openssl_libs,
[
LDFLAGS="$LDFLAGS $with_openssl_libs -lssl -lcrypto $DL_LDFLAGS"
AC_TRY_LINK_FUNC(SSL_read, openssl_libs="yes", openssl_libs="no")
LDFLAGS="$LDFLAGS_save"
])
if test "x${openssl_libs}" != "xno"; then
AC_DEFINE(HAVE_OPENSSL)
AC_DEFINE(HAVE_SSL)
msg_ssl="yes (OpenSSL)"
OPENSSL_LDFLAGS="$with_openssl_libs -lssl -lcrypto $DL_LDFLAGS"
else
OPENSSL_CFLAGS=""
OPENSSL_LDFLAGS=""
fi
else
AC_MSG_CHECKING(for OpenSSL libraries)
AC_MSG_RESULT(no)
fi
else
OPENSSL_CFLAGS=""
OPENSSL_LDFLAGS=""
fi
AC_SUBST(OPENSSL_CFLAGS)
AC_SUBST(OPENSSL_LDFLAGS)
##################################################
# Check for gtk-doc.
##################################################