From: Henrik Nordstrom Date: Tue, 27 Oct 2009 19:50:18 +0000 (+0100) Subject: Don't try to write autoconf snippets when having a fewer.. X-Git-Tag: SQUID_3_2_0_1~647^2~4 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=ff8d255b6a2657d79ac65774b612ca89c4ba0127;p=thirdparty%2Fsquid.git Don't try to write autoconf snippets when having a fewer.. --- diff --git a/configure.in b/configure.in index 5d939417ef..05e1f41661 100644 --- a/configure.in +++ b/configure.in @@ -2766,9 +2766,9 @@ AC_ARG_WITH(caps, AS_HELP_STRING([--without-libcap],[disable usage of Linux capa if test "x$use_caps" != "xno"; then # cap_clear_flag is the most recent libcap function we require AC_CHECK_LIB(cap, cap_clear_flag) - if test "x$ac_cv_lib_cap_cap_clear_flag" != xyes + if test "x$ac_cv_lib_cap_cap_clear_flag" != xyes; then if test "x$use_caps" = "xyes"; then - AC_MSG_ERROR("libcap forced enabled but not available or not usable, requires libcap-2.09 or later") + AC_MSG_ERROR([libcap forced enabled but not available or not usable, requires libcap-2.09 or later]) fi use_caps=no fi @@ -2777,13 +2777,19 @@ if test "x$use_caps" != "xno"; then AC_DEFINE(USE_LIBCAP, 1, [use libcap to set capabilities required for TPROXY]) dnl Check for libcap headader breakage. AC_CHECK_HEADERS(sys/capability.h) - AC_CACHE_CHECK([for operational libcap2 headers], squid_cv_libcap_broken, - AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include ]], [[ - capget(NULL, NULL); - capset(NULL, NULL); - ]])],[squid_cv_libcap_broken=0],[squid_cv_libcap_broken=1]) + AC_CACHE_CHECK([for operational libcap2 headers], squid_cv_sys_capability_works, + AC_LINK_IFELSE([AC_LANG_PROGRAM([[ +#include +#include +#include +]], [[ +capget(NULL, NULL); +capset(NULL, NULL); + ]])],[squid_cv_sys_capability_works=yes],[squid_cv_sys_capability_works=no]) ) - AC_DEFINE_UNQUOTED([LIBCAP_BROKEN],$squid_cv_libcap_broken,[if libcap2 headers are broken and clashing with glibc]) + if test x$squid_cv_sys_capability_works != xyes; then + AC_DEFINE([LIBCAP_BROKEN],1,[if libcap2 headers are broken and clashing with glibc]) + fi fi