1
0
mirror of https://git.FreeBSD.org/ports.git synced 2025-02-01 10:59:55 +00:00

Add option for smbk5pwd overlay.

PR:		ports/126367
Submitted by:	Alexander Kriventsov <akriventsov xx masterhost.ru>
Approved by:	maintainer timeout
This commit is contained in:
Sergey Skvortsov 2008-09-04 17:36:25 +00:00
parent 90f52b3e1d
commit d68f711af0
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=219853
3 changed files with 47 additions and 1 deletions

View File

@ -39,7 +39,7 @@ BROKEN= incompatible OpenLDAP version: ${WANT_OPENLDAP_VER}
.endif
PORTREVISION_CLIENT= 0
PORTREVISION_SERVER= 0
PORTREVISION_SERVER= 1
.if !defined(CLIENT_ONLY)
OPTIONS= SASL "With (Cyrus) SASL2 support" off \
@ -74,6 +74,7 @@ OPTIONS= SASL "With (Cyrus) SASL2 support" off \
TRANSLUCENT "With Translucent Proxy overlay" off \
UNIQUE "With attribute Uniqueness overlay" off \
VALSORT "With Value Sorting overlay" off \
SMBPWD "With Samba Password hashes overlay" off \
DYNAMIC_BACKENDS "Build dynamic backends" on
.endif
@ -388,6 +389,12 @@ BROKEN= choose either iODBC or unixODBC for WITH_ODBC_TYPE
PLIST_SUB+= BACK_SQL="@comment "
.endif
.if defined(WITH_SMBPWD)
PLIST_SUB+= SMBPWD=""
.else
PLIST_SUB+= SMBPWD="@comment "
.endif
.if defined(WITH_RLOOKUPS)
CONFIGURE_ARGS+= --enable-rlookups
PLIST_SUB+= RLOOKUPS=""
@ -460,6 +467,12 @@ test: build
${MAKE} ${MAKE_FLAGS} ${MAKEFILE} ${MAKE_ARGS} test
.endif
.if defined(WITH_SMBPWD)
post-build:
@cd ${BUILD_WRKSRC}/contrib/slapd-modules/smbk5pwd; ${SETENV} ${MAKE_ENV} \
${MAKE} ${MAKE_FLAGS} ${MAKEFILE} ${MAKE_ARGS} DEFS="-DDO_SAMBA" all
.endif
pre-su-install:
@if [ -f ${PKGINSTALL} ]; then \
${SETENV} PKG_PREFIX="${PREFIX}" ${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL; \
@ -489,6 +502,11 @@ post-install:
done >>${TMPPLIST}
@${ECHO_CMD} "@unexec ${RMDIR} %D/etc/openldap/schema 2>/dev/null || true" >>${TMPPLIST}
@${ECHO_CMD} "@unexec ${RMDIR} %D/etc/openldap 2>/dev/null || true" >>${TMPPLIST}
.if defined(WITH_SMBPWD)
@${INSTALL_PROGRAM} ${WRKSRC}/contrib/slapd-modules/smbk5pwd/smbk5pwd.la \
${WRKSRC}/contrib/slapd-modules/smbk5pwd/.libs/smbk5pwd.so.0 ${PREFIX}/libexec/openldap/
@${LN} -s smbk5pwd.so.0 ${PREFIX}/libexec/openldap/smbk5pwd.so
.endif
.endif
@${CAT} ${PKGMESSAGE}

View File

@ -0,0 +1,25 @@
--- contrib/slapd-modules/smbk5pwd/Makefile.orig 2008-09-04 20:37:17.000000000 +0400
+++ contrib/slapd-modules/smbk5pwd/Makefile 2008-09-04 21:06:32.000000000 +0400
@@ -9,7 +9,6 @@
# top-level directory of the distribution or, alternatively, at
# <http://www.OpenLDAP.org/license.html>.
-LIBTOOL=../../../libtool
OPT=-g -O2
CC=gcc
@@ -24,7 +23,7 @@
HEIMDAL_LIB=-L/usr/heimdal/lib -lkrb5 -lkadm5srv
SSL_LIB=-lcrypto
LDAP_LIB=-lldap_r -llber
-LIBS=$(LDAP_LIB) $(HEIMDAL_LIB) $(SSL_LIB)
+LIBS=$(LDAP_LIB) $(SSL_LIB) $(LDFLAGS)
all: smbk5pwd.la
@@ -34,4 +33,4 @@
smbk5pwd.la: smbk5pwd.lo
$(LIBTOOL) --mode=link $(CC) $(OPT) -version-info 0:0:0 \
- -rpath /usr/local/libexec/openldap -module -o $@ $? $(LIBS)
+ -rpath $(PREFIX)/libexec/openldap -module -o $@ $? $(LIBS)

View File

@ -68,6 +68,9 @@ etc/openldap/DB_CONFIG.example
%%BACK_SQL%%libexec/openldap/back_sql-2.4.so.3
%%BACK_SQL%%libexec/openldap/back_sql.la
%%BACK_SQL%%libexec/openldap/back_sql.so
%%SMBPWD%%libexec/openldap/smbk5pwd.la
%%SMBPWD%%libexec/openldap/smbk5pwd.so
%%SMBPWD%%libexec/openldap/smbk5pwd.so.0
libexec/slapd
@dirrmtry libexec/openldap
sbin/slapacl