diff options
author | ghen <ghen> | 2006-05-31 18:17:49 +0000 |
---|---|---|
committer | ghen <ghen> | 2006-05-31 18:17:49 +0000 |
commit | c370c2f0fc9109151b62ccec8f184921d3659185 (patch) | |
tree | 9b7d6f4fb22d372b4206aa30abf654b79ca4cc57 /databases/openldap/Makefile.common | |
parent | ce377dd12cbbbc4a76c60d519458c4505f1bbe87 (diff) | |
download | pkgsrc-c370c2f0fc9109151b62ccec8f184921d3659185.tar.gz |
Split the databases/openldap package in -client and -server component packages
(and add a -doc component), which I'll import in a minute. This package is now
nothing but a meta-package, depending on those three. Take over MAINTAINERship
(ok with joerg). Add an inet6 option to -client and -server (PR pkg/33524).
Bump PKGREVISION.
Diffstat (limited to 'databases/openldap/Makefile.common')
-rw-r--r-- | databases/openldap/Makefile.common | 104 |
1 files changed, 104 insertions, 0 deletions
diff --git a/databases/openldap/Makefile.common b/databases/openldap/Makefile.common new file mode 100644 index 00000000000..7a8bb7be9be --- /dev/null +++ b/databases/openldap/Makefile.common @@ -0,0 +1,104 @@ +# $NetBSD: Makefile.common,v 1.1 2006/05/31 18:17:49 ghen Exp $ + +DISTNAME= openldap-2.3.23 +CATEGORIES= databases +MASTER_SITES= ftp://ftp.openldap.org/pub/OpenLDAP/openldap-release/ +MASTER_SITES+= http://ftp.openldap.org/pub/OpenLDAP/openldap-release/ +EXTRACT_SUFX= .tgz + +MAINTAINER= ghen@NetBSD.org +HOMEPAGE= http://www.openldap.org/ + +CONFLICTS+= ldapsdk-[0-9]* + +DISTINFO_FILE= ${.CURDIR}/../../databases/openldap/distinfo +PATCHDIR= ${.CURDIR}/../../databases/openldap/patches +FILESDIR= ${.CURDIR}/../../databases/openldap/files + +USE_LIBTOOL= yes +GNU_CONFIGURE= yes +TEST_TARGET= test + +MAKE_ENV+= LIBMODE=${LIBMODE:Q} + +.include "../../mk/bsd.prefs.mk" + +OPENLDAP_ETCDIR?= ${PKG_SYSCONFDIR}/openldap +OPENLDAP_MODULEDIR= ${PREFIX}/lib/openldap +OPENLDAP_VARDIR?= ${VARBASE}/openldap + +SLAPD_USER?= slapd +SLURPD_USER?= slurpd +LDAP_GROUP?= ldap + +.include "${.CURDIR}/options.mk" + +# the internal avl_* prototypes conflict with those in <sys/avl.h> which +# is included by another system header file on Solaris, so subst them. +.if ${OPSYS} == "SunOS" +SUBST_CLASSES+= conflict +SUBST_STAGE.conflict= post-patch +SUBST_FILES.conflict= ${WRKSRC}/*/*.h +SUBST_FILES.conflict+= ${WRKSRC}/*/*/*.c ${WRKSRC}/*/*/*/*.c +SUBST_SED.conflict+= -e 's,avl_free,openldap_avl_free,g' +SUBST_SED.conflict+= -e 's,avl_insert,openldap_avl_insert,g' +SUBST_SED.conflict+= -e 's,avl_delete,openldap_avl_delete,g' +SUBST_SED.conflict+= -e 's,avl_find,openldap_avl_find,g' +SUBST_SED.conflict+= -e 's,avl_find2,openldap_avl_find2,g' +SUBST_MESSAGE.conflict= Fixing conflicting function prototypes. +.endif + +CPPFLAGS.Darwin+= -DBIND_8_COMPAT + +CONFIGURE_ARGS+= --sysconfdir=${PKG_SYSCONFDIR:Q} +CONFIGURE_ARGS+= --localstatedir=${OPENLDAP_VARDIR:Q} +CONFIGURE_ARGS+= --enable-dynamic +CONFIGURE_ARGS+= --with-tls=openssl + +EGDIR= ${PREFIX}/share/examples/openldap + +CONF_FILES= # empty +CONF_FILES_PERMS= # empty +.for FILE in ${CNFS} +CONF_FILES+= ${EGDIR}/${FILE:Q} ${OPENLDAP_ETCDIR}/${FILE:Q} +.endfor +.for FILE in ${CNFS_PERMS} +CONF_FILES_PERMS+= ${EGDIR}/${FILE:Q} ${OPENLDAP_ETCDIR}/${FILE:Q} ${OPENLDAP_FILEPERMS} +.endfor + +DB_CONFIG?= # empty + +PTHREAD_OPTS+= require + +.include "../../security/openssl/buildlink3.mk" +.include "../../security/tcp_wrappers/buildlink3.mk" +.include "../../mk/pthread.buildlink3.mk" + +.if ${PTHREAD_TYPE} == "native" +CONFIGURE_ARGS+= --with-threads +.elif ${PTHREAD_TYPE} == "pth" +CONFIGURE_ARGS+= --with-threads=pth + +# +# Don't use a larger FD_SETSIZE than GNU Pth can handle (value taken from +# pth.h header). +# +PTH_FDSETSIZE_cmd= \ + if ${TEST} -f ${BUILDLINK_PREFIX.pth:Q}/include/pth.h; then \ + ${AWK} '/if FD_SETSIZE >/ { print $$4 }' \ + ${BUILDLINK_PREFIX.pth}/include/pth.h; \ + else \ + ${ECHO} 0; \ + fi +CPPFLAGS+= -DOPENLDAP_FD_SETSIZE=${PTH_FDSETSIZE_cmd:sh:Q} +.endif + +MAKE_FLAGS+= moduledir=${OPENLDAP_MODULEDIR:Q} +INSTALL_MAKE_FLAGS= ${MAKE_FLAGS} sysconfdir=${EGDIR:Q} + +# Set the correct file modes for the example config files. +post-install: +.for file in ${CNFS} ${CNFS_PERMS} ${DB_CONFIG} + ${CHMOD} ${SHAREMODE} ${EGDIR}/${file:Q} + ${RM} -f ${EGDIR}/${file:Q}.default +.endfor |