1 # $NetBSD: Makefile,v 1.31 2008/11/21 03:24:29 ahoka Exp $
4 PKGNAME= ${DISTNAME:S/_/-/}
7 MASTER_SITES= ftp://ftp.padl.com/pub/ \
8 http://www.padl.com/download/
10 MAINTAINER= rh@NetBSD.org
11 HOMEPAGE= http://www.padl.com/pam_ldap.html
12 COMMENT= Pluggable authentication module for LDAP directories
14 PKG_DESTDIR_SUPPORT= user-destdir
19 CONFIGURE_ARGS+= --with-ldap-lib=openldap
20 CONFIGURE_ARGS+= --with-ldap-dir=${BUILDLINK_PREFIX.openldap-client}
21 CONFIGURE_ARGS+= --with-ldap-conf-file=${PKG_SYSCONFDIR}/pam_ldap.conf
22 CONFIGURE_ARGS+= --with-ldap-secret-file=${PKG_SYSCONFDIR}/pam_ldap.secret
23 CONFIGURE_ARGS+= --sysconfdir=${PKG_SYSCONFDIR:Q}
25 MAKE_ENV+= SHLIBTOOL=${SHLIBTOOL:Q}
27 # Fix (workaround?) a bug with openpam/NetBSD
28 # The bug is described in PR security/39313.
30 .include "../../mk/bsd.prefs.mk"
32 .if ${OPSYS} == "NetBSD"
33 CFLAGS+= -DNO_STATIC_MODULES
36 INSTALL_MAKE_FLAGS= ${MAKE_FLAGS} sysconfdir=${EGDIR}
37 INSTALL_TARGET= install install-data
39 DOCDIR= ${PREFIX}/share/doc/${PKGBASE}
40 EGDIR= ${PREFIX}/share/examples/${PKGBASE}
42 INSTALLATION_DIRS= ${DOCDIR}
44 CONF_FILES= ${EGDIR}/pam_ldap.conf ${PKG_SYSCONFDIR}/pam_ldap.conf
46 .include "../../databases/openldap-client/buildlink3.mk"
47 .include "../../mk/pam.buildlink3.mk"
50 .for file in COPYING COPYING.LIB
51 cd ${WRKSRC} && ${INSTALL_DATA} ${file} ${DESTDIR}${DOCDIR}
53 .for file in ldapns.schema ns-pwd-policy.schema
54 cd ${WRKSRC} && ${INSTALL_DATA} ${file} ${DESTDIR}${EGDIR}
57 .include "../../mk/bsd.pkg.mk"