logo

overlay

My own overlay for experimentations, use with caution, no support is provided git clone https://anongit.hacktivis.me/git/overlay.git/
commit: ee9b6dc8cd5824f7990991d4b2b985d086794126
parent c028b8217ff3c1f3b27c44c9446109945baa9d6d
Author: Haelwenn (lanodan) Monnier <contact@hacktivis.me>
Date:   Sat, 28 Dec 2024 19:02:47 +0100

mail-filter/opensmtpd-filter-rspamd: new package, add 0.1.8

Diffstat:

Amail-filter/opensmtpd-filter-rspamd/Manifest1+
Amail-filter/opensmtpd-filter-rspamd/opensmtpd-filter-rspamd-0.1.8.ebuild55+++++++++++++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 56 insertions(+), 0 deletions(-)

diff --git a/mail-filter/opensmtpd-filter-rspamd/Manifest b/mail-filter/opensmtpd-filter-rspamd/Manifest @@ -0,0 +1 @@ +DIST opensmtpd-filter-rspamd-0.1.8.tar.gz 7449 BLAKE2B 245bb4cbbcdb2b9bf0abde0fc43296cf3fa6e135492d83f8d6d0a5762b7a5f9fa9215d1750e546adc831aaeb0e5f42014609c8079a7cbafe5f31031c30a64aad SHA512 54dc5ec496251e6a223ac05909f4d940c79ce2487e40e30a430da24fcc211983c40355fd91a609e7bb109be49051ca81f092e297f5c8c1e5a3e91a188b948f04 diff --git a/mail-filter/opensmtpd-filter-rspamd/opensmtpd-filter-rspamd-0.1.8.ebuild b/mail-filter/opensmtpd-filter-rspamd/opensmtpd-filter-rspamd-0.1.8.ebuild @@ -0,0 +1,55 @@ +# Copyright 2020-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +EGO_PN="github.com/poolpOrg/filter-rspamd" + +DESCRIPTION="OpenSMTPD filter for putting emails through rspamd" +HOMEPAGE="https://github.com/poolpOrg/filter-rspamd" +SRC_URI="https://github.com/poolpOrg/filter-rspamd/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz" +S="${WORKDIR}/src/${EGO_PN}" + +LICENSE="ISC" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="" + +DEPEND=" + >=dev-lang/go-1.15 + >=dev-go/sys-0.13.0 +" +RDEPEND="${DEPEND} mail-mta/opensmtpd" +BDEPEND="" + +RESTRICT="strip" +QA_FLAGS_IGNORED='.*' + +DOCS=( README.md ) + +src_unpack() { + default + + mkdir -p "$(dirname "${S}")" || die + mv "${WORKDIR}/filter-rspamd-${PV}" "${S}" || die +} + +src_compile() { + # disable module-aware mode + export GO111MODULE=off + # no network access + export GOPROXY=off + # don't try to update the toolchain + export GOTOOLCHAIN="local" + + # With GO111MODULE=off WORKDIR needs to be included + export GOPATH="${WORKDIR}:${EPREFIX}/usr/lib/go-gentoo" + + go build -ldflags="-s -w" -buildmode=pie -o filter-rspamd || die +} + +src_install() { + default + exeinto /usr/libexec/opensmtpd + doexe filter-rspamd +}