2001-01-07 07:38:32 +00:00
|
|
|
# New ports collection makefile for: amavis
|
|
|
|
# Date Created: 13 Nov 2000
|
|
|
|
# Whom: Roman Shterenzon <roman@xpert.com>
|
|
|
|
#
|
|
|
|
# $FreeBSD$
|
|
|
|
#
|
|
|
|
|
|
|
|
PORTNAME= amavis-perl
|
2001-10-21 18:47:20 +00:00
|
|
|
PORTVERSION= 11
|
2001-01-16 17:33:20 +00:00
|
|
|
CATEGORIES= security
|
2001-01-07 07:38:32 +00:00
|
|
|
MASTER_SITES= http://www.amavis.org/dist/perl/
|
|
|
|
|
2001-10-21 18:47:20 +00:00
|
|
|
MAINTAINER= svenasse@polaris.ca
|
2001-01-07 07:38:32 +00:00
|
|
|
|
|
|
|
BUILD_DEPENDS= ${LOCALBASE}/bin/uvscan:${PORTSDIR}/security/vscan \
|
|
|
|
${LOCALBASE}/bin/lha:${PORTSDIR}/archivers/lha \
|
|
|
|
${LOCALBASE}/bin/unarj:${PORTSDIR}/archivers/unarj \
|
|
|
|
${LOCALBASE}/bin/unrar:${PORTSDIR}/archivers/unrar \
|
|
|
|
${LOCALBASE}/bin/zoo:${PORTSDIR}/archivers/zoo \
|
|
|
|
${LOCALBASE}/bin/arc:${PORTSDIR}/archivers/arc \
|
|
|
|
${LOCALBASE}/lib/perl5/site_perl/${PERL_VER}/IO/AtomicFile.pm:${PORTSDIR}/devel/p5-IO-stringy \
|
|
|
|
${LOCALBASE}/lib/perl5/site_perl/${PERL_VER}/${PERL_ARCH}/MIME/Base64.pm:${PORTSDIR}/converters/p5-MIME-Base64 \
|
|
|
|
${LOCALBASE}/lib/perl5/site_perl/${PERL_VER}/MIME/Body.pm:${PORTSDIR}/mail/p5-MIME-Tools \
|
|
|
|
${LOCALBASE}/lib/perl5/site_perl/${PERL_VER}/Mail/Address.pm:${PORTSDIR}/mail/p5-Mail-Tools \
|
|
|
|
${LOCALBASE}/lib/perl5/site_perl/${PERL_VER}/${PERL_ARCH}/Compress/Zlib.pm:${PORTSDIR}/archivers/p5-Compress-Zlib \
|
|
|
|
${LOCALBASE}/lib/perl5/site_perl/${PERL_VER}/${PERL_ARCH}/Convert/UUlib.pm:${PORTSDIR}/converters/p5-Convert-UUlib \
|
|
|
|
${LOCALBASE}/lib/perl5/site_perl/${PERL_VER}/Convert/TNEF.pm:${PORTSDIR}/converters/p5-Convert-TNEF \
|
|
|
|
${LOCALBASE}/lib/perl5/site_perl/${PERL_VER}/Archive/Tar.pm:${PORTSDIR}/archivers/p5-Archive-Tar \
|
2001-10-21 18:47:20 +00:00
|
|
|
${LOCALBASE}/lib/perl5/site_perl/${PERL_VER}/${PERL_ARCH}/Unix/Syslog.pm:${PORTSDIR}/sysutils/p5-Unix-Syslog \
|
|
|
|
${LOCALBASE}/lib/perl5/site_perl/${PERL_VER}/Archive/Zip.pm:${PORTSDIR}/archivers/p5-Archive-Zip
|
2001-08-15 20:33:16 +00:00
|
|
|
.if !exists(/usr/bin/bzip2)
|
|
|
|
BUILD_DEPENDS+= bunzip2:${PORTSDIR}/archivers/bzip2
|
|
|
|
.endif
|
2001-01-07 07:38:32 +00:00
|
|
|
RUN_DEPENDS= ${BUILD_DEPENDS}
|
|
|
|
|
|
|
|
GNU_CONFIGURE= yes
|
2001-10-21 18:47:20 +00:00
|
|
|
CONFIGURE_ARGS+= --with-virusdir=/var/spool/quarantine --with-runtime-dir=/var/log/amavis \
|
|
|
|
--with-logdir=/var/log/amavis
|
|
|
|
|
|
|
|
.if defined(WITH_QMAIL)
|
|
|
|
MTA?= qmail
|
|
|
|
DIROWNER?= qmailq:qmail
|
|
|
|
CONFIGURE_ARGS+= --enable-qmail
|
|
|
|
.if exists(${LOCALBASE}/qmail/bin/qmail-send)
|
|
|
|
QMAIL_DIR?= ${LOCALBASE}/qmail
|
|
|
|
.else
|
|
|
|
QMAIL_DIR?= /var/qmail
|
|
|
|
.endif
|
|
|
|
BUILD_DEPENDS+= ${QMAIL_DIR}/bin/qmail-send:${PORTSDIR}/mail/qmail
|
|
|
|
RUN_DEPENDS= ${BUILD_DEPENDS}
|
|
|
|
.endif
|
|
|
|
|
2002-06-17 19:28:21 +00:00
|
|
|
.if defined(MTA)
|
|
|
|
.if ${MTA} == "postfix"
|
|
|
|
DIROWNER?= vscan:daemon
|
|
|
|
CONFIGURE_ARGS+= --enable-postfix --enable-smtp
|
|
|
|
BUILD_DEPENDS+= ${LOCALBASE}/sbin/postfix:${PORTSDIR}/mail/postfix
|
|
|
|
.elif ${MTA} == "exim"
|
|
|
|
DIROWNER?= root:daemon
|
|
|
|
CONFIGURE_ARGS+= --enable-exim
|
|
|
|
BUILD_DEPENDS+= ${LOCALBASE}/sbin/exim:${PORTSDIR}/mail/exim
|
|
|
|
.endif
|
|
|
|
RUN_DEPENDS= ${BUILD_DEPENDS}
|
|
|
|
.else
|
2001-10-21 18:47:20 +00:00
|
|
|
MTA?= sendmail
|
|
|
|
DIROWNER?= root:daemon
|
|
|
|
CONFIGURE_ARGS+= --enable-relay
|
|
|
|
.endif
|
|
|
|
|
|
|
|
PKGDEINSTALL= ${PKGDIR}/pkg-deinstall.${MTA}
|
|
|
|
PKGINSTALL= ${PKGDIR}/pkg-install.${MTA}
|
2002-06-17 19:28:21 +00:00
|
|
|
PKGMESSAGE= ${PKGDIR}/pkg-message.${MTA}
|
2001-01-07 07:38:32 +00:00
|
|
|
|
|
|
|
do-install:
|
2001-10-21 18:47:20 +00:00
|
|
|
@${MKDIR} /var/log/amavis
|
|
|
|
@${MKDIR} /var/spool/quarantine
|
2001-01-07 07:38:32 +00:00
|
|
|
${INSTALL_SCRIPT} ${WRKSRC}/amavis/amavis ${PREFIX}/sbin
|
|
|
|
.if !defined(NOPORTDOCS)
|
2001-10-21 18:47:20 +00:00
|
|
|
@${MKDIR} ${PREFIX}/share/doc/amavis
|
|
|
|
.for i in README README.exim README.qmail README.milter README.postfix README.sendmail README.scanners doc/amavis.txt
|
2001-01-07 07:38:32 +00:00
|
|
|
${INSTALL_DATA} ${WRKSRC}/${i} ${PREFIX}/share/doc/amavis
|
|
|
|
.endfor
|
|
|
|
.endif
|
|
|
|
|
|
|
|
post-install:
|
2002-06-17 19:28:21 +00:00
|
|
|
@PKG_PREFIX=${PREFIX} ${PERL5} ${PKGINSTALL} _ POST-INSTALL
|
2001-10-21 18:47:20 +00:00
|
|
|
@${CHOWN} ${DIROWNER} /var/log/amavis /var/spool/quarantine
|
|
|
|
@${CHMOD} 0755 /var/log/amavis /var/spool/quarantine
|
2002-06-17 19:28:21 +00:00
|
|
|
@${CAT} ${PKGMESSAGE}
|
2001-01-07 07:38:32 +00:00
|
|
|
|
|
|
|
.include <bsd.port.mk>
|