aboutsummaryrefslogtreecommitdiffstats
path: root/mail/opensmtpd-extras/Makefile
blob: 27f3aada29f1aa6e3197d16c92556835e021313b (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
# Created by: gahr
# $FreeBSD$

PORTNAME=   opensmtpd-extras
PORTVERSION=    201602042118
PORTREVISION?=  3
CATEGORIES+=    mail
MASTER_SITES=   http://www.opensmtpd.org/archives/

MAINTAINER?=    gahr@FreeBSD.org
COMMENT?=   Addons for OpenSMTPD

LICENSE?=   ISCL

LIB_DEPENDS+=   libevent.so:devel/libevent2
RUN_DEPENDS+=   ${LOCALBASE}/sbin/smtpctl:mail/opensmtpd

USES+=      autoreconf libtool pkgconfig
USE_OPENSSL=    yes
WITH_OPENSSL_PORT=  yes
GNU_CONFIGURE=  yes

.if empty(SLAVE_PORT)
OPTIONS_GROUP=      FILTER TABLE
OPTIONS_GROUP_FILTER=   DNSBL PAUSE REGEX SPAMASSASSIN
OPTIONS_GROUP_TABLE=    LDAP MYSQL PASSWD PGSQL PYTHON REDIS SMAP SQLITE
OPTIONS_DEFAULT=    ${OPTIONS_GROUP_FILTER} ${OPTIONS_GROUP_TABLE}

# Filters
DNSBL_DESC=     Check messages against DNSBLs
PAUSE_DESC=     Pause incoming messages to reduce spam
SPAMASSASSIN_DESC=  Check messages with SpamAssassin
# Tables
PASSWD_DESC=        passwd(5) table support
SMAP_DESC=      Socketmap protocol support

OPTIONS_SUB=    yes

PLIST_FILES=    man/man3/filter_api.3.gz
INSTALL_DIR=    ${LOCALBASE}/libexec/opensmtpd

NO_ARCH=    yes

#
# Filters
#
DNSBL_RUN_DEPENDS=      ${INSTALL_DIR}/filter-dnsbl:mail/opensmtpd-extras-filter-dnsbl
PAUSE_RUN_DEPENDS=      ${INSTALL_DIR}/filter-pause:mail/opensmtpd-extras-filter-pause
REGEX_RUN_DEPENDS=      ${INSTALL_DIR}/filter-regex:mail/opensmtpd-extras-filter-regex
SPAMASSASSIN_RUN_DEPENDS=   ${INSTALL_DIR}/filter-spamassassin:mail/opensmtpd-extras-filter-spamassassin

#
# Tables
#
MYSQL_RUN_DEPENDS=  ${INSTALL_DIR}/table-mysql:mail/opensmtpd-extras-table-mysql
PASSWD_RUN_DEPENDS= ${INSTALL_DIR}/table-passwd:mail/opensmtpd-extras-table-passwd
PGSQL_RUN_DEPENDS=  ${INSTALL_DIR}/table-postgres:mail/opensmtpd-extras-table-postgresql
PYTHON_RUN_DEPENDS= ${INSTALL_DIR}/table-python:mail/opensmtpd-extras-table-python
REDIS_RUN_DEPENDS=  ${INSTALL_DIR}/table-redis:mail/opensmtpd-extras-table-redis
SMAP_RUN_DEPENDS=   ${INSTALL_DIR}/table-socketmap:mail/opensmtpd-extras-table-socketmap
SQLITE_RUN_DEPENDS= ${INSTALL_DIR}/table-sqlite:mail/opensmtpd-extras-table-sqlite
.else

# Only install this for the opensmtpd-extras master port
pre-patch:
    @${REINPLACE_CMD} -e '/man_MANS.*filter_api.3/s/^/#/' \
        ${WRKSRC}/extras/wip/filters/Makefile.am

.endif

.include <bsd.port.mk>