From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 4AD971382C5 for ; Tue, 26 May 2020 13:40:38 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 37973E0922; Tue, 26 May 2020 13:40:37 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id E9E30E090F for ; Tue, 26 May 2020 13:40:36 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 7735B34EE69 for ; Tue, 26 May 2020 13:40:35 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id DC65926A for ; Tue, 26 May 2020 13:40:32 +0000 (UTC) From: "Michael Orlitzky" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Michael Orlitzky" Message-ID: <1590499877.328a9a69d17949b8bff1f1b854f4a301a759f10f.mjo@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: mail-filter/spf-engine/ X-VCS-Repository: repo/gentoo X-VCS-Files: mail-filter/spf-engine/Manifest mail-filter/spf-engine/spf-engine-2.9.2.ebuild X-VCS-Directories: mail-filter/spf-engine/ X-VCS-Committer: mjo X-VCS-Committer-Name: Michael Orlitzky X-VCS-Revision: 328a9a69d17949b8bff1f1b854f4a301a759f10f X-VCS-Branch: master Date: Tue, 26 May 2020 13:40:32 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: a0bca4fe-035d-4b49-8fef-c79027403ee9 X-Archives-Hash: cb10eb44805a3da73ff0db2dba396423 commit: 328a9a69d17949b8bff1f1b854f4a301a759f10f Author: Michael Orlitzky gentoo org> AuthorDate: Tue May 26 01:28:54 2020 +0000 Commit: Michael Orlitzky gentoo org> CommitDate: Tue May 26 13:31:17 2020 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=328a9a69 mail-filter/spf-engine: new version 2.9.2. The first new version after the rename, with an ebuild that will make sense to future readers. Thanks to Alex Efros for pointing out that this package was renamed and for supplying an updated ebuild. Reported-by: Alex Efros yandex.ru> Closes: https://bugs.gentoo.org/724526 Package-Manager: Portage-2.3.99, Repoman-2.3.22 Signed-off-by: Michael Orlitzky gentoo.org> mail-filter/spf-engine/Manifest | 1 + mail-filter/spf-engine/spf-engine-2.9.2.ebuild | 79 ++++++++++++++++++++++++++ 2 files changed, 80 insertions(+) diff --git a/mail-filter/spf-engine/Manifest b/mail-filter/spf-engine/Manifest index a02a604de1f..e26a6abe523 100644 --- a/mail-filter/spf-engine/Manifest +++ b/mail-filter/spf-engine/Manifest @@ -1 +1,2 @@ DIST pypolicyd-spf-2.0.2.tar.gz 38546 BLAKE2B 691cd5db37592be0ef0cda41223280e764e83802e37563f4e6c08505731118199c03d27b0bf51cec0556aa946fc6c7465fe09d3c9100c8e2582a4d85ad828495 SHA512 adcc7b30c6922894f9407edd0637b02a138623f4480ec37635475396826b457c835b3ffb599d1985e306770fe5f72404552ed705bd957e63b5c54ca3d8991673 +DIST spf-engine-2.9.2.tar.gz 52737 BLAKE2B 39d6c9831ef3ea489f2910fcbcaec9b2bed627f02459e20826166f04a2fe895aecf83768a3446a037e4231cc317ee277f6ff8e9030c72d8819739f6af889d632 SHA512 fe1fe82411ed4d6fcfadccd6ccc9fbd36372b4676051aafa5984740cba862336b00567576b3e32451cd24b0cfcd992d7dfdee33f0cf65a35f4009837e99b8f98 diff --git a/mail-filter/spf-engine/spf-engine-2.9.2.ebuild b/mail-filter/spf-engine/spf-engine-2.9.2.ebuild new file mode 100644 index 00000000000..eebe9b13725 --- /dev/null +++ b/mail-filter/spf-engine/spf-engine-2.9.2.ebuild @@ -0,0 +1,79 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +PYTHON_COMPAT=( python3_6 python3_7 python3_8 ) + +# The built-in ipaddress module handles the parsing of IP addresses. If +# python is built without ipv6 support, then ipaddress can't parse ipv6 +# addresses, and the daemon will crash if it sees an ipv6 SPF record. In +# other words, it's completely broken. +PYTHON_REQ_USE="ipv6" + +# setup.py defines entry_points +DISTUTILS_USE_SETUPTOOLS=rdepend +inherit distutils-r1 + +DESCRIPTION="Policy daemon and milter for Postfix SPF verification" +HOMEPAGE="https://launchpad.net/spf-engine" +SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz" + +LICENSE="Apache-2.0" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="" + +DEPEND="dev-python/pyspf[${PYTHON_USEDEP}]" + +RDEPEND="${DEPEND} + dev-python/authres[${PYTHON_USEDEP}]" + +DOCS=( CHANGES policyd-spf.conf.commented README README.per_user_whitelisting ) + +python_prepare_all() { + # The "real" config file mentions the commented one, so we point + # users in the right direction. + local oldconf="policyd-spf.conf.commented" + local newconf="/usr/share/doc/${PF}/${oldconf}" + + sed -e "1 s~ ${oldconf}~,\n# ${newconf}~" -i policyd-spf.conf \ + || die 'failed to update commented config file path' + + distutils-r1_python_prepare_all +} + +src_install() { + distutils-r1_src_install + + # Remove the milter files that are installed by default. The milter + # isn't quite ready: + # + # * The README says it's experimental not well-tested. + # * There's no documentation for its configuration parameters + # (expecially the UserID). + # * The configuration file is hard-coded to /usr/local. + # * The paths in the systemd service file are hard-coded to /usr/local. + # * We need to write an OpenRC service script for it. + # + # These are all eventually doable, but I'm not willing to commit to + # making the milter work before upstream is. + # + rm "${ED}/usr/bin/pyspf-milter" \ + || die "failed to remove ${ED}/usr/bin/pyspf-milter" + rm -r "${ED}/usr/lib/systemd" \ + || die "failed to remove ${ED}/usr/lib/systemd" + rm -r "${ED}/usr/etc/init.d" \ + || die "failed to remove ${ED}/usr/etc/init.d" + einfo "The milter component of spf-engine is still deemed experimental" + einfo "and not well-tested by upstream. It's missing configuration" + einfo "files, service scripts, and documentation. In other words, it" + einfo "doesn't work yet." + + # The setuptools installation routing always works relative to + # python's prefix, so that when installing locally you wind up + # with paths like /usr/local/etc. However for system installs + # that does the wrong thing and puts the sysconfdir at /usr/etc. + # Here we move it to the right place. + mv -v "${ED}/usr/etc" "${ED}/" || die 'failed to relocate sysconfdir' +}