Improve libcurl detection.
authorWerner Koch <wk@gnupg.org>
Tue, 6 Aug 2013 08:31:54 +0000 (10:31 +0200)
committerWerner Koch <wk@gnupg.org>
Tue, 6 Aug 2013 08:31:54 +0000 (10:31 +0200)
* m4/libcurl.m4: Do not use AC_PATH_PROG if --with-libcurl as been
given.  Suggested by John Marshall.
--

GnuPG-bug-id: 1510

m4/libcurl.m4

index fe9809e..6299501 100644 (file)
@@ -75,7 +75,11 @@ AC_DEFUN([LIBCURL_CHECK_CONFIG],
      if test -d "$_libcurl_with" ; then
         LIBCURL_CPPFLAGS="-I$withval/include"
         _libcurl_ldflags="-L$withval/lib"
-        AC_PATH_PROG([_libcurl_config],["$withval/bin/curl-config"])
+        if test -x "$withval/bin/curl-config" ; then
+          _libcurl_config="$withval/bin/curl-config"
+        else
+          _libcurl_config=
+        fi
      else
        AC_PATH_PROG([_libcurl_config],[curl-config])
      fi