aboutsummaryrefslogtreecommitdiff
path: root/net/openldap24-server/Makefile
diff options
context:
space:
mode:
authorOliver Lehmann <oliver@FreeBSD.org>2003-07-07 14:01:25 +0000
committerOliver Lehmann <oliver@FreeBSD.org>2003-07-07 14:01:25 +0000
commit6ef2dc6e19b63972fbcd949d325f74b87ef312b3 (patch)
tree22afa5e37d08484c0d21f291337a812ce0b8c31b /net/openldap24-server/Makefile
parentebb10f1bafc7db5d17db30d21d483e82a7c70283 (diff)
downloadports-6ef2dc6e19b63972fbcd949d325f74b87ef312b3.tar.gz
ports-6ef2dc6e19b63972fbcd949d325f74b87ef312b3.zip
Notes
Diffstat (limited to 'net/openldap24-server/Makefile')
-rw-r--r--net/openldap24-server/Makefile38
1 files changed, 25 insertions, 13 deletions
diff --git a/net/openldap24-server/Makefile b/net/openldap24-server/Makefile
index bccf8e39955d..f13c39a1e86f 100644
--- a/net/openldap24-server/Makefile
+++ b/net/openldap24-server/Makefile
@@ -7,7 +7,7 @@
PORTNAME= openldap
PORTVERSION= ${OPENLDAP_VERSION}.a
-PORTREVISION= 1
+PORTREVISION= 2
CATEGORIES= net databases
MASTER_SITES= ftp://ftp.OpenLDAP.org/pub/OpenLDAP/%SUBDIR%/ \
http://public.planetmirror.com/pub/openldap/%SUBDIR%/ \
@@ -41,15 +41,17 @@ USE_OPENSSL= yes
USE_REINPLACE= yes
USE_LIBTOOL_VER= 14
+PLIST= ${WRKDIR}/pkg-plist
PKGINSTALL= ${WRKDIR}/pkg-install
PKGMESSAGE= ${WRKDIR}/pkg-message
-LOCALSTATEDIR?= /var/db
-LDAP_RUN_DIR?= /var/run/openldap
+LOCALSTATEDIR?= ${DESTDIR}/var/db
+LDAP_RUN_DIR?= ${DESTDIR}/var/run/openldap
WITH_BDB_VER?= 41
-CONFIGURE_ARGS= --with-threads \
+CONFIGURE_ARGS= --enable-dynamic \
+ --with-threads \
--with-tls=openssl
SED_SCRIPT= -e 's,%%PREFIX%%,${PREFIX},g' \
@@ -61,7 +63,7 @@ PKGNAMESUFFIX= -client
CONFIGURE_ARGS+= --disable-slapd
PLIST_SUB+= SERVER="@comment " \
SLAPI="@comment "
-SED_SCRIPT+= -e '/^%%SERVER%%/d'
+SED_SCRIPT+= -e '/^%%SERVER%%/d'
.else
CONFIGURE_ARGS+= --localstatedir=${LOCALSTATEDIR} \
--enable-lmpasswd \
@@ -93,7 +95,6 @@ CONFIGURE_ARGS+= --enable-shell
.endif
.if defined(WITH_PERL)
-.error build with Perl backend broken: <http://www.openldap.org/its/index.cgi/Development?id=2513>
USE_PERL5= yes
CONFIGURE_ARGS+= --enable-perl
.endif
@@ -114,7 +115,6 @@ CONFIGURE_ARGS+= --enable-sql
.if defined(WITH_SLAPI)
LIB_DEPENDS+= ltdl.4:${PORTSDIR}/devel/libltdl
CONFIGURE_ARGS+= --enable-slapi
-LIBS+= -lltdl
PLIST_SUB+= SLAPI=""
.else
PLIST_SUB+= SLAPI="@comment "
@@ -137,7 +137,7 @@ CPPFLAGS+= -D_REENTRANT ${PTHREAD_CFLAGS} \
-I${LOCALBASE}/include
LDFLAGS+= -L${LOCALBASE}/lib
-CONFIGURE_TARGET= --host=${MACHINE_ARCH}-portbld-freebsd${OSREL}
+CONFIGURE_TARGET= --build=${MACHINE_ARCH}-portbld-freebsd${OSREL}
CONFIGURE_ENV= CPPFLAGS="${CPPFLAGS}" \
LDFLAGS="${LDFLAGS}" \
LIBS="${LIBS}"
@@ -167,6 +167,10 @@ post-patch:
@${REINPLACE_CMD} -e 's,%LOCALSTATEDIR%/slapd\.,${LDAP_RUN_DIR}/slapd.,g' \
${WRKSRC}/servers/slapd/slapd.conf
+pre-configure:
+ @${REINPLACE_CMD} -e '/^LIBTOOL=/s^\$$(top_builddir)/libtool^${LIBTOOL}^g' \
+ ${WRKSRC}/configure
+
post-build:
.for script in slapd.sh slurpd.sh
@${SED} ${SED_SCRIPT} ${FILESDIR}/${script} >${WRKDIR}/${script}
@@ -175,6 +179,18 @@ post-build:
@${SED} ${SED_SCRIPT} ${.CURDIR}/${text} >${WRKDIR}/${text}
.endfor
+pre-install:
+ @${CP} ${.CURDIR}/pkg-plist ${PLIST}
+.if !defined(NOPORTDOCS)
+ @for dir in rfc drafts; do \
+ ${FIND} ${WRKSRC}/doc/$${dir} -maxdepth 1 -type f \
+ | ${SED} -e "s,^${WRKSRC}/doc/,%%DOCSDIR%%/," \
+ >>${PLIST}; \
+ ${ECHO_CMD} "@dirrm %%DOCSDIR%%/$${dir}" >>${PLIST}; \
+ done
+ @${ECHO_CMD} "@dirrm %%DOCSDIR%%" >>${PLIST}
+.endif
+
post-install:
.if !defined(CLIENT_ONLY)
@${INSTALL_SCRIPT} ${WRKDIR}/slapd.sh ${WRKDIR}/slurpd.sh ${PREFIX}/etc/rc.d
@@ -185,12 +201,8 @@ post-install:
@for dir in rfc drafts; do \
${MKDIR} ${DOCSDIR}/$${dir}; \
${FIND} ${WRKSRC}/doc/$${dir} -maxdepth 1 -type f \
- -exec ${INSTALL_DATA} {} ${DOCSDIR}/$${dir} \; -print \
- | ${SED} -e "s,^${WRKSRC}/doc/,${DOCSDIR:S,^${PREFIX}/,,}/," \
- >>${TMPPLIST}; \
- ${ECHO_CMD} "@dirrm ${DOCSDIR:S,^${PREFIX}/,,}/$${dir}" >>${TMPPLIST}; \
+ -exec ${INSTALL_DATA} {} ${DOCSDIR}/$${dir} \; ; \
done
- @${ECHO_CMD} "@dirrm ${DOCSDIR:S,^${PREFIX}/,,}" >>${TMPPLIST}
.endif
@${CAT} ${PKGMESSAGE}