1 ## Copyright (C) 1996-2015 The Squid Software Foundation and contributors
3 ## Squid software is distributed under GPLv2+ license and includes
4 ## contributions from numerous individuals and organizations.
5 ## Please see the COPYING and CONTRIBUTORS files for details.
8 # This file is supposed to run all the tests required to identify which
9 # configured modules are able to be built in this environment
11 # FIXME: de-duplicate $enable_auth_negotiate list containing double entries.
13 #not specified. Inherit global
14 if test "x$enable_auth_negotiate" = "x"; then
15 enable_auth_negotiate=$enable_auth
17 #conflicts with global
18 if test "x$enable_auth_negotiate" != "xno" -a "x$enable_auth" = "xno" ; then
19 AC_MSG_ERROR([Negotiate auth requested but auth disabled])
21 #define list of modules to build
22 if test "x$enable_auth_negotiate" = "xyes" ; then
23 SQUID_LOOK_FOR_MODULES([$srcdir/helpers/negotiate_auth],[enable_auth_negotiate])
25 #handle the "none" special case
26 if test "x$enable_auth_negotiate" = "xnone" ; then
27 enable_auth_negotiate=""
30 NEGOTIATE_AUTH_HELPERS=""
31 enable_auth_negotiate="`echo $enable_auth_negotiate| sed -e 's/,/ /g;s/ */ /g'`"
32 if test "x$enable_auth_negotiate" != "xno" ; then
33 AUTH_MODULES="$AUTH_MODULES negotiate"
34 AC_DEFINE([HAVE_AUTH_MODULE_NEGOTIATE],1,[Negotiate auth module is built])
35 for helper in $enable_auth_negotiate; do
36 dir="$srcdir/helpers/negotiate_auth/$helper"
38 # modules converted to autoconf macros already
39 # NP: we only need this list because m4_include() does not accept variables
40 if test "x$helper" = "xSSPI" ; then
41 m4_include([helpers/negotiate_auth/SSPI/required.m4])
43 elif test "x$helper" = "xkerberos" ; then
44 m4_include([helpers/negotiate_auth/kerberos/required.m4])
46 elif test "x$helper" = "xwrapper" ; then
47 m4_include([helpers/negotiate_auth/wrapper/required.m4])
49 # modules not yet converted to autoconf macros (or third party drop-in's)
50 elif test -f "$dir/config.test" && sh "$dir/config.test" "$squid_host_os"; then
51 BUILD_HELPER="$helper"
54 if test -d "$srcdir/helpers/negotiate_auth/$helper"; then
55 if test "$BUILD_HELPER" != "$helper"; then
56 AC_MSG_NOTICE([Negotiate auth helper $helper ... found but cannot be built])
58 NEGOTIATE_AUTH_HELPERS="$NEGOTIATE_AUTH_HELPERS $BUILD_HELPER"
61 AC_MSG_ERROR([Negotiate auth helper $helper ... not found])
66 AC_MSG_NOTICE([Negotiate auth helpers to be built: $NEGOTIATE_AUTH_HELPERS])
67 AM_CONDITIONAL(ENABLE_AUTH_NEGOTIATE, test "x$enable_auth_negotiate" != "xno")
68 AC_SUBST(NEGOTIATE_AUTH_HELPERS)