From 76b40e35f28fa6774007b3f7862831bbd37b0120 Mon Sep 17 00:00:00 2001 From: psychon Date: Tue, 30 Jun 2009 13:33:42 +0000 Subject: [PATCH] configure: Error out if pkg-config is not found git-svn-id: https://znc.svn.sourceforge.net/svnroot/znc/trunk@1553 726aef4b-f618-498e-8847-2d620e286838 --- configure | 6 ++++++ configure.in | 5 +++++ 2 files changed, 11 insertions(+) diff --git a/configure b/configure index 5ec0422d..5fc2b290 100755 --- a/configure +++ b/configure @@ -2955,6 +2955,12 @@ $as_echo "no" >&6; } fi fi + if test -z "$PKG_CONFIG" + then + { { $as_echo "$as_me:$LINENO: error: pkg-config not found. Try --disable-c-ares." >&5 +$as_echo "$as_me: error: pkg-config not found. Try --disable-c-ares." >&2;} + { (exit 1); exit 1; }; } + fi pkg_failed=no { $as_echo "$as_me:$LINENO: checking for c_ares" >&5 diff --git a/configure.in b/configure.in index a931ba42..c05ff76d 100644 --- a/configure.in +++ b/configure.in @@ -117,6 +117,11 @@ AC_CHECK_LIB( gnugetopt, getopt_long,) AC_CHECK_FUNC([lstat], [appendCXX -DHAVE_LSTAT]) if test "x$ARES" = "xyes"; then + PKG_PROG_PKG_CONFIG() + if test -z "$PKG_CONFIG" + then + AC_MSG_ERROR([pkg-config not found. Try --disable-c-ares.]) + fi PKG_CHECK_MODULES([c_ares], [libcares],, AC_MSG_ERROR([c-ares not found. Try --disable-c-ares.])) appendCXX $c_ares_CFLAGS -DHAVE_ARES appendLib $c_ares_LIBS