2010-12-23 09:44:26 +00:00
|
|
|
dnl
|
|
|
|
dnl Check for libcurl
|
|
|
|
dnl
|
2010-12-25 22:22:57 +00:00
|
|
|
|
2015-04-28 20:31:04 +00:00
|
|
|
curl_found=no
|
2011-12-28 14:17:01 +00:00
|
|
|
AC_ARG_WITH([curl], AC_HELP_STRING([--without-curl], [do not build with CURL support]),
|
|
|
|
[ with_curl=${withval} ], [ with_curl=yes ])
|
2015-04-28 20:31:04 +00:00
|
|
|
AC_ARG_WITH(curl_config,
|
|
|
|
AC_HELP_STRING([--with-curl-config=prog],[use prog instead of looking for curl-config]),
|
|
|
|
[ CURL_CONFIG="$with_curl_config" ],)
|
|
|
|
|
2011-12-28 14:17:01 +00:00
|
|
|
if test "x$with_curl" != "xno"; then
|
2015-04-28 21:38:20 +00:00
|
|
|
AC_PATH_TOOL(CURL_CONFIG, curl-config, no)
|
2015-04-28 20:31:04 +00:00
|
|
|
|
|
|
|
if test x"$CURL_CONFIG" != "xno" ; then
|
|
|
|
curl_found=yes
|
|
|
|
CURL_CFLAGS="`"$CURL_CONFIG" --cflags`"
|
|
|
|
CURL_LIBS="`"$CURL_CONFIG" --libs`"
|
|
|
|
|
|
|
|
else
|
|
|
|
PKG_CHECK_MODULES([CURL], [libcurl], [curl_found=yes])
|
|
|
|
fi
|
2011-12-28 14:17:01 +00:00
|
|
|
fi
|
2010-12-23 09:44:26 +00:00
|
|
|
|
|
|
|
if test "$curl_found" = "yes"; then
|
|
|
|
opt_features_yes="$opt_features_yes\n * online update checks (via libcurl)"
|
2011-10-23 18:23:10 +00:00
|
|
|
AC_DEFINE(HAVE_CURL_EASY_H, 1, [define if libcurl is found via pkg-config])
|
2010-12-23 09:44:26 +00:00
|
|
|
else
|
|
|
|
opt_features_no="$opt_features_no\n * online update checks (via libcurl)"
|
2010-12-25 22:22:57 +00:00
|
|
|
CURL_CFLAGS=""
|
2010-12-23 09:44:26 +00:00
|
|
|
CURL_LIBS=""
|
|
|
|
fi
|