summaryrefslogtreecommitdiff
path: root/devel/ldapsdk/Makefile
blob: d597316073e18bc158f9cdbee4f013afab3a0fcf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
# $NetBSD: Makefile,v 1.33 2012/10/03 21:54:31 wiz Exp $

DISTNAME=	ldapsdk_12311998
PKGNAME=	${DISTNAME:S/_/-/}
PKGREVISION=	3
CATEGORIES=	devel databases
MASTER_SITES=	${MASTER_SITE_MOZILLA_ALL:=directory/c-sdk/ancient/}

MAINTAINER=	pkgsrc-users@NetBSD.org
HOMEPAGE=	http://www.mozilla.org/directory/
COMMENT=	LDAP C-SDK from the Mozilla project

CONFLICTS+=	openldap-client-[0-9]*

PKG_DESTDIR_SUPPORT=	user-destdir
NOT_FOR_BULK_PLATFORM=	Linux-*-*

MAKE_JOBS_SAFE=	no

WRKSRC=		${WRKDIR}/mozilla
USE_TOOLS+=	gmake perl

PKG_SYSCONFSUBDIR=	ldapsdk
EGDIR=			${PREFIX}/share/examples/ldapsdk

MAKE_ENV+=	MOZILLA_CLIENT=1
MAKE_ENV+=	NO_MDUPDATE=1
MAKE_ENV+=	MOZ_LDAP_SDK=1
MAKE_FILE=	${WRKSRC}/directory/ldapsdk.mk
BUILD_TARGET=	build
BUILD_DIRS=	config .

AUTO_MKDIRS=			yes

post-extract:
	${LN} -s FreeBSD.mk ${WRKSRC}/config/DragonFly.mk

do-configure:
	${ECHO} "PKG_SYSCONFDIR=${PKG_SYSCONFDIR}" >> ${WRKSRC}/config/rules.mk
	${ECHO} "EGDIR=${EGDIR}" >> ${WRKSRC}/config/rules.mk

do-install:
	cd ${WRKSRC}/dist/public/ldap \
	&& ${INSTALL_DATA} disptmpl.h lber.h ldap.h srchpref.h ${DESTDIR}${PREFIX}/include
	#
	# XXX kludge
	#
	${INSTALL_DATA} ${WRKSRC}/dist/${OPSYS}*/lib/libldap.a ${DESTDIR}${PREFIX}/lib/libldap.a
	${INSTALL_DATA} ${WRKSRC}/dist/${OPSYS}*/lib/liblber.a ${DESTDIR}${PREFIX}/lib/liblber.a
	${INSTALL_LIB} ${WRKSRC}/dist/${OPSYS}*/bin/libldap.so.1.0 ${DESTDIR}${PREFIX}/lib/libldap.so.1.0
	${LN} -sf libldap.so.1.0 ${DESTDIR}${PREFIX}/lib/libldap.so.1
	${LN} -sf libldap.so.1.0 ${DESTDIR}${PREFIX}/lib/libldap.so
	${INSTALL_LIB} ${WRKSRC}/dist/${OPSYS}*/bin/liblber.so.1.0 ${DESTDIR}${PREFIX}/lib/liblber.so.1.0
	${LN} -sf liblber.so.1.0 ${DESTDIR}${PREFIX}/lib/liblber.so.1
	${LN} -sf liblber.so.1.0 ${DESTDIR}${PREFIX}/lib/liblber.so
	${INSTALL_DATA_DIR} ${DESTDIR}${EGDIR}
	${INSTALL_DATA} ${WRKSRC}/dist/${OPSYS}*/etc/ldapfilter.conf      ${DESTDIR}${EGDIR}/ldapfilter.conf
	${INSTALL_DATA} ${WRKSRC}/dist/${OPSYS}*/etc/ldapsearchprefs.conf ${DESTDIR}${EGDIR}/ldapsearchprefs.conf
	${INSTALL_DATA} ${WRKSRC}/dist/${OPSYS}*/etc/ldapfriendly         ${DESTDIR}${EGDIR}/ldapfriendly
	${INSTALL_DATA} ${WRKSRC}/dist/${OPSYS}*/etc/ldaptemplates.conf   ${DESTDIR}${EGDIR}/ldaptemplates.conf

.include "../../mk/bsd.pkg.mk"