summaryrefslogtreecommitdiff
path: root/security/cyrus-sasl2/Makefile.common
blob: 90b2dd751526077b01c6fb6bd9c16cee94603ad8 (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
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
# $NetBSD: Makefile.common,v 1.3 2003/05/26 06:53:07 martti Exp $
#
# This Makefile fragment should be included _below_ and SASL_PLUGIN
# definition and _above_ any CONFIGURE_ARGS definitions.

DISTNAME=	cyrus-sasl-2.1.13
CATEGORIES=	security
MASTER_SITES=	ftp://ftp.andrew.cmu.edu/pub/cyrus-mail/ \
		ftp://ftp.andrew.cmu.edu/pub/cyrus-mail/OLD-VERSIONS/sasl/

MAINTAINER=	chris@netbsd.org
HOMEPAGE=	http://asg.web.cmu.edu/sasl/

DISTINFO_FILE=		${.CURDIR}/../cyrus-sasl2/distinfo
FILESDIR=		${.CURDIR}/../cyrus-sasl2/files
PATCHDIR=		${.CURDIR}/../cyrus-sasl2/patches

.if defined(SASL_PLUGIN) && !empty(SASL_PLUGIN:M[yY][eE][sS])
DEPENDS+=		cyrus-sasl>=2.1.12:../../security/cyrus-sasl2
.endif

USE_BUILDLINK2=		YES
USE_PKGINSTALL=		YES
GNU_CONFIGURE=		YES
USE_LIBTOOL=		YES
LTCONFIG_OVERRIDE=	${WRKSRC}/config/ltconfig

.include "../../mk/bsd.prefs.mk"

# CYRUS_USER		username of the Cyrus administrator
# CYRUS_GROUP		group of the Cyrus administrator
#
CYRUS_USER?=		cyrus
CYRUS_GROUP?=		mail
FILES_SUBST+=		CYRUS_USER=${CYRUS_USER}

HTMLDIR=		${PREFIX}/share/doc/html/cyrus-sasl
PLUGINDIR=		${PREFIX}/lib/sasl2
# /var/run/saslauthd matches the default value in configure.
SASLSOCKETDIR=		/var/run/saslauthd
FILES_SUBST+=		SASLSOCKETDIR=${SASLSOCKETDIR}
PLIST_SUBST+=		SASLSOCKETDIR=${SASLSOCKETDIR}

BUILD_DEFS+=		CYRUS_USER CYRUS_GROUP

CONFIGURE_ARGS+=	--with-saslauthd=${SASLSOCKETDIR}
CONFIGURE_ARGS+=	--with-dblib=ndbm
CONFIGURE_ARGS+=	--with-dbpath=${PKG_SYSCONFDIR}/sasldb
CONFIGURE_ARGS+=	--with-plugindir=${PLUGINDIR}

# Authentication mechanisms
CONFIGURE_ARGS+=	--disable-anon		# ANONYMOUS
CONFIGURE_ARGS+=	--disable-cram		# CRAM-MD5
CONFIGURE_ARGS+=	--disable-digest	# DIGEST-MD5
CONFIGURE_ARGS+=	--disable-login		# LOGIN
CONFIGURE_ARGS+=	--disable-ntlm		# NTLM
CONFIGURE_ARGS+=	--disable-plain		# PLAIN
CONFIGURE_ARGS+=	--disable-scram		# SCRAM-MD5
CONFIGURE_ARGS+=	--disable-sia		# SIA
CONFIGURE_ARGS+=	--disable-srp		# SRP
CONFIGURE_ARGS+=	--disable-krb4		# KERBEROS_V4
CONFIGURE_ARGS+=	--disable-gssapi	# GSSAPI
CONFIGURE_ARGS+=	--disable-otp		# OTP
CONFIGURE_ARGS+=	--without-pam

# clean up a bit to help package maintainer produce patch files
post-extract:
	${_PKG_SILENT}${_PKG_DEBUG}			\
	${FIND} ${WRKSRC} -type f -name "*.orig" | ${XARGS} ${RM}

# Left here as reference for patch makers...
#pre-configure:
#	cd ${WRKSRC};					\
#	${ACLOCAL} -I cmulocal -I config;		\
#	${AUTOHEADER};					\
#	${AUTOMAKE} -a --gnu -i ;			\
#	${AUTOCONF}