aboutsummaryrefslogtreecommitdiffstats
path: root/security/cyrus-sasl2-ldapdb/Makefile
blob: c86b1222e7e033790d8641f17a0f9f453cd32be3 (plain) (blame)
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
63
64
65
66
67
68
69
70
71
72
73
74
75
# $FreeBSD$

PORTNAME=   ldapdb
PORTVERSION=    2.1.26
#PORTREVISION=  0
CATEGORIES= security ipv6
MASTER_SITES=   ftp://ftp.cyrusimap.org/cyrus-sasl/
PKGNAMEPREFIX=  cyrus-sasl-
DISTNAME=   ${PKGNAMEPREFIX}${PORTVERSION}

MAINTAINER= ume@FreeBSD.org
COMMENT=    SASL LDAPDB auxprop plugin

LICENSE=    BSD
LICENSE_FILE=   ${WRKSRC}/COPYING

LIB_DEPENDS=    sasl2:${PORTSDIR}/security/cyrus-sasl2

CYRUS_SASL2_DIR=${MASTERDIR}/../cyrus-sasl2
DISTINFO_FILE=  ${CYRUS_SASL2_DIR}/distinfo
PATCHDIR=   ${CYRUS_SASL2_DIR}/files
INSTALL_WRKSRC= ${WRKSRC}/plugins

MAKE_JOBS_SAFE= yes

USE_LDCONFIG=   yes

USE_AUTOTOOLS=  libtool
USE_OPENSSL=    yes
GNU_CONFIGURE=  yes

.if defined(WITH_OPENLDAP_VER)
WANT_OPENLDAP_VER=  ${WITH_OPENLDAP_VER}
.endif
USE_OPENLDAP=   yes

CONFIGURE_ARGS= --sysconfdir=${PREFIX}/etc \
        --with-plugindir=${PREFIX}/lib/sasl2 \
        --with-dbpath=${PREFIX}/etc/sasldb2 \
        --with-lib-subdir=lib \
        --includedir=${PREFIX}/include \
        --enable-static \
        --with-rc4=openssl

CONFIGURE_ARGS+=--with-dblib=none \
        --disable-anon \
        --disable-cram \
        --disable-digest \
        --disable-gssapi \
        --disable-krb4 \
        --disable-ntlm \
        --disable-otp \
        --disable-plain \
        --disable-scram

CONFIGURE_ARGS+=--enable-ldapdb --with-ldap=${LOCALBASE}

PLIST_FILES=    lib/sasl2/libldapdb.a \
        lib/sasl2/libldapdb.la \
        lib/sasl2/libldapdb.so \
        lib/sasl2/libldapdb.so.3

.include <bsd.port.pre.mk>

.if ${OPENSSLBASE} == /usr
CONFIGURE_ARGS+=--with-openssl=yes
.else
CONFIGURE_ARGS+=--with-openssl=${OPENSSLBASE}
.endif

do-build:
    cd ${WRKSRC}/include && ${MAKE}
    cd ${WRKSRC}/plugins && ${MAKE}

.include <bsd.port.post.mk>