From owner-svn-ports-all@freebsd.org Sat Apr 16 01:55:25 2016 Return-Path: Delivered-To: svn-ports-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id BD745B04A2E; Sat, 16 Apr 2016 01:55:25 +0000 (UTC) (envelope-from adamw@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 98EBE1DA1; Sat, 16 Apr 2016 01:55:25 +0000 (UTC) (envelope-from adamw@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u3G1tOle074928; Sat, 16 Apr 2016 01:55:24 GMT (envelope-from adamw@FreeBSD.org) Received: (from adamw@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u3G1tO3U074926; Sat, 16 Apr 2016 01:55:24 GMT (envelope-from adamw@FreeBSD.org) Message-Id: <201604160155.u3G1tO3U074926@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: adamw set sender to adamw@FreeBSD.org using -f From: Adam Weinberger Date: Sat, 16 Apr 2016 01:55:24 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r413411 - in head/mail: . opensmtpd-extras-filter-spamassassin X-SVN-Group: ports-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-all@freebsd.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: SVN commit messages for the ports tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 16 Apr 2016 01:55:25 -0000 Author: adamw Date: Sat Apr 16 01:55:24 2016 New Revision: 413411 URL: https://svnweb.freebsd.org/changeset/ports/413411 Log: Add mail/opensmtpd-extras-filter-spamassassin, a filter that pipes messages to the spamassassin daemon. There's no registered dependency on SA, because it should theoretically work for rspamd as well (haven't tested this yet). Added: head/mail/opensmtpd-extras-filter-spamassassin/ head/mail/opensmtpd-extras-filter-spamassassin/Makefile - copied, changed from r413409, head/mail/opensmtpd-extras/Makefile Modified: head/mail/Makefile Modified: head/mail/Makefile ============================================================================== --- head/mail/Makefile Sat Apr 16 01:54:15 2016 (r413410) +++ head/mail/Makefile Sat Apr 16 01:55:24 2016 (r413411) @@ -293,6 +293,7 @@ SUBDIR += opensmtpd SUBDIR += opensmtpd-devel SUBDIR += opensmtpd-extras + SUBDIR += opensmtpd-extras-filter-spamassassin SUBDIR += opensmtpd-extras-table-mysql SUBDIR += opensmtpd-extras-table-passwd SUBDIR += opensmtpd-extras-table-postgresql Copied and modified: head/mail/opensmtpd-extras-filter-spamassassin/Makefile (from r413409, head/mail/opensmtpd-extras/Makefile) ============================================================================== --- head/mail/opensmtpd-extras/Makefile Sat Apr 16 01:37:52 2016 (r413409, copy source) +++ head/mail/opensmtpd-extras-filter-spamassassin/Makefile Sat Apr 16 01:55:24 2016 (r413411) @@ -1,70 +1,28 @@ -# Created by: gahr +# Created by: Adam Weinberger # $FreeBSD$ -PORTNAME= opensmtpd-extras -PORTVERSION= 201602042118 -PORTREVISION?= 1 -CATEGORIES+= mail -MASTER_SITES= http://www.opensmtpd.org/archives/ +PKGNAMESUFFIX= -filter-spamassassin -MAINTAINER?= gahr@FreeBSD.org -COMMENT?= Addons for OpenSMTPD +COMMENT= Spamassassin filter addon for OpenSMTPD +MAINTAINER= adamw@FreeBSD.org -LICENSE?= ISCL +PLIST_FILES= libexec/opensmtpd/filter-spamassassin \ + man/man8/filter-spamassassin.8.gz -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= TABLE -OPTIONS_GROUP_TABLE= LDAP MYSQL PASSWD PGSQL PYTHON REDIS SMAP SQLITE -OPTIONS_DEFAULT= LDAP MYSQL PASSWD PGSQL PYTHON REDIS SMAP SQLITE - -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 - -# -# Tables -# - -MYSQL_BUILD_DEPENDS= ${INSTALL_DIR}/table-mysql:mail/opensmtpd-extras-table-mysql -MYSQL_RUN_DEPENDS= ${MYSQL_BUILD_DEPENDS} - -PASSWD_BUILD_DEPENDS= ${INSTALL_DIR}/table-passwd:mail/opensmtpd-extras-table-passwd -PASSWD_RUN_DEPENDS= ${PASSWD_BUILD_DEPENDS} - -PGSQL_BUILD_DEPENDS= ${INSTALL_DIR}/table-postgres:mail/opensmtpd-extras-table-postgresql -PGSQL_RUN_DEPENDS= ${PGSQL_BUILD_DEPENDS} - -PYTHON_BUILD_DEPENDS= ${INSTALL_DIR}/table-python:mail/opensmtpd-extras-table-python -PYTHON_RUN_DEPENDS= ${PYTHON_BUILD_DEPENDS} - -REDIS_BUILD_DEPENDS= ${INSTALL_DIR}/table-redis:mail/opensmtpd-extras-table-redis -REDIS_RUN_DEPENDS= ${REDIS_BUILD_DEPENDS} - -SMAP_BUILD_DEPENDS= ${INSTALL_DIR}/table-socketmap:mail/opensmtpd-extras-table-socketmap -SMAP_RUN_DEPENDS= ${SMAP_BUILD_DEPENDS} - -SQLITE_BUILD_DEPENDS= ${INSTALL_DIR}/table-sqlite:mail/opensmtpd-extras-table-sqlite -SQLITE_RUN_DEPENDS= ${SQLITE_BUILD_DEPENDS} -.else - -# Only install this for the opensmtpd-extras master port -post-install: - @${RM} ${STAGEDIR}${MAN3PREFIX}/man/man3/filter_api.3 - -.endif - -.include +CONFIGURE_ARGS+= --with-filter-spamassassin + +MASTERDIR= ${.CURDIR}/../opensmtpd-extras +SLAVE_PORT= yes + +# These have to be set at compile-time. These are the +# defaults for spamassassin. +FILTER_SPAMASSASSIN_HOST?= 127.0.0.1 +FILTER_SPAMASSASSIN_PORT?= 783 + +post-patch: + @${REINPLACE_CMD} \ + -e '/^#define SPAMASSASSIN_HOST/s/127.0.0.1/${FILTER_SPAMASSASSIN_HOST}/' \ + -e '/^#define SPAMASSASSIN_PORT/s/783/${FILTER_SPAMASSASSIN_PORT}/' \ + ${WRKSRC}/extras/wip/filters/filter-spamassassin/filter_spamassassin.c + +.include "${MASTERDIR}/Makefile"