|
|
|
@ -1,3 +1,24 @@
@@ -1,3 +1,24 @@
|
|
|
|
|
#*************************************************************************** |
|
|
|
|
# _ _ ____ _ |
|
|
|
|
# Project ___| | | | _ \| | |
|
|
|
|
# / __| | | | |_) | | |
|
|
|
|
# | (__| |_| | _ <| |___ |
|
|
|
|
# \___|\___/|_| \_\_____| |
|
|
|
|
# |
|
|
|
|
# Copyright (C) 2006 - 2020, David Shaw <dshaw@jabberwocky.com> |
|
|
|
|
# |
|
|
|
|
# This software is licensed as described in the file COPYING, which |
|
|
|
|
# you should have received as part of this distribution. The terms |
|
|
|
|
# are also available at https://curl.se/docs/copyright.html. |
|
|
|
|
# |
|
|
|
|
# You may opt to use, copy, modify, merge, publish, distribute and/or sell |
|
|
|
|
# copies of the Software, and permit persons to whom the Software is |
|
|
|
|
# furnished to do so, under the terms of the COPYING file. |
|
|
|
|
# |
|
|
|
|
# This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY |
|
|
|
|
# KIND, either express or implied. |
|
|
|
|
# |
|
|
|
|
########################################################################### |
|
|
|
|
# LIBCURL_CHECK_CONFIG ([DEFAULT-ACTION], [MINIMUM-VERSION], |
|
|
|
|
# [ACTION-IF-YES], [ACTION-IF-NO]) |
|
|
|
|
# ---------------------------------------------------------- |
|
|
|
@ -61,7 +82,7 @@ AC_DEFUN([LIBCURL_CHECK_CONFIG],
@@ -61,7 +82,7 @@ AC_DEFUN([LIBCURL_CHECK_CONFIG],
|
|
|
|
|
AH_TEMPLATE([LIBCURL_PROTOCOL_SMTP],[Defined if libcurl supports SMTP]) |
|
|
|
|
|
|
|
|
|
AC_ARG_WITH(libcurl, |
|
|
|
|
AC_HELP_STRING([--with-libcurl=PREFIX],[look for the curl library in PREFIX/lib and headers in PREFIX/include]), |
|
|
|
|
AS_HELP_STRING([--with-libcurl=PREFIX],[look for the curl library in PREFIX/lib and headers in PREFIX/include]), |
|
|
|
|
[_libcurl_with=$withval],[_libcurl_with=ifelse([$1],,[yes],[$1])]) |
|
|
|
|
|
|
|
|
|
if test "$_libcurl_with" != "no" ; then |
|
|
|
@ -73,6 +94,7 @@ AC_DEFUN([LIBCURL_CHECK_CONFIG],
@@ -73,6 +94,7 @@ AC_DEFUN([LIBCURL_CHECK_CONFIG],
|
|
|
|
|
_libcurl_try_link=yes |
|
|
|
|
|
|
|
|
|
if test -d "$_libcurl_with" ; then |
|
|
|
|
LIBCURL_CPPFLAGS="-I$withval/include" |
|
|
|
|
_libcurl_ldflags="-L$withval/lib" |
|
|
|
|
AC_PATH_PROG([_libcurl_config],[curl-config],[], |
|
|
|
|
["$withval/bin"]) |
|
|
|
@ -105,7 +127,7 @@ AC_DEFUN([LIBCURL_CHECK_CONFIG],
@@ -105,7 +127,7 @@ AC_DEFUN([LIBCURL_CHECK_CONFIG],
|
|
|
|
|
LIBCURL_CPPFLAGS=`$_libcurl_config --cflags` |
|
|
|
|
fi |
|
|
|
|
if test x"$LIBCURL" = "x" ; then |
|
|
|
|
LIBCURL=`$_libcurl_config --static-libs` |
|
|
|
|
LIBCURL=`$_libcurl_config --libs` |
|
|
|
|
|
|
|
|
|
# This is so silly, but Apple actually has a bug in their |
|
|
|
|
# curl-config script. Fixed in Tiger, but there are still |
|
|
|
@ -152,11 +174,11 @@ int x;
@@ -152,11 +174,11 @@ int x;
|
|
|
|
|
curl_easy_setopt(NULL,CURLOPT_URL,NULL); |
|
|
|
|
x=CURL_ERROR_SIZE; |
|
|
|
|
x=CURLOPT_WRITEFUNCTION; |
|
|
|
|
x=CURLOPT_FILE; |
|
|
|
|
x=CURLOPT_WRITEDATA; |
|
|
|
|
x=CURLOPT_ERRORBUFFER; |
|
|
|
|
x=CURLOPT_STDERR; |
|
|
|
|
x=CURLOPT_VERBOSE; |
|
|
|
|
if (x) ; |
|
|
|
|
if (x) {;} |
|
|
|
|
]])],libcurl_cv_lib_curl_usable=yes,libcurl_cv_lib_curl_usable=no) |
|
|
|
|
|
|
|
|
|
CPPFLAGS=$_libcurl_save_cppflags |
|
|
|
|