2005-05-28 09:56:27 +00:00
|
|
|
# New ports collection makefile for: assp
|
|
|
|
# Date created: 16 May 2005
|
|
|
|
# Whom: J.R. Oldroyd <fbsd@opal.com>
|
|
|
|
#
|
|
|
|
# $FreeBSD$
|
|
|
|
#
|
|
|
|
|
|
|
|
PORTNAME= assp
|
2010-12-12 02:41:17 +00:00
|
|
|
PORTVERSION= 1.8.1.6
|
2011-01-06 16:26:53 +00:00
|
|
|
PORTREVISION= 1
|
2005-05-28 09:56:27 +00:00
|
|
|
CATEGORIES= mail
|
2011-01-06 16:26:53 +00:00
|
|
|
MASTER_SITES= SF
|
|
|
|
MASTER_SITE_SUBDIR=${PORTNAME}/ASSP%20Installation/${PORTNAME:U}%20${PORTVERSION}/
|
2006-12-21 19:14:10 +00:00
|
|
|
DISTNAME= ${PORTNAME:U}_${PORTVERSION}-Install
|
2005-05-28 09:56:27 +00:00
|
|
|
|
2010-09-02 13:51:46 +00:00
|
|
|
MAINTAINER= rnejdl@ringofsaturn.com
|
2005-05-28 09:56:27 +00:00
|
|
|
COMMENT= Anti-Spam SMTP Proxy
|
|
|
|
|
|
|
|
USE_ZIP= yes
|
|
|
|
NO_BUILD= yes
|
|
|
|
USE_PERL5_RUN= yes
|
|
|
|
|
|
|
|
MAN8= assp.8 assplog.8
|
|
|
|
|
2009-05-22 01:43:29 +00:00
|
|
|
ASSP_USER= assp
|
|
|
|
ASSP_GROUP= assp
|
2011-01-06 16:26:53 +00:00
|
|
|
USERS= ${ASSP_USER}
|
|
|
|
GROUPS= ${ASSP_GROUP}
|
2005-05-28 09:56:27 +00:00
|
|
|
ASSP_HOME= /var/db/assp
|
2009-05-22 01:43:29 +00:00
|
|
|
ASSP_LOG= /var/log/assp
|
2005-05-28 09:56:27 +00:00
|
|
|
|
2009-05-22 01:43:29 +00:00
|
|
|
PLIST_SUB= ASSP_HOME="${ASSP_HOME}" ASSP_LOG="${ASSP_LOG}"
|
2005-05-28 09:56:27 +00:00
|
|
|
|
2011-01-06 16:26:53 +00:00
|
|
|
SUB_FILES= assp.8 assplog.8 assplog.pl periodic-assp pkg-install
|
2009-05-22 01:43:29 +00:00
|
|
|
SUB_LIST= ASSP_USER="${ASSP_USER}" ASSP_GROUP="${ASSP_GROUP}" \
|
|
|
|
ASSP_HOME="${ASSP_HOME}" ASSP_LOG="${ASSP_LOG}" \
|
|
|
|
DATADIR="${DATADIR}" PERL="${PERL}"
|
2005-05-28 09:56:27 +00:00
|
|
|
|
2006-07-18 03:08:23 +00:00
|
|
|
USE_RC_SUBR= ${PORTNAME}
|
|
|
|
RC_SCRIPT= ${PREFIX}/etc/rc.d/${PORTNAME}
|
2005-05-28 09:56:27 +00:00
|
|
|
|
|
|
|
OPTIONS= EMVALID "RFC822 recipient address validator" on \
|
2009-05-22 01:43:29 +00:00
|
|
|
LDAP "LDAP validation of recipient addresses" off \
|
2005-05-28 09:56:27 +00:00
|
|
|
SPF "SPF validation of client IP" on \
|
2006-07-18 03:08:23 +00:00
|
|
|
SRS "Sender Rewriting Scheme" on \
|
2009-05-22 01:43:29 +00:00
|
|
|
SEND "Resending .eml files" on \
|
2006-07-18 03:08:23 +00:00
|
|
|
FBACKW "File Reading Backwards" on \
|
|
|
|
ZLIB "HTTP Header Compression on Admin Interface" on \
|
2005-05-28 09:56:27 +00:00
|
|
|
CLAMAV "ClamAV virus scanner" on \
|
2006-12-21 19:14:10 +00:00
|
|
|
DNSBL "DNS block list checking" on \
|
2008-01-02 22:12:07 +00:00
|
|
|
MYSQL "Use MySQL db to store white/red/delaylists" off \
|
2009-05-22 01:43:29 +00:00
|
|
|
MATCHRE "Match IP ranges and CIDR blocks in lists" on \
|
|
|
|
SENDERB "Country Code checks" on \
|
|
|
|
MIMEMOD "Multiple Attachement detection" on \
|
|
|
|
SSL "SSL secure sockets support" on \
|
|
|
|
IPV6 "IPv6 sockets support" on
|
2005-05-28 09:56:27 +00:00
|
|
|
|
2009-01-31 00:23:12 +00:00
|
|
|
WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION}/${DISTNAME}/${PORTNAME:U}
|
2006-07-18 03:08:23 +00:00
|
|
|
|
2005-05-28 09:56:27 +00:00
|
|
|
.include <bsd.port.pre.mk>
|
|
|
|
|
2010-03-27 06:14:03 +00:00
|
|
|
SUB_LIST+= RC_SCRIPT=${RC_SCRIPT}
|
2006-07-18 03:08:23 +00:00
|
|
|
|
2009-08-08 12:45:24 +00:00
|
|
|
RUN_DEPENDS+= ${SITE_PERL}/${PERL_ARCH}/Net/DNS.pm:${PORTSDIR}/dns/p5-Net-DNS
|
|
|
|
RUN_DEPENDS+= ${SITE_PERL}/LWP/Simple.pm:${PORTSDIR}/www/p5-libwww
|
|
|
|
|
2005-05-28 09:56:27 +00:00
|
|
|
.if !defined(WITHOUT_EMVALID)
|
|
|
|
RUN_DEPENDS+= ${SITE_PERL}/Email/Valid.pm:${PORTSDIR}/mail/p5-Email-Valid
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(WITHOUT_LDAP)
|
|
|
|
RUN_DEPENDS+= ${SITE_PERL}/Net/LDAP.pm:${PORTSDIR}/net/p5-perl-ldap
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(WITHOUT_SPF)
|
2009-05-22 01:43:29 +00:00
|
|
|
RUN_DEPENDS+= ${SITE_PERL}/Mail/SPF.pm:${PORTSDIR}/mail/p5-Mail-SPF
|
2005-05-28 09:56:27 +00:00
|
|
|
.endif
|
|
|
|
|
2006-07-18 03:08:23 +00:00
|
|
|
.if !defined(WITHOUT_SRS)
|
|
|
|
RUN_DEPENDS+= ${SITE_PERL}/Mail/SRS.pm:${PORTSDIR}/mail/p5-Mail-SRS
|
|
|
|
.endif
|
|
|
|
|
2009-05-22 01:43:29 +00:00
|
|
|
.if !defined(WITHOUT_SEND)
|
|
|
|
RUN_DEPENDS+= ${SITE_PERL}/Email/Send.pm:${PORTSDIR}/mail/p5-Email-Send
|
|
|
|
.endif
|
|
|
|
|
2006-07-18 03:08:23 +00:00
|
|
|
.if !defined(WITHOUT_FBACKW)
|
|
|
|
RUN_DEPENDS+= ${SITE_PERL}/File/ReadBackwards.pm:${PORTSDIR}/devel/p5-File-ReadBackwards
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(WITHOUT_ZLIB)
|
2010-09-21 07:56:43 +00:00
|
|
|
. if ${PERL_LEVEL} < 500903
|
|
|
|
RUN_DEPENDS+= ${SITE_PERL}/Compress/Zlib.pm:${PORTSDIR}/archivers/p5-IO-Compress
|
|
|
|
.endif
|
2005-05-28 09:56:27 +00:00
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(WITHOUT_CLAMAV)
|
2006-12-01 08:10:20 +00:00
|
|
|
RUN_DEPENDS+= ${SITE_PERL}/File/Scan/ClamAV.pm:${PORTSDIR}/security/p5-File-Scan-ClamAV
|
2005-05-28 09:56:27 +00:00
|
|
|
PLIST_SUB+= ASSP_CLAMAV=""
|
|
|
|
.else
|
|
|
|
PLIST_SUB+= ASSP_CLAMAV="@comment "
|
|
|
|
.endif
|
|
|
|
|
2006-07-18 03:08:23 +00:00
|
|
|
.if !defined(WITHOUT_DNSBL)
|
|
|
|
RUN_DEPENDS+= ${SITE_PERL}/${PERL_ARCH}/Net/DNS.pm:${PORTSDIR}/dns/p5-Net-DNS
|
|
|
|
.endif
|
2005-07-13 07:08:15 +00:00
|
|
|
|
2006-12-21 19:14:10 +00:00
|
|
|
.if !defined(WITHOUT_MYSQL)
|
|
|
|
RUN_DEPENDS+= ${SITE_PERL}/Tie/RDBM.pm:${PORTSDIR}/databases/p5-Tie-DBI
|
|
|
|
.endif
|
2005-07-13 07:08:15 +00:00
|
|
|
|
2009-05-22 01:43:29 +00:00
|
|
|
.if !defined(WITHOUT_MATCHRE)
|
|
|
|
RUN_DEPENDS+= ${SITE_PERL}/Net/IP/Match/Regexp.pm:${PORTSDIR}/net-mgmt/p5-Net-IP-Match-Regexp
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(WITHOUT_SENDERB)
|
|
|
|
RUN_DEPENDS+= ${SITE_PERL}/Net/SenderBase.pm:${PORTSDIR}/mail/p5-Net-SenderBase
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(WITHOUT_MIMEMOD)
|
2009-11-24 21:44:44 +00:00
|
|
|
RUN_DEPENDS+= ${SITE_PERL}/Email/MIME/Modifier.pm:${PORTSDIR}/mail/p5-Email-MIME
|
2009-05-22 01:43:29 +00:00
|
|
|
.endif
|
|
|
|
|
2009-01-31 00:23:12 +00:00
|
|
|
.if !defined(WITHOUT_SSL)
|
|
|
|
RUN_DEPENDS+= ${SITE_PERL}/IO/Socket/SSL.pm:${PORTSDIR}/security/p5-IO-Socket-SSL
|
2009-05-22 01:43:29 +00:00
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(WITHOUT_IPV6)
|
2010-08-09 08:54:36 +00:00
|
|
|
RUN_DEPENDS+= ${SITE_PERL}/IO/Socket/INET6.pm:${PORTSDIR}/net/p5-IO-Socket-INET6
|
2009-01-31 00:23:12 +00:00
|
|
|
.endif
|
|
|
|
|
2006-12-21 19:14:10 +00:00
|
|
|
EXTRACT_AFTER_ARGS= -d ${PORTNAME}-${PORTVERSION}
|
2006-12-01 08:10:20 +00:00
|
|
|
|
2005-05-28 09:56:27 +00:00
|
|
|
post-patch:
|
|
|
|
@${REINPLACE_CMD} -e 's|/usr/bin/perl|${PERL}|' ${WRKSRC}/*.pl
|
|
|
|
|
|
|
|
do-install:
|
2009-05-22 01:43:29 +00:00
|
|
|
${MKDIR} ${DATADIR}
|
|
|
|
${INSTALL_SCRIPT} ${WRKSRC}/assp.pl ${DATADIR}
|
|
|
|
${INSTALL_SCRIPT} ${WRKSRC}/rebuildspamdb.pl ${DATADIR}
|
|
|
|
${INSTALL_SCRIPT} ${WRKSRC}/stat.pl ${DATADIR}
|
|
|
|
|
2011-01-06 16:26:53 +00:00
|
|
|
( cd ${WRKSRC} && ${COPYTREE_SHARE} "files images reports" \
|
|
|
|
${DATADIR}/ "! -name '*.orig' ! -name '*.bak'" )
|
2009-05-22 01:43:29 +00:00
|
|
|
|
|
|
|
${INSTALL_SCRIPT} ${WRKDIR}/assplog.pl ${PREFIX}/sbin/assplog
|
2005-05-28 09:56:27 +00:00
|
|
|
|
|
|
|
${INSTALL_MAN} ${WRKDIR}/assp.8 ${MAN8PREFIX}/man/man8
|
|
|
|
${INSTALL_MAN} ${WRKDIR}/assplog.8 ${MAN8PREFIX}/man/man8
|
|
|
|
|
|
|
|
${MKDIR} ${PREFIX}/etc/periodic/daily
|
2010-12-12 02:41:17 +00:00
|
|
|
${INSTALL_SCRIPT} ${WRKDIR}/periodic-assp ${PREFIX}/etc/periodic/daily/510.assp
|
2005-05-28 09:56:27 +00:00
|
|
|
|
|
|
|
.if !defined(NOPORTDOCS)
|
|
|
|
${MKDIR} ${DOCSDIR}
|
2007-10-12 00:32:21 +00:00
|
|
|
${INSTALL_DATA} ${WRKSRC}/docs/*.htm ${DOCSDIR}
|
2005-05-28 09:56:27 +00:00
|
|
|
.endif
|
|
|
|
|
2011-01-06 16:26:53 +00:00
|
|
|
post-install:
|
|
|
|
@PKG_PREFIX=${PREFIX} ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL
|
|
|
|
# XXX Workaround: for PR ports/152498. Remove if PR ports/152498 is fixed!
|
|
|
|
@${EGREP} -e '^@exec.*${PW}' -e '^@exec ${INSTALL} -d -g' ${TMPPLIST} > ${WRKDIR}/.PLIST.ugid
|
|
|
|
@${EGREP} -v -e '^@exec.*${PW}' -e '^@exec ${INSTALL} -d -g' ${TMPPLIST} >> ${WRKDIR}/.PLIST.ugid
|
|
|
|
@${MV} ${WRKDIR}/.PLIST.ugid ${TMPPLIST}
|
|
|
|
|
2005-05-28 09:56:27 +00:00
|
|
|
.include <bsd.port.post.mk>
|