Browse Source

* Use MY_ARG_WITH_PATH for OpenSSL path

Bryan Drewery 14 năm trước cách đây
mục cha
commit
6f9b23162e
2 tập tin đã thay đổi với 10 bổ sung13 xóa
  1. 3 7
      autotools/includes/acinclude.m4
  2. 7 6
      configure

+ 3 - 7
autotools/includes/acinclude.m4

@@ -519,16 +519,12 @@ AC_DEFUN([CHECK_SSL],
 dnl Adapted from Ratbox configure.ac
 dnl OpenSSL support
 AC_MSG_CHECKING(for path to OpenSSL)
-AC_ARG_WITH(openssl,
-[AS_HELP_STRING([--with-openssl=DIR],[Path to OpenSSL])],
-[cf_with_openssl=$withval],
-[cf_with_openssl="auto"]
-)
+MY_ARG_WITH_PATH(openssl, [Path to OpenSSL], [auto])
 
 cf_openssl_basedir=""
-if test "$cf_with_openssl" != "auto"; then
+if test "$with_openssl_path" != "auto"; then
   dnl Support for --with-openssl=/some/place
-  cf_openssl_basedir="`echo ${cf_with_openssl} | sed 's/\/$//'`"
+  cf_openssl_basedir="`echo ${with_openssl_path} | sed 's/\/$//'`"
 else
   dnl Do the auto-probe here.  Check some common directory paths.
   for dirs in /usr/local/ssl /usr/pkg /usr/local /usr/local/openssl; do

+ 7 - 6
configure

@@ -1322,7 +1322,7 @@ Optional Features:
 Optional Packages:
   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
-  --with-openssl=DIR      Path to OpenSSL
+  --with-openssl=PATH     Path to OpenSSL
   --with-tcllib=PATH      full path to Tcl library
   --with-tclinc=PATH      full path to Tcl header
 
@@ -5331,18 +5331,19 @@ rm -f confcache
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for path to OpenSSL" >&5
 $as_echo_n "checking for path to OpenSSL... " >&6; }
 
+
 # Check whether --with-openssl was given.
 if test "${with_openssl+set}" = set; then :
-  withval=$with_openssl; cf_with_openssl=$withval
+  withval=$with_openssl; with_openssl_path=$withval
 else
-  cf_with_openssl="auto"
-
+  with_openssl_path=auto
 fi
 
 
+
 cf_openssl_basedir=""
-if test "$cf_with_openssl" != "auto"; then
-    cf_openssl_basedir="`echo ${cf_with_openssl} | sed 's/\/$//'`"
+if test "$with_openssl_path" != "auto"; then
+    cf_openssl_basedir="`echo ${with_openssl_path} | sed 's/\/$//'`"
 else
     for dirs in /usr/local/ssl /usr/pkg /usr/local /usr/local/openssl; do
     if test -f "${dirs}/include/openssl/opensslv.h" ; then