@@ -1442,12 +1442,12 @@
installation
--with-openssl-libdir=
path to lib directory of OpenSSL or LibreSSL
installation
--with-openssl-pkgconfig=
- path to root directory of OpenSSL or LibreSSL
- pkgconfigdir
+ path to pkgconfigdir directory for OpenSSL or
+ LibreSSL
Some influential environment variables:
CC C compiler command
CFLAGS C compiler flags
LDFLAGS linker flags, e.g. -L if you have libraries in a
@@ -9287,12 +9287,12 @@
printf "%s\n" "#define NO_TLS1 1" >>confdefs.h
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for disable TLS1 protocol" >&5
printf %s "checking for disable TLS1 protocol... " >&6; }
- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: 'yes'" >&5
-printf "%s\n" "'yes'" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
fi
fi
@@ -9304,12 +9304,12 @@
printf "%s\n" "#define NO_TLS1_1 1" >>confdefs.h
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for disable TLS1.1 protocol" >&5
printf %s "checking for disable TLS1.1 protocol... " >&6; }
- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: 'yes'" >&5
-printf "%s\n" "'yes'" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
fi
fi
@@ -9321,12 +9321,12 @@
printf "%s\n" "#define NO_TLS1_2 1" >>confdefs.h
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for disable TLS1.2 protocol" >&5
printf %s "checking for disable TLS1.2 protocol... " >&6; }
- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: 'yes'" >&5
-printf "%s\n" "'yes'" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
fi
fi
@@ -9338,12 +9338,12 @@
printf "%s\n" "#define NO_TLS1_3 1" >>confdefs.h
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for disable TLS1.3 protocol" >&5
printf %s "checking for disable TLS1.3 protocol... " >&6; }
- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: 'yes'" >&5
-printf "%s\n" "'yes'" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
fi
fi
@@ -9438,10 +9438,14 @@
;;
esac
fi
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for OpenSSL directory" >&5
+printf %s "checking for OpenSSL directory... " >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $openssldir" >&5
+printf "%s\n" "$openssldir" >&6; }
# Check whether --with-openssl-includedir was given.
if test ${with_openssl_includedir+y}
then :
@@ -9448,12 +9452,12 @@
withval=$with_openssl_includedir;
opensslincludedir="$withval"
else case e in #(
e)
- if test -n "$openssldir"; then
- opensslincludedir="$openssldir/include/openssl"
+ if test ! -z "$openssldir"; then
+ opensslincludedir="${openssldir}/include"
else
opensslincludedir=''
fi
;;
@@ -9463,20 +9467,25 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for OpenSSL include directory" >&5
printf %s "checking for OpenSSL include directory... " >&6; }
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $opensslincludedir" >&5
printf "%s\n" "$opensslincludedir" >&6; }
- if test -n "$opensslincludedir"; then
- if test -f "$opensslincludedir/ssl.h"; then
+ if test ! -z "$opensslincludedir"; then
+ if test -f "$opensslincludedir/openssl/ssl.h"; then
TCLTLS_SSL_CFLAGS="-I$opensslincludedir"
TCLTLS_SSL_INCLUDES="-I$opensslincludedir"
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ssl.h" >&5
+printf %s "checking for ssl.h... " >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ssl.h" >&5
+printf %s "checking for ssl.h... " >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
as_fn_error $? "Unable to locate ssl.h" "$LINENO" 5
fi
- else
- TCLTLS_SSL_CFLAGS="-I$(includedir)/openssl"
- TCLTLS_SSL_INCLUDES="-I$(includedir)/openssl"
fi
# Check whether --with-openssl-libdir was given.
if test ${with_openssl_libdir+y}
@@ -9484,11 +9493,11 @@
withval=$with_openssl_libdir;
openssllibdir="$withval"
else case e in #(
e)
- if test -n "$openssldir"; then
+ if test ! -z "$openssldir"; then
if test "$do64bit" == 'yes'; then
openssllibdir="$openssldir/lib64"
else
openssllibdir="$openssldir/lib"
fi
@@ -9503,32 +9512,24 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for OpenSSL lib directory" >&5
printf %s "checking for OpenSSL lib directory... " >&6; }
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $openssllibdir" >&5
printf "%s\n" "$openssllibdir" >&6; }
- if test -n "$openssllibdir"; then
+ if test ! -z "$openssllibdir"; then
if test -f "$openssllibdir/libssl${SHLIB_SUFFIX}"; then
if test "${TCLEXT_TLS_STATIC_SSL}" == 'no'; then
TCLTLS_SSL_LIBS="-L$openssllibdir -lcrypto -lssl"
- else
+ #else
# Linux and Solaris
- TCLTLS_SSL_LIBS="-Wl,-Bstatic `$PKG_CONFIG --static --libs crypto ssl` -Wl,-Bdynamic"
+ #TCLTLS_SSL_LIBS="-Wl,-Bstatic `$PKG_CONFIG --static --libs crypto ssl` -Wl,-Bdynamic"
# HPUX
# -Wl,-a,archive ... -Wl,-a,shared_archive
fi
else
as_fn_error $? "Unable to locate libssl${SHLIB_SUFFIX}" "$LINENO" 5
fi
- else
- TCLTLS_SSL_LIBS="-lcrypto -lssl"
fi
-
-
-
-
-
-
# Check whether --with-openssl-pkgconfig was given.
if test ${with_openssl_pkgconfig+y}
then :
@@ -9535,11 +9536,15 @@
withval=$with_openssl_pkgconfig;
opensslpkgconfigdir="$withval"
else case e in #(
e)
- opensslpkgconfigdir=''
+ if test -d ${libdir}/../pkgconfig; then
+ opensslpkgconfigdir="$libdir/../pkgconfig"
+ else
+ opensslpkgconfigdir=''
+ fi
;;
esac
fi
@@ -9560,11 +9565,11 @@
if test -n "${opensslpkgconfigdir}"; then
if ! test -f "${opensslpkgconfigdir}/openssl.pc"; then
as_fn_error $? "Unable to locate ${opensslpkgconfigdir}/openssl.pc" "$LINENO" 5
fi
- PKG_CONFIG_PATH="${opensslpkgconfigdir}${PATH_SEPARATOR}${PKG_CONFIG_PATH}"
+ PKG_CONFIG_PATH="${opensslpkgconfigdir}:${PKG_CONFIG_PATH}"
export PKG_CONFIG_PATH
fi
if test -z "$TCLTLS_SSL_LIBS"; then
TCLTLS_SSL_LIBS="`"${PKG_CONFIG}" openssl --libs $pkgConfigExtraArgs`" || as_fn_error $? "Unable to get OpenSSL Configuration" "$LINENO" 5
fi
@@ -9575,10 +9580,27 @@
TCLTLS_SSL_INCLUDES="`"${PKG_CONFIG}" openssl --cflags-only-I $pkgConfigExtraArgs`" || as_fn_error $? "Unable to get OpenSSL Configuration" "$LINENO" 5
fi
PKG_CONFIG_PATH="${PKG_CONFIG_PATH_SAVE}"
fi
+
+ if test -z "$TCLTLS_SSL_LIBS"; then
+ TCLTLS_SSL_LIBS="-lcrypto -lssl"
+ fi
+ if test -z "$TCLTLS_SSL_CFLAGS"; then
+ TCLTLS_SSL_CFLAGS=""
+ fi
+ if test -z "$TCLTLS_SSL_INCLUDES"; then
+ if test -f /usr/include/openssl/ssl.h; then
+ TCLTLS_SSL_INCLUDES="-I/usr/include"
+ fi
+ fi
+
+
+
+
+
#--------------------------------------------------------------------
# Shared libraries and static libraries have different names.
# Also, windows libraries and unix libraries have different names.
# For the OpenSSL version, I chose to use the same library names that
@@ -9586,11 +9608,11 @@
#--------------------------------------------------------------------
if test "${TEA_PLATFORM}" = "windows" ; then
if test "$GCC" = "yes"; then
- PKG_CFLAGS="$PKG_CFLAGS ${TCLTLS_SSL_CFLAGS}"
+ PKG_CFLAGS="$PKG_CFLAGS ${TCLTLS_SSL_CFLAGS} -Wno-deprecated-declarations"
vars="${TCLTLS_SSL_INCLUDES}"
for i in $vars; do
@@ -9610,11 +9632,11 @@
fi
else
- PKG_CFLAGS="$PKG_CFLAGS ${TCLTLS_SSL_CFLAGS}"
+ PKG_CFLAGS="$PKG_CFLAGS ${TCLTLS_SSL_CFLAGS} -Wno-deprecated-declarations"
vars="${TCLTLS_SSL_INCLUDES}"
for i in $vars; do