From b83bf6e571f34db86a3353e5855e1d92a47571c0 Mon Sep 17 00:00:00 2001 From: Jia Yuan Lo Date: Tue, 14 Apr 2020 11:51:36 +0800 Subject: [PATCH] Add check for "-L/..." in "$SSL_LIBS" Checking for "-lssl" in "$LIBCURL" may not be enough to find where is the SSL lib The test may fail with "cannot find -lssl" and "cannot find -lcrypto" Add additional check if "$SSL_LIBS" can provide the SSL lib before moving on --- m4/libcurl.m4 | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/m4/libcurl.m4 b/m4/libcurl.m4 index 555f3c8de4..f7a6940bf0 100644 --- a/m4/libcurl.m4 +++ b/m4/libcurl.m4 @@ -110,6 +110,11 @@ AC_DEFUN([LIBCURL_CHECK_CONFIG], LIBCURL="${LIBCURL} ${SSL_LIBS}" fi + # fix cannot find -lssl + if test "x`echo \""$SSL_LIBS"\" | grep '\-L/'`" != 'x' ; then + LIBCURL="${LIBCURL} ${SSL_LIBS}" + fi + # This is so silly, but Apple actually has a bug in their # curl-config script. Fixed in Tiger, but there are still # lots of Panther installs around.