Index: aclocal/tcltls_openssl.m4 ================================================================== --- aclocal/tcltls_openssl.m4 +++ aclocal/tcltls_openssl.m4 @@ -129,13 +129,13 @@ SAVE_LIBS="${LIBS}" SAVE_CFLAGS="${CFLAGS}" SAVE_CPPFLAGS="${CPPFLAGS}" dnl Update compile-altering variables to include the OpenSSL libraries - LIBS="${SAVE_LIBS} ${TCLTLS_SSL_LIBS}" - CFLAGS="${SAVE_CFLAGS} ${TCLTLS_SSL_CFLAGS}" - CPPFLAGS="${SAVE_CPPFLAGS} ${TCLTLS_SSL_CPPFLAGS}" + LIBS="${TCLTLS_SSL_LIBS} ${SAVE_LIBS} ${TCLTLS_SSL_LIBS}" + CFLAGS="${TCLTLS_SSL_CFLAGS} ${SAVE_CFLAGS} ${TCLTLS_SSL_CFLAGS}" + CPPFLAGS="${TCLTLS_SSL_CPPFLAGS} ${SAVE_CPPFLAGS} ${TCLTLS_SSL_CPPFLAGS}" dnl Verify that basic functionality is there AC_LANG_PUSH(C) AC_MSG_CHECKING([if a basic OpenSSL program works]) AC_LINK_IFELSE([AC_LANG_PROGRAM([ Index: configure.ac ================================================================== --- configure.ac +++ configure.ac @@ -202,13 +202,13 @@ AC_MSG_ERROR([Unsupported SSL library: $tcltls_ssl_lib]) ] ) dnl Determine how to use this SSL library AC_MSG_CHECKING([how to use $tcltls_ssl_lib]) -LIBS="${LIBS} ${TCLTLS_SSL_LIBS}" -CFLAGS="${CFLAGS} ${TCLTLS_SSL_CFLAGS}" -CPPFLAGS="${CPPFLAGS} ${TCLTLS_SSL_CPPFLAGS}" +LIBS="${TCLTLS_SSL_LIBS} ${LIBS} ${TCLTLS_SSL_LIBS}" +CFLAGS="${TCLTLS_SSL_CFLAGS} ${CFLAGS} ${TCLTLS_SSL_CFLAGS}" +CPPFLAGS="${TCLTLS_SSL_CPPFLAGS} ${CPPFLAGS} ${TCLTLS_SSL_CPPFLAGS}" AC_MSG_RESULT([$TCLTLS_SSL_CPPFLAGS $TCLTLS_SSL_CFLAGS $TCLTLS_SSL_LIBS]) dnl Sync the RPATH if requested if test "$TCLEXT_BUILD" != 'static'; then if test "$TCLEXT_TLS_STATIC_SSL" = 'yes'; then