Re: squid master build with alternate openssl fails

Christos Tsantilas <[email protected]>
Newsgroups gmane.comp.web.squid.devel
Message-ID <[email protected]>
On 8/5/20 5:50 μ.μ., Amos Jeffries wrote:
> Does this change resolve the issue for you?

It is a step but this is not enough.

I am attaching a patch which finally solved the issue. However still it 
is not enough, there are other similar cases need to be fixed in 
squid-util.m4 and probably in configure.ac


> 
> diff --git a/acinclude/squid-util.m4 b/acinclude/squid-util.m4
> index 7f5a72e5b..5860b690e 100644
> --- a/acinclude/squid-util.m4
> +++ b/acinclude/squid-util.m4
> @@ -188,9 +188,9 @@ AC_DEFUN([SQUID_OPTIONAL_LIB],[
>     squid_auto_lib=`echo $1|tr "\-" "_"`
>     set with_$squid_auto_lib = no
>     AC_ARG_WITH([$1],AS_HELP_STRING([--with-$1],[Compile with the $2
> library.]),[
> -    AS_CASE(["$with_$1"],[yes|no],,[
> -      AS_IF([test ! -d "$with_$1"],AC_MSG_ERROR([--with-$1 path does
> not point to a directory]))
> -      with_$squid_auto_lib=yes
> +    AS_CASE(["$withval"],[yes|no],,[
> +      AS_IF([test ! -d "$withval"],AC_MSG_ERROR([--with-$1 path does
> not point to a directory]))
> +      set with_$squid_auto_lib = yes
>         AS_IF([test -d "$withval/lib64"],[$3_PATH += "-L$withval/lib64"])
>         AS_IF([test -d "$withval/lib"],[$3_PATH += "-L$withval/lib"])
>         $3_CFLAGS="-I$withval/include"
> 
> _______________________________________________
> squid-dev mailing list
> [email protected]
> http://lists.squid-cache.org/listinfo/squid-dev
>

_______________________________________________
squid-dev mailing list
[email protected]
http://lists.squid-cache.org/listinfo/squid-dev
fix-openssl-detect.patch (text/x-patch, 1.3 KB)
diff --git a/acinclude/squid-util.m4 b/acinclude/squid-util.m4
index 7f5a72e5b..e48d2c8f9 100644
--- a/acinclude/squid-util.m4
+++ b/acinclude/squid-util.m4
@@ -190,9 +190,9 @@ AC_DEFUN([SQUID_OPTIONAL_LIB],[
   AC_ARG_WITH([$1],AS_HELP_STRING([--with-$1],[Compile with the $2 library.]),[
     AS_CASE(["$with_$1"],[yes|no],,[
       AS_IF([test ! -d "$with_$1"],AC_MSG_ERROR([--with-$1 path does not point to a directory]))
-      with_$squid_auto_lib=yes
-      AS_IF([test -d "$withval/lib64"],[$3_PATH += "-L$withval/lib64"])
-      AS_IF([test -d "$withval/lib"],[$3_PATH += "-L$withval/lib"])
+      set with_$squid_auto_lib = yes
+      AS_IF([test -d "$withval/lib64"],[$3_PATH+="-L$withval/lib64"])
+      AS_IF([test -d "$withval/lib"],[$3_PATH+="-L$withval/lib"])
       $3_CFLAGS="-I$withval/include"
     ])
   ])
diff --git a/configure.ac b/configure.ac
index 2260d09c6..49f79a499 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1261,7 +1261,7 @@ dnl User may specify OpenSSL is needed from a non-standard location
 SQUID_OPTIONAL_LIB(openssl,[OpenSSL],[LIBOPENSSL])
 AH_TEMPLATE(USE_OPENSSL,[OpenSSL support is available])
 ## OpenSSL is default disable due to licensing issues on some OS
-if test "x$with_openssl" = "xyes"; then
+if test "x$with_openssl" != "xno"; then
   CPPFLAGS="$LIBOPENSSL_CFLAGS $CPPFLAGS"
   AC_CHECK_HEADERS( \
     openssl/asn1.h \
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.