index : pacman | |
Archlinux32 fork of pacman | gitolite user |
summaryrefslogtreecommitdiff |
author | Dave Reisner <d@falconindy.com> | 2010-12-16 17:19:07 -0500 |
---|---|---|
committer | Dave Reisner <d@falconindy.com> | 2011-03-09 15:22:32 -0500 |
commit | 67391c2c6cfa0044f554fb6a6b9717175d8d83a3 (patch) | |
tree | 767d2ce0a3ca98b923ac72c5e18a776d4e7ffa88 | |
parent | 36c570712a34cda92ce3c3362d07baff41ba0d04 (diff) |
-rw-r--r-- | configure.ac | 19 |
diff --git a/configure.ac b/configure.ac index 1039bba1..0ae9cba8 100644 --- a/configure.ac +++ b/configure.ac @@ -96,7 +96,12 @@ AC_ARG_WITH(openssl, # Help line for libfetch AC_ARG_WITH(fetch, AS_HELP_STRING([--with-fetch], [use libfetch as an internal downloader]), - [], [with_fetch=check]) + [], [with_fetch=no]) + +# Help line for libcurl +AC_ARG_WITH(curl, + AS_HELP_STRING([--with-curl], [use libcurl as an internal downloader]), + [], [with_curl=check]) # Help line for documentation AC_ARG_ENABLE(doc, @@ -149,6 +154,18 @@ AS_IF([test "x$with_openssl" != "xno"], AC_MSG_RESULT(no)) AM_CONDITIONAL([HAVE_LIBSSL], [test "x$ac_cv_lib_ssl_MD5_Final" = "xyes"]) +# Enable or disable usage of libcurl +AC_MSG_CHECKING(whether to link with libcurl) +AS_IF([test "x$with_curl" != "xno"], + [AC_MSG_RESULT(yes) + AC_CHECK_LIB([curl], [curl_easy_perform], , + [if test "x$with_curl" != "xcheck"; then + AC_MSG_FAILURE([--with-curl was given, but -lcurl was not found]) + fi], + [-lcurl])], + AC_MSG_RESULT(no)) +AM_CONDITIONAL([HAVE_LIBCURL], [test "x$ac_cv_lib_curl_curl_easy_perform" = "xyes"]) + # Enable or disable usage of libfetch AC_MSG_CHECKING(whether to link with libfetch) AS_IF([test "x$with_fetch" != "xno"], |