Commit 42b063c3 authored by hartmut@mysql.com's avatar hartmut@mysql.com

make --with-openssl work with parameters as expected,

old options for include path and library settings still
work for backwards compatibility
(fix for BUG #5494)
parent 53d0daa3
......@@ -35,6 +35,7 @@ greg@mysql.com
guilhem@mysql.com
gweir@build.mysql.com
gweir@work.mysql.com
hartmut@mysql.com
heikki@donna.mysql.fi
heikki@hundin.mysql.fi
heikki@rescue.
......
......@@ -788,7 +788,7 @@ AC_DEFUN(MYSQL_FIND_OPENSSL, [
AC_DEFUN(MYSQL_CHECK_OPENSSL, [
AC_MSG_CHECKING(for OpenSSL)
AC_ARG_WITH([openssl],
[ --with-openssl Include the OpenSSL support],
[ --with-openssl[=DIR] Include the OpenSSL support],
[openssl="$withval"],
[openssl=no])
......@@ -806,8 +806,19 @@ AC_MSG_CHECKING(for OpenSSL)
[openssl_libs="$withval"],
[openssl_libs=""])
if test "$openssl" = "yes"
if test "$openssl" != "no"
then
if test "$openssl" != "yes"
then
if test -z "$openssl_includes"
then
openssl_includes="$openssl/include"
fi
if test -z "$openssl_libs"
then
openssl_libs="$openssl/lib"
fi
fi
MYSQL_FIND_OPENSSL([$openssl_includes], [$openssl_libs])
#force VIO use
vio_dir="vio"
......@@ -843,6 +854,14 @@ AC_MSG_CHECKING(for OpenSSL)
NON_THREADED_CLIENT_LIBS="$NON_THREADED_CLIENT_LIBS $openssl_libs"
else
AC_MSG_RESULT(no)
if test ! -z "$openssl_includes"
then
AC_MSG_ERROR(Can't have --with-openssl-includes without --with-openssl);
fi
if test ! -z "$openssl_libs"
then
AC_MSG_ERROR(Can't have --with-openssl-libs without --with-openssl);
fi
fi
AC_SUBST(openssl_libs)
AC_SUBST(openssl_includes)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment