summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDan McGee <dan@archlinux.org>2010-10-07 17:53:11 -0500
committerDan McGee <dan@archlinux.org>2010-10-11 10:06:57 -0500
commit73442a7e035a7b7f8ed80261226989ae87edd3a9 (patch)
treeeee0bfc322dc5fb3a923b634b0a5de5cd64675c7
parent1e0e5b2a0241d1f3e298991c0d583afb9c80baef (diff)
Only check for function if we are using libfetch
We did this check unconditionally, rather than only doing it if we were actually going to build and run with libfetch. This is safe because we would have already bailed if libfetch was explicitly requested but not found. Signed-off-by: Dan McGee <dan@archlinux.org>
-rw-r--r--configure.ac4
1 files changed, 3 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac
index e709fc4c..37b26f25 100644
--- a/configure.ac
+++ b/configure.ac
@@ -158,9 +158,11 @@ AS_IF([test "x$with_fetch" != "xno"],
fi],
[-lcrypto -ldl])
# Check if libfetch supports connnection caching which we use
- AC_CHECK_DECL(fetchConnectionCacheInit, ,
+ AS_IF([test "x$ac_cv_lib_fetch_fetchParseURL" = "xyes"],
+ [AC_CHECK_DECL(fetchConnectionCacheInit, ,
AC_MSG_ERROR([libfetch must be version 2.28 or greater]),
[#include <fetch.h>])
+ ])
],
AC_MSG_RESULT(no))
AM_CONDITIONAL([HAVE_LIBFETCH], [test "x$ac_cv_lib_fetch_fetchParseURL" = "xyes"])