dnl $OpenLDAP$
dnl This work is part of OpenLDAP Software <http://www.openldap.org/>.
dnl
-dnl Copyright 1998-2004 The OpenLDAP Foundation.
+dnl Copyright 1998-2005 The OpenLDAP Foundation.
dnl All rights reserved.
dnl
dnl Redistribution and use in source and binary forms, with or without
# This work is part of OpenLDAP Software <http://www.openldap.org/>.
#
-# Copyright 1998-2004 The OpenLDAP Foundation.
+# Copyright 1998-2005 The OpenLDAP Foundation.
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# top-level directory of the distribution or, alternatively, at
# <http://www.OpenLDAP.org/license.html>.
-echo "Copyright 1998-2004 The OpenLDAP Foundation. All rights reserved."
+echo "Copyright 1998-2005 The OpenLDAP Foundation. All rights reserved."
echo " Restrictions apply, see COPYRIGHT and LICENSE files."
])dnl
dnl ----------------------------------------------------------------
OL_ARG_ENABLE(slp,[ --enable-slp enable SLPv2 support], no)dnl
OL_ARG_ENABLE(wrappers,[ --enable-wrappers enable tcp wrapper support], no)dnl
-
+dnl ----------------------------------------------------------------
+dnl SLAPD Backend Options
Backends="bdb dnssrv hdb ldap ldbm meta monitor null \
passwd perl shell sql"
-dnl SLAPD Backend options
+AC_ARG_WITH(xxslapoverlays,[
+SLAPD Backend Options:])
+
OL_ARG_ENABLE(bdb,[ --enable-bdb enable Berkeley DB backend no|yes|mod], yes, [no yes mod])dnl
OL_ARG_ENABLE(dnssrv,[ --enable-dnssrv enable dnssrv backend no|yes|mod], no, [no yes mod])dnl
OL_ARG_ENABLE(hdb,[ --enable-hdb enable Hierarchical DB backend no|yes|mod], no, [no yes mod])dnl
AC_ARG_WITH(xxslapoverlays,[
SLAPD Overlay Options:])
+
OL_ARG_ENABLE(dyngroup,[ --enable-dyngroup Dynamic Group overlay no|yes|mod], no,
[no yes mod])
OL_ARG_ENABLE(proxycache,[ --enable-proxycache Proxy Cache overlay no|yes|mod], no,
AC_MSG_ERROR([NDBM only supports LDBM type hash])
fi
- if test $ol_enable_bdb = yes -o $ol_enable_hdb = yes ; then
+ if test $ol_enable_bdb != no -o $ol_enable_hdb != no ; then
if test $ol_with_ldbm_api = auto ; then
ol_with_ldbm_api=berkeley
elif test $ol_with_ldbm_api != berkeley ; then
AC_MSG_ERROR([LDBM API not compatible with BDB/HDB])
fi
-
- elif test $ol_enable_bdb = auto ; then
- if test $ol_with_ldbm_api != berkeley \
- -o $ol_with_ldbm_api != auto ; then
- AC_MSG_WARN([LDBM API not compatible with BDB, disabling BDB])
- ol_enable_bdb=no
- fi
fi
fi
-if test $ol_enable_chain != no -a $ol_enable_ldap = no ; then
- AC_MSG_ERROR([--enable-chain requires --enable-ldap])
-fi
-
if test $ol_enable_meta = yes -a $ol_enable_ldap = no ; then
AC_MSG_ERROR([--enable-meta requires --enable-ldap])
fi
dnl ----------------------------------------------------------------
dnl Checks for libraries
+AC_CHECK_FUNCS( sigaction sigset )
+
dnl HP-UX requires -lV3
dnl this is not needed on newer versions of HP-UX
-AC_CHECK_LIB(V3, sigset)
+if test $ac_cv_func_sigaction = no && test $ac_cv_func_sigaction = no ; then
+ AC_CHECK_LIB(V3, sigset)
+fi
dnl The following is INTENTIONALLY scripted out because shell does not
dnl support variable names with the '@' character, which is what
ac_cv_func_res_query=$ac_cv_lib_resolv___res_query
fi
+if test $ac_cv_func_res_query = no ; then
+ AC_CHECK_LIB(resolv, _res_9_query)
+ ac_cv_func_res_query=$ac_cv_lib_resolv_res_9_query
+fi
+
if test "$ac_cv_func_res_query" = yes ; then
AC_DEFINE(HAVE_RES_QUERY,1,
[define if you have res_query()])
fi
fi
-if test $ol_enable_bdb = yes -a $ol_link_ldbm != berkeley ; then
- AC_MSG_ERROR(BDB: BerkeleyDB not available)
-elif test $ol_enable_bdb != no -a $ol_link_ldbm = berkeley ; then
- OL_BDB_COMPAT
-
- if test $ol_cv_bdb_compat = yes ; then
- ol_enable_bdb=yes
- elif test $ol_enable_bdb = yes ; then
- AC_MSG_ERROR([BDB: BerkeleyDB version incompatible])
+if test $ol_enable_bdb != no -o $ol_enable_hdb != no; then
+ if test $ol_link_ldbm != berkeley ; then
+ AC_MSG_ERROR(BDB/HDB: BerkeleyDB not available)
else
- ol_enable_bdb=no
+ OL_BDB_COMPAT
+
+ if test $ol_cv_bdb_compat != yes ; then
+ AC_MSG_ERROR([BDB/HDB: BerkeleyDB version incompatible])
+ fi
fi
fi
-if test $ol_enable_hdb = yes -a $ol_link_ldbm != berkeley ; then
- AC_MSG_ERROR([HDB: BerkeleyDB not available])
-fi
if test $ol_link_ldbm = no -a $ol_with_ldbm_type = btree ; then
AC_MSG_WARN([Could not find LDBM with BTREE support])
ol_enable_ldbm=no
fi
+if test $ol_enable_bdb = yes -o \
+ $ol_enable_hdb = yes -o \
+ $ol_enable_ldbm = yes ; then
+ SLAPD_LIBS="$SLAPD_LIBS \$(LDBM_LIBS)"
+fi
+
dnl ----------------------------------------------------------------
if test $ol_enable_dynamic = yes -a $enable_shared = yes ; then
dnl ----------------------------------------------------------------
dnl Checks for library functions.
AC_FUNC_MEMCMP
+
+if test $ac_cv_func_memcmp_clean = no ; then
+ AC_DEFINE(NEED_MEMCMP_REPLACEMENT,1,
+ [define if memcmp is not 8-bit clean or is otherwise broken])
+fi
+
dnl AM_FUNC_MKTIME dnl checks for sys/time.h and unistd.h
AC_FUNC_STRFTIME
dnl AM_FUNC_STRTOD
setsid \
setuid \
seteuid \
- sigaction \
signal \
- sigset \
strdup \
strerror \
strpbrk \