Skip to content
Snippets Groups Projects
configure.in 80.8 KiB
Newer Older
dnl $OpenLDAP$
Kurt Zeilenga's avatar
Kurt Zeilenga committed
dnl Copyright 1998-2003 The OpenLDAP Foundation.  All Rights Reserved.
dnl 
dnl Redistribution and use in source and binary forms, with or without
dnl modification, are permitted only as authorized by the OpenLDAP
dnl Public License.  A copy of this license is available at
dnl http://www.OpenLDAP.org/license.html or in file LICENSE in the
dnl top-level directory of the distribution.
dnl ----------------------------------------------------------------
dnl Redefine AC_INIT_BINSH to provide RCS IDs and copyright notice
dnl at top of generated configure script.  Prints simple copyright.
# from] translit([$OpenLDAP$], $")] [
Kurt Zeilenga's avatar
Kurt Zeilenga committed
# Copyright 1998-2003 The OpenLDAP Foundation.  All Rights Reserved.
# Redistribution and use in source and binary forms, with or without
# modification, are permitted only as authorized by the OpenLDAP
# Public License.  A copy of this license is available at
# http://www.OpenLDAP.org/license.html or in file LICENSE in the
# top-level directory of the distribution.
Kurt Zeilenga's avatar
Kurt Zeilenga committed
echo "Copyright 1998-2003 The OpenLDAP Foundation,  All Rights Reserved."
Kurt Zeilenga's avatar
Kurt Zeilenga committed
echo "	Restrictions apply, see COPYRIGHT and LICENSE files."
dnl ----------------------------------------------------------------
dnl Disable config.cache!
define([AC_CACHE_LOAD], )dnl
define([AC_CACHE_SAVE], )dnl
Kurt Zeilenga's avatar
Kurt Zeilenga committed
dnl ================================================================
dnl Configure.in for OpenLDAP
AC_INIT(build/version.sh)dnl
# set unset (borrowed from autoconf 2.49c)
if (OL_FOO=OL_FOO; unset OL_FOO) >/dev/null 2>&1; then
  ol_unset=unset
else
  ol_unset=false
fi
# unset CDPATH
$ol_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
eval `$ac_aux_dir/version.sh`
if test -z "$OL_STRING"; then
	AC_MSG_ERROR([could not determine version])
fi

Kurt Zeilenga's avatar
Kurt Zeilenga committed
if test -f "$ac_aux_dir/shtool" -a ! -d $ac_aux_dir/shtool; then
	ac_cv_shtool="$ac_aux_dir/shtool"
else
	AC_MSG_ERROR([no shtool found in $ac_aux_dir])
fi

SHTOOL="$ac_cv_shtool"
dnl AC_SUBST(SHTOOL)dnl
Kurt Zeilenga's avatar
Kurt Zeilenga committed
TB="`$SHTOOL echo -e '%B' 2>/dev/null`"
TN="`$SHTOOL echo -e '%b' 2>/dev/null`"
OPENLDAP_CVS=""
if test -d $ac_aux_dir/CVS; then
	OPENLDAP_CVS="(from CVS sources) "
fi

echo "Configuring ${TB}${OL_STRING}${TN} ${OPENLDAP_CVS}..."
dnl Determine host platform
dnl		we try not to use this for much
AC_CANONICAL_SYSTEM

AM_INIT_AUTOMAKE([$OL_PACKAGE],[$OL_VERSION], [no defines])dnl
Kurt Zeilenga's avatar
Kurt Zeilenga committed
AC_SUBST(PACKAGE)dnl
AC_SUBST(VERSION)dnl
AC_DEFINE_UNQUOTED(OPENLDAP_PACKAGE,"$PACKAGE",Package)
AC_DEFINE_UNQUOTED(OPENLDAP_VERSION,"$VERSION",Version)
AC_DEFINE_UNQUOTED(LDAP_VENDOR_VERSION,$OL_API_INC,Version)
AC_DEFINE_UNQUOTED(LDAP_VENDOR_VERSION_MAJOR,$OL_MAJOR,Major)
AC_DEFINE_UNQUOTED(LDAP_VENDOR_VERSION_MINOR,$OL_MINOR,Minor)
AC_DEFINE_UNQUOTED(LDAP_VENDOR_VERSION_PATCH,$OL_PATCH,Patch)

OPENLDAP_LIBVERSION=$OL_API_LIB
Kurt Zeilenga's avatar
Kurt Zeilenga committed
AC_SUBST(OPENLDAP_LIBVERSION)dnl
OPENLDAP_RELEASE_DATE="$OL_RELEASE_DATE"
AC_SUBST(OPENLDAP_RELEASE_DATE)dnl

dnl We use autoconf features new to 2.13.
dnl aclocal.m4 should be built using aclocal from automake 1.4
Kurt Zeilenga's avatar
Kurt Zeilenga committed
dnl libtool 1.4.2 should be installed.
AC_PREREQ(2.13)dnl Required Autoconf version
AC_CONFIG_HEADER(include/portable.h include/ldap_features.h include/lber_types.h)dnl
dnl ================================================================
dnl Start Args
AC_MSG_CHECKING(configure arguments)
AC_PREFIX_DEFAULT(/usr/local)

dnl ----------------------------------------------------------------
dnl --with-subdir
ldap_subdir="/openldap"
AC_ARG_WITH(subdir,
Kurt Zeilenga's avatar
Kurt Zeilenga committed
[  --with-subdir=DIR       change default subdirectory used for installs],
[case "$withval" in
	no) ldap_subdir=""
		;;
	yes)
		;;
	/*|\\*)
		;;
	*)
		ldap_subdir="/$withval"
		;;
esac
AC_SUBST(ldap_subdir)dnl

dnl ----------------------------------------------------------------
dnl General "enable" options
OL_ARG_ENABLE(debug,[  --enable-debug 	  enable debugging], yes)dnl
Kurt Zeilenga's avatar
Kurt Zeilenga committed
OL_ARG_ENABLE(dynamic,[  --enable-dynamic	  enable linking built binaries with dynamic libs], no)dnl
OL_ARG_ENABLE(syslog,[  --enable-syslog	  enable syslog support], auto)dnl
OL_ARG_ENABLE(proctitle,[  --enable-proctitle	  enable proctitle support], yes)dnl
dnl OL_ARG_ENABLE(referrals,[  --enable-referrals	  enable LDAPv2+ Referrals (experimental)], no)dnl
ol_enable_referrals=${ol_enable_referrals-no}
dnl OL_ARG_ENABLE(kbind,[  --enable-kbind	  enable LDAPv2+ Kerberos IV bind (deprecated)], no)dnl
ol_enable_kbind=${ol_enable_kbind-no}
OL_ARG_ENABLE(ipv6,[  --enable-ipv6 	  enable IPv6 support], auto)dnl
OL_ARG_ENABLE(local,[  --enable-local	  enable AF_LOCAL (AF_UNIX) socket support], auto)dnl
OL_ARG_ENABLE(x_compile,[  --enable-x-compile	  enable cross compiling],
	no, [yes no])dnl
dnl ----------------------------------------------------------------
dnl General "with" options
dnl OL_ARG_ENABLE(dmalloc,[  --enable-dmalloc	  enable debug malloc support], no)dnl
OL_ARG_WITH(cyrus_sasl,[  --with-cyrus-sasl	  with Cyrus SASL support],
	auto, [auto yes no] )
Kurt Zeilenga's avatar
Kurt Zeilenga committed
OL_ARG_WITH(fetch,[  --with-fetch		  with fetch(3) URL support],
	auto, [auto yes no] )
OL_ARG_WITH(kerberos,[  --with-kerberos	  with Kerberos support],
	auto, [auto k5 k5only k425 kth k4 afs yes no])
OL_ARG_WITH(readline,[  --with-readline	  with readline support],
OL_ARG_WITH(threads,[  --with-threads	  with threads],
	auto, [auto nt posix mach pth lwp yes no manual] )
OL_ARG_WITH(tls,[  --with-tls		  with TLS/SSL support],
Bart Hartgers's avatar
 
Bart Hartgers committed
	auto, [auto ssleay openssl yes no] )
OL_ARG_WITH(yielding_select,[  --with-yielding-select  with implicitly yielding select],
dnl ----------------------------------------------------------------
dnl Server options
dnl ----------------------------------------------------------------
dnl ----------------------------------------------------------------
dnl SLAPD OPTIONS
Kurt Zeilenga's avatar
Kurt Zeilenga committed
AC_ARG_WITH(xxslapdoptions,[
SLAPD (Standalone LDAP Daemon) Options:])
OL_ARG_ENABLE(slapd,[  --enable-slapd	  enable building slapd], yes)dnl
Kurt Zeilenga's avatar
Kurt Zeilenga committed
OL_ARG_ENABLE(aci,[    --enable-aci	  enable per-object ACIs (experimental)], no)dnl
OL_ARG_ENABLE(cleartext,[    --enable-cleartext	  enable cleartext passwords], yes)dnl
OL_ARG_ENABLE(crypt,[    --enable-crypt	  enable crypt(3) passwords], no)dnl
Kurt Zeilenga's avatar
Kurt Zeilenga committed
OL_ARG_ENABLE(kpasswd,[    --enable-kpasswd	  enable Kerberos password verification], no)dnl
OL_ARG_ENABLE(lmpasswd,[    --enable-lmpasswd	  enable LAN Manager passwords], no)dnl
OL_ARG_ENABLE(spasswd,[    --enable-spasswd	  enable (Cyrus) SASL password verification], no)dnl
OL_ARG_ENABLE(modules,[    --enable-modules	  enable dynamic module support], no)dnl
dnl OL_ARG_ENABLE(multimaster,[    --enable-multimaster  enable multimaster replication], no)dnl
ol_enable_multimaster=${ol_enable_multimaster-no}
OL_ARG_ENABLE(phonetic,[    --enable-phonetic	  enable phonetic/soundex], no)dnl
OL_ARG_ENABLE(rewrite,[    --enable-rewrite	  enable DN rewriting in back-ldap and back-meta], no)dnl
OL_ARG_ENABLE(rlookups,[    --enable-rlookups	  enable reverse lookups of client hostnames], no)dnl
Kurt Zeilenga's avatar
Kurt Zeilenga committed
OL_ARG_ENABLE(slapi,[    --enable-slapi        enable installation of slapi library], no)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 SLAPD Backend options
OL_ARG_ENABLE(bdb,[    --enable-bdb	  enable Berkeley DB backend], yes)dnl
OL_ARG_WITH(bdb_module,[    --with-bdb-module     module type static|dynamic], static,
	[static dynamic])
OL_ARG_ENABLE(dnssrv,[    --enable-dnssrv	  enable dnssrv backend], no)dnl
OL_ARG_WITH(dnssrv_module,[    --with-dnssrv-module  module type static|dynamic], static,
OL_ARG_ENABLE(ldap,[    --enable-ldap	  enable ldap backend], no)dnl
OL_ARG_WITH(ldap_module,[    --with-ldap-module	  module type static|dynamic], static,
Loading
Loading full blame...