openbsd-ports/mail/dovecot/Makefile

119 lines
2.8 KiB
Makefile
Raw Normal View History

2007-12-31 05:31:11 -05:00
# $OpenBSD: Makefile,v 1.90 2007/12/31 10:31:11 jakob Exp $
2006-12-02 05:34:30 -05:00
SHARED_ONLY= Yes
COMMENT-server= compact IMAP/POP3 server
COMMENT-sieve= sieve mail filtering for Dovecot
2007-08-27 03:48:55 -04:00
V_MAJOR= 1.0
2007-12-31 05:31:11 -05:00
V_DOVECOT= 1.0.10
2007-08-27 03:48:55 -04:00
V_SIEVE= 1.0.2
2007-09-08 04:44:39 -04:00
PKGNAME= dovecot-${V_DOVECOT}
PKGNAME-server= dovecot-${V_DOVECOT}
2007-12-31 05:31:11 -05:00
PKGNAME-sieve= dovecot-sieve-${V_SIEVE}p7
DISTNAME= dovecot-${V_DOVECOT}
CATEGORIES= mail
2007-09-08 04:44:39 -04:00
MASTER_SITES= ${HOMEPAGE}releases/${V_MAJOR}/
MASTER_SITES0= ${HOMEPAGE}releases/sieve/
2007-09-08 04:44:39 -04:00
DISTFILES= dovecot-${V_DOVECOT}.tar.gz \
dovecot-sieve-${V_SIEVE}.tar.gz:0
HOMEPAGE= http://www.dovecot.org/
MAINTAINER= Brad Smith <brad@comstyle.com>
# MIT/LGPL
PERMIT_PACKAGE_CDROM= Yes
PERMIT_PACKAGE_FTP= Yes
PERMIT_DISTFILES_CDROM= Yes
PERMIT_DISTFILES_FTP= Yes
WANTLIB-server= c crypto ssl z
WANTLIB-sieve=
2004-08-10 05:14:47 -04:00
MODULES= converters/libiconv
MULTI_PACKAGES= -server
2006-12-01 18:57:28 -05:00
SUBPACKAGE?= -server
PSEUDO_FLAVORS= no_sieve
2007-03-22 02:59:13 -04:00
FLAVORS= ldap mysql postgresql sqlite
FLAVOR?=
USE_LIBTOOL= Yes
CONFIGURE_STYLE= gnu
CONFIGURE_ARGS+= --localstatedir=/var \
--with-ioloop=kqueue \
--with-ssl=openssl \
--with-ssldir=/etc/ssl \
--without-pam \
--without-shadow \
--without-vpopmail
CONFIGURE_ENV= CFLAGS="${CFLAGS} -I${LOCALBASE}/include" \
LDFLAGS="-L${LOCALBASE}/lib"
.if !${FLAVOR:L:Mno_sieve}
MULTI_PACKAGES+= -sieve
SIEVE_DIR= ${WRKDIR}/dovecot-sieve-${V_SIEVE}
AUTOCONF_DIR+= ${SIEVE_DIR}
RUN_DEPENDS-sieve= ::${BUILD_PKGPATH}
LIB_DEPENDS-sieve= ${MODLIBICONV_LIB_DEPENDS}
.endif
2005-10-06 13:03:21 -04:00
.if ${FLAVOR:L:Mldap}
CONFIGURE_ARGS+= --with-ldap
LIB_DEPENDS+= lber,ldap::databases/openldap
WANTLIB-server+= sasl2 asn1 com_err gssapi krb5
2005-10-06 13:03:21 -04:00
.endif
.if ${FLAVOR:L:Mmysql}
CONFIGURE_ARGS+= --with-mysql
LIB_DEPENDS+= lib/mysql/mysqlclient.>=10::databases/mysql
WANTLIB-server+= m
.endif
.if ${FLAVOR:L:Mpostgresql}
CONFIGURE_ARGS+= --with-pgsql
LIB_DEPENDS+= pq.>=4::databases/postgresql
.endif
2007-03-22 02:59:13 -04:00
.if ${FLAVOR:L:Msqlite}
CONFIGURE_ARGS+= --with-sqlite
LIB_DEPENDS+= sqlite3::databases/sqlite3
.endif
.if !${FLAVOR:L:Mno_sieve}
post-configure:
(cd ${WRKSRC}; ${MAKE_PROGRAM} dovecot-config)
(cd ${SIEVE_DIR}; ${SETENV} ${CONFIGURE_ENV} \
./configure --with-dovecot=${WRKSRC})
.endif
2005-09-04 14:22:30 -04:00
pre-build:
@perl -pi -e s#_PREFIX_#\${PREFIX}#g ${WRKSRC}/dovecot-example.conf
.if !${FLAVOR:L:Mno_sieve}
post-build:
(cd ${SIEVE_DIR}; ${MAKE_PROGRAM} ${MAKE_FLAGS})
.endif
post-install:
${INSTALL_DATA_DIR} ${PREFIX}/share/examples/dovecot
${INSTALL_DATA} ${WRKSRC}/doc/dovecot-openssl.cnf \
2007-03-24 03:29:01 -04:00
${WRKSRC}/doc/dovecot-sql-example.conf \
${WRKSRC}/doc/dovecot-ldap-example.conf \
2005-09-04 14:22:30 -04:00
${WRKSRC}/dovecot-example.conf \
2005-07-23 16:38:17 -04:00
${PREFIX}/share/examples/dovecot
${INSTALL_SCRIPT} ${WRKSRC}/doc/mkcert.sh \
${PREFIX}/sbin/dovecot-mkcert.sh
.if !${FLAVOR:L:Mno_sieve}
${INSTALL_DATA} \
${SIEVE_DIR}/src/.libs/lib90_cmusieve_plugin.so \
${PREFIX}/lib/dovecot/lda
.endif
.include <bsd.port.mk>