summaryrefslogtreecommitdiffstats
path: root/source3/configure.in
diff options
context:
space:
mode:
authorTim Potter <tpot@samba.org>2002-09-17 05:38:12 +0000
committerTim Potter <tpot@samba.org>2002-09-17 05:38:12 +0000
commitccfe2b848583d4036fb1a11a25e8c87c80e59520 (patch)
tree3b4b7d66aa4c60e1d1b8e9d1b4b83b14bbfd84cf /source3/configure.in
parent83b997118e4cbf8cc794b612a4ac9b8e852f488c (diff)
downloadsamba-ccfe2b848583d4036fb1a11a25e8c87c80e59520.tar.gz
samba-ccfe2b848583d4036fb1a11a25e8c87c80e59520.tar.xz
samba-ccfe2b848583d4036fb1a11a25e8c87c80e59520.zip
Added --with-ads option, defaults to yes. If you run ./configure
--with-ads=no or ./configure --without-ads Samba will build without linking to the various kerberos libraries. (This used to be commit edb6172abf0f07fead8ed3aaaebe0411d757aa64)
Diffstat (limited to 'source3/configure.in')
-rw-r--r--source3/configure.in114
1 files changed, 68 insertions, 46 deletions
diff --git a/source3/configure.in b/source3/configure.in
index 0e4e910f0c7..fe697e4209e 100644
--- a/source3/configure.in
+++ b/source3/configure.in
@@ -1936,63 +1936,85 @@ AC_ARG_WITH(dfs,
AC_MSG_RESULT(no)
)
-
#################################################
-# see if this box has the RedHat location for kerberos
-AC_MSG_CHECKING(for /usr/kerberos)
-if test -d /usr/kerberos; then
+# active directory support
+
+with_ads_support=yes
+AC_MSG_CHECKING([whether to use Active Directory])
+
+AC_ARG_WITH(ads,
+[ --with-ads Active Directory support (default yes)],
+[ case "$withval" in
+ no)
+ with_ads_support=no
+ ;;
+ esac ])
+
+if test x"$with_ads_support" = x"yes"; then
+ AC_DEFINE(WITH_ADS)
+fi
+
+AC_MSG_RESULT($with_ads_support)
+
+if test x"$with_ads_support" = x"yes"; then
+
+ #################################################
+ # see if this box has the RedHat location for kerberos
+ AC_MSG_CHECKING(for /usr/kerberos)
+ if test -d /usr/kerberos; then
LDFLAGS="$LDFLAGS -L/usr/kerberos/lib"
CFLAGS="$CFLAGS -I/usr/kerberos/include"
CPPFLAGS="$CPPFLAGS -I/usr/kerberos/include"
AC_MSG_RESULT(yes)
-else
+ else
AC_MSG_RESULT(no)
-fi
+ fi
-#################################################
-# check for location of Kerberos 5 install
-AC_MSG_CHECKING(for kerberos 5 install path)
-AC_ARG_WITH(krb5,
-[ --with-krb5=base-dir Locate Kerberos 5 support (default=/usr)],
-[ case "$withval" in
- no)
+ #################################################
+ # check for location of Kerberos 5 install
+ AC_MSG_CHECKING(for kerberos 5 install path)
+ AC_ARG_WITH(krb5,
+ [ --with-krb5=base-dir Locate Kerberos 5 support (default=/usr)],
+ [ case "$withval" in
+ no)
+ AC_MSG_RESULT(no)
+ ;;
+ *)
+ AC_MSG_RESULT(yes)
+ LIBS="$LIBS -lkrb5"
+ CFLAGS="$CFLAGS -I$withval/include"
+ CPPFLAGS="$CPPFLAGS -I$withval/include"
+ LDFLAGS="$LDFLAGS -L$withval/lib"
+ ;;
+ esac ],
AC_MSG_RESULT(no)
- ;;
- *)
- AC_MSG_RESULT(yes)
- LIBS="$LIBS -lkrb5"
- CFLAGS="$CFLAGS -I$withval/include"
- CPPFLAGS="$CPPFLAGS -I$withval/include"
- LDFLAGS="$LDFLAGS -L$withval/lib"
- ;;
- esac ],
- AC_MSG_RESULT(no)
-)
-
-# now check for krb5.h. Some systems have the libraries without the headers!
-# note that this check is done here to allow for different kerberos
-# include paths
-AC_CHECK_HEADERS(krb5.h)
-
-# now check for gssapi headers. This is also done here to allow for
-# different kerberos include paths
-AC_CHECK_HEADERS(gssapi/gssapi_generic.h gssapi/gssapi.h)
-
-##################################################################
-# we might need the k5crypto and com_err libraries on some systems
-AC_CHECK_LIB(com_err, _et_list, [LIBS="$LIBS -lcom_err"])
-AC_CHECK_LIB(k5crypto, krb5_encrypt_data, [LIBS="$LIBS -lk5crypto"])
-
-########################################################
-# now see if we can find the krb5 libs in standard paths
-# or as specified above
-AC_CHECK_LIB(krb5, krb5_mk_req_extended, [LIBS="$LIBS -lkrb5";
+ )
+
+ # now check for krb5.h. Some systems have the libraries without the headers!
+ # note that this check is done here to allow for different kerberos
+ # include paths
+ AC_CHECK_HEADERS(krb5.h)
+
+ # now check for gssapi headers. This is also done here to allow for
+ # different kerberos include paths
+ AC_CHECK_HEADERS(gssapi/gssapi_generic.h gssapi/gssapi.h)
+
+ ##################################################################
+ # we might need the k5crypto and com_err libraries on some systems
+ AC_CHECK_LIB(com_err, _et_list, [LIBS="$LIBS -lcom_err"])
+ AC_CHECK_LIB(k5crypto, krb5_encrypt_data, [LIBS="$LIBS -lk5crypto"])
+
+ ########################################################
+ # now see if we can find the krb5 libs in standard paths
+ # or as specified above
+ AC_CHECK_LIB(krb5, krb5_mk_req_extended, [LIBS="$LIBS -lkrb5";
AC_DEFINE(HAVE_KRB5)])
-########################################################
-# now see if we can find the gssapi libs in standard paths
-AC_CHECK_LIB(gssapi_krb5, gss_display_status, [LIBS="$LIBS -lgssapi_krb5";
+ ########################################################
+ # now see if we can find the gssapi libs in standard paths
+ AC_CHECK_LIB(gssapi_krb5, gss_display_status, [LIBS="$LIBS -lgssapi_krb5";
AC_DEFINE(HAVE_GSSAPI)])
+fi
##################################################################
# we might need the lber lib on some systems. To avoid link errors