mirror of
https://git.FreeBSD.org/ports.git
synced 2024-11-23 00:43:28 +00:00
- Fix several default paths relative to PREFIX
- Move REINPLACE_CMDs to the post-patch target to avoid patching the same files again when re-running the install target - Provide a .conf file from the .conf.sample one - Add a LOCAL mirror PR: 154843 Approved by: Michael Graziano <mikeg@bsd-box.net> (maintainer), ehaupt (mentor) Feature safe: yes
This commit is contained in:
parent
638ec6658d
commit
24baed54a8
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=269313
@ -7,9 +7,10 @@
|
||||
|
||||
PORTNAME= nss_ldap
|
||||
PORTVERSION= 1.${NSS_LDAP_VERSION}
|
||||
PORTREVISION= 4
|
||||
PORTREVISION= 5
|
||||
CATEGORIES= net
|
||||
MASTER_SITES= http://www.padl.com/download/
|
||||
MASTER_SITES= http://www.padl.com/download/ \
|
||||
LOCAL/martymac
|
||||
DISTNAME= ${PORTNAME}-${NSS_LDAP_VERSION}
|
||||
|
||||
MAINTAINER= mikeg@bsd-box.net
|
||||
@ -27,9 +28,6 @@ USE_OPENLDAP= yes
|
||||
|
||||
OPTIONS= LCLASS "Enable login classes via the loginClass attribute" on
|
||||
|
||||
PLIST_FILES= etc/nss_ldap.conf.sample \
|
||||
lib/nss_ldap.so.1
|
||||
|
||||
CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include" \
|
||||
LDFLAGS="-L${LOCALBASE}/lib -Wl,-rpath,${LOCALBASE}/lib"
|
||||
|
||||
@ -54,6 +52,13 @@ CFLAGS+="-DHAVE_LOGIN_CLASSES"
|
||||
post-extract:
|
||||
${CP} ${FILESDIR}/bsdnss.c ${WRKSRC}
|
||||
|
||||
post-patch:
|
||||
@${REINPLACE_CMD} -e 's,/etc/ldap\.,${PREFIX}/etc/nss_ldap.,g' \
|
||||
-e 's,/etc/openldap/ldap\.,${PREFIX}/etc/openldap/ldap.,g' \
|
||||
${WRKSRC}/ldap.conf
|
||||
@${REINPLACE_CMD} 's,/etc/ldap\.,${PREFIX}/etc/nss_ldap.,g' \
|
||||
${WRKSRC}/${MAN5}
|
||||
|
||||
# XXX: newer autoconf's rely on the compiler result, not the preprocessor
|
||||
# for checking headers, so the configure.in needs to be fixed upstream
|
||||
# to properly include dependencies
|
||||
@ -65,11 +70,12 @@ post-configure:
|
||||
do-install:
|
||||
${INSTALL_PROGRAM} ${WRKSRC}/nss_ldap.so ${PREFIX}/lib/nss_ldap.so.1
|
||||
${INSTALL_DATA} ${WRKSRC}/ldap.conf ${PREFIX}/etc/nss_ldap.conf.sample
|
||||
@${REINPLACE_CMD} 's,/etc/ldap.,${PREFIX}/etc/nss_ldap.,g' \
|
||||
${WRKSRC}/${MAN5}
|
||||
${INSTALL_MAN} ${WRKSRC}/${MAN5} ${MAN5PREFIX}/man/man5
|
||||
|
||||
post-install:
|
||||
.if !exists(${PREFIX}/etc/nss_ldap.conf)
|
||||
${CP} -p ${PREFIX}/etc/nss_ldap.conf.sample ${PREFIX}/etc/nss_ldap.conf
|
||||
.endif
|
||||
.if !defined(PACKAGE_BUILDING)
|
||||
@${CAT} ${PKGMESSAGE}
|
||||
.endif
|
||||
|
@ -1,3 +1,2 @@
|
||||
MD5 (nss_ldap-265.tar.gz) = c1cb02d1a85538cf16bca6f6a562abe4
|
||||
SHA256 (nss_ldap-265.tar.gz) = 77b54d905f50d774f28d5559d49126f1bc76720f741b0864a64bb4936ec226a8
|
||||
SIZE (nss_ldap-265.tar.gz) = 280976
|
||||
|
4
net/nss_ldap/pkg-plist
Normal file
4
net/nss_ldap/pkg-plist
Normal file
@ -0,0 +1,4 @@
|
||||
lib/nss_ldap.so.1
|
||||
@unexec if cmp -s %D/etc/nss_ldap.conf %D/etc/nss_ldap.conf.sample; then rm -f %D/etc/nss_ldap.conf; fi
|
||||
etc/nss_ldap.conf.sample
|
||||
@exec if [ ! -f %D/etc/nss_ldap.conf ]; then cp %B/%f %D/etc/nss_ldap.conf; fi
|
Loading…
Reference in New Issue
Block a user