diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
commit | 4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch) | |
tree | ba5f07bf3f9d22d82e54a462313f5d244036c768 /net-mail/postfix-logwatch |
reinit the tree, so we can have metadata
Diffstat (limited to 'net-mail/postfix-logwatch')
7 files changed, 221 insertions, 0 deletions
diff --git a/net-mail/postfix-logwatch/Manifest b/net-mail/postfix-logwatch/Manifest new file mode 100644 index 000000000000..f672357c5ec6 --- /dev/null +++ b/net-mail/postfix-logwatch/Manifest @@ -0,0 +1,9 @@ +AUX multi-digit-enhanced-status.patch 1479 SHA256 89c7b86632ccff9f1cb2720a58510092f81a881865b775d0a4b402ee418ec78a SHA512 6f732591637c5a076532b210a0b9378904609e7927ed5549c1b3e976e45a38e080ed0a754b230d04f4fd0b1904ddc75acd4c420032e23bd663276398cb35a5c7 WHIRLPOOL aa3343631322117d718b9b2332d9b2605c74a2fa44d859f119037939c23997546a3022016e7a292e3b6cf6a76c12d76b46634c62e8b46d9bbd6c5a3c51347ddc +AUX redundant-argument-to-sprintf.patch 1744 SHA256 a3e500da7b5379f3c0600904b2092e7a6b3a9a8270d1137ebc0f0c07211a4103 SHA512 31e35603cee7c51ffe126ba0caeadbbca564694439101d92293d2163d3b674be552ac3e781d4b10fab11435d072bf3bb540e3070bd3a839dd6297fff02cf5b04 WHIRLPOOL 408129f782a7fd6a40f72061f4953726c48e87b5b3fdbb3b2e58e5f488a17e584ca411786591cbdc7d0f7e2745e8b5005b420a62b5c1811c92a0268d8c5f597d +AUX unescaped-left-brace.patch 1277 SHA256 cf57345d6dec8bf8d45020af79d4c15bb95d4c3d98b2495bea39df561439eb15 SHA512 dcfdb1fc7793fcf8a1e41fd890023c901bccff5c241601f99a5aef398fe35c1eae82d786064e189ef2113aad9d2081a67d8451d9c58ceefc78192e22ac5d3033 WHIRLPOOL fde7e75c52ca4afc97bc7d8183c5161badf379f71ae543f5660cf566f7a42a780153457d18ce18492eb8aa9f524ac06e7f28539ec5e155649151b12127d4793b +DIST postfix-logwatch-1.40.03.tgz 107065 SHA256 c9aae87471554bb93c9d91bd2df3999ce3fae19f75ffd43fdee3f8552232c748 SHA512 7059f409cabb3cb638885342ab876e1c85c87530c3544bf04c54a56707695acdc5cbb706e3f192ef5608c9a00706e4d7be3cc7b32286460719d7b497e44b3341 WHIRLPOOL 3c8e556863a79ec55af5e1a19204ddbc2fb3ac60c1a8162239f465da2cda465983f705755be7750e58e0a196c680b1e880f5c6aed0157baf275f6443535104a4 +EBUILD postfix-logwatch-1.40.03-r2.ebuild 1071 SHA256 e26f7d9d889364847fceec4712ffa74aff48319aa9a446500d0ab41c7cb5c46f SHA512 4fe1e57565820139e3228d3b3a10400d0ae68bfd89aa3a066bf2e83247244a2fd704c8c7ed7c2140659dabe8e2a3887c02fddbd40b6763e599d4594f24d40456 WHIRLPOOL dc557e7a7fe266617e7b1ad950c8411b7a893463633c5470690e16b1d1c46edb0d64d9c4ad29faea46f1f119b748f37b4c757121ec7216ad6305954094fcae5e +EBUILD postfix-logwatch-1.40.03.ebuild 905 SHA256 d27fe92c7a60846aa5a796c2e22ed7cd1684699b853ff0e2d40c011dae12ec03 SHA512 ab5358dacd8bcbf723d2c8a310f67b2a351bf814a018f3a258d6ae68ca244aca34b214194d53678caa5cd5ba99e24a0c74a2fe068078659a955694c02adbca30 WHIRLPOOL 05afddb1f12be1e8a2a6e93a75692e1e7d6796afe560e434f75c04e31dd467e380d4dc55c3ac40bd1b4e06b0241987ed92a95dfdae1c9a1ed9defa8f7db89976 +MISC ChangeLog 2439 SHA256 23a257bb21b554b1099d717e06e9c6e22c92b564e921edafcf3297e53c361f66 SHA512 a78e1a9c4d3d70f6d2fcbff2201d0d348441f1ad1ce3d690cefcc82286f0571afda1676efb3c97a7f8cb34dee12f8f1f5dd86f0361562fede4b2750d6ad3e26f WHIRLPOOL 5967139fac80d2013a40056206dca62a5606f88a6b8cf2bf6580b438aa1ca57ecbf49e3ede57088cfcdfbd2a230263f16b6aa39e2509705c8365427f3524fbbf +MISC ChangeLog-2015 1150 SHA256 0ea7b481e33e04aa79b6033fe7b2197661fc5599c5fa0c9df9382e98d536c3d6 SHA512 6d84cd9cba19e811f48b254cddd65d3fb43064f644ed179e95588c73b287520b78c272d43db1297b53dff6fda222ed6f5e45166acdede705b63aabe0530e30cd WHIRLPOOL 8eeffdfb7b8bae200f8ac33bd6b25339cc8b9d1bc4fe997c5fcb926af4b3aab3ecd0a2acdfd2c316a21d8e513f01dab3dce0f2f1a9bb0535ebe7abc25d88d523 +MISC metadata.xml 304 SHA256 b182e57c2917b40d2337cc57fe76f04e36af8c24004a80c61c3eea94f9b5477f SHA512 6df4937b334df95e1178cd70c594d9ef08e52f5b34f4da0a129cd3586192dabe974623b13b6992021231150e8a70b7c2d68e7b65faea39113efe04f9a2244cb1 WHIRLPOOL b774e93c9c2e496b4d859e2149b688d68785cb18bde4a6f17dc10dc1e09c199b0d3c775441b863936ce726a392adc7d6f69eeb2a45fd33ea7967984165cfb272 diff --git a/net-mail/postfix-logwatch/files/multi-digit-enhanced-status.patch b/net-mail/postfix-logwatch/files/multi-digit-enhanced-status.patch new file mode 100644 index 000000000000..f07ab22813c9 --- /dev/null +++ b/net-mail/postfix-logwatch/files/multi-digit-enhanced-status.patch @@ -0,0 +1,38 @@ +From ced6e6fcbf1a025419e8ee9f940e5022ed440532 Mon Sep 17 00:00:00 2001 +From: Michael Orlitzky <michael@orlitzky.com> +Date: Tue, 5 Sep 2017 09:19:44 -0400 +Subject: [PATCH 1/1] Allow multi-digit numbers in enhanced SMTP status codes. + +The re_DSN regular expression is intended to match a response like +"550 1.2.3", where "1.2.3" is an enhanced status code. However, the +regular expression was only expecting single-digit numbers between the +dots; thus it was missing codes like "550 5.7.23". The expression has +been updated to accept any number of digits between the dots. + +This fixes unmatched rejection lines that begin with, + + 550 5.7.23 <user@example.com>: Recipient address rejected... + +Such lines appear with newer versions of the python SPF policy daemon. +--- + postfix-logwatch | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +diff --git a/postfix-logwatch b/postfix-logwatch +index 92ed621..827dfe0 100644 +--- a/postfix-logwatch ++++ b/postfix-logwatch +@@ -66,7 +66,9 @@ my $re_QID_s = qr/[A-Z\d]+/; + my $re_QID_l = qr/(?:NOQUEUE|[bcdfghjklmnpqrstvwxyzBCDFGHJKLMNPQRSTVWXYZ\d]+)/; + our $re_QID; + +-our $re_DSN = qr/(?:(?:\d{3})?(?: ?\d\.\d\.\d)?)/; ++# The enhanced status codes can contain two-digit (or more) numbers; ++# for example, "550 5.7.23". ++our $re_DSN = qr/(?:(?:\d{3})?(?: ?\d+\.\d+\.\d+)?)/; + our $re_DDD = qr/(?:(?:conn_use=\d+ )?delay=-?[\d.]+(?:, delays=[\d\/.]+)?(?:, dsn=[\d.]+)?)/; + + #MODULE: ../Logreporters/Utils.pm +-- +2.13.0 + diff --git a/net-mail/postfix-logwatch/files/redundant-argument-to-sprintf.patch b/net-mail/postfix-logwatch/files/redundant-argument-to-sprintf.patch new file mode 100644 index 000000000000..ee0e79bd41d9 --- /dev/null +++ b/net-mail/postfix-logwatch/files/redundant-argument-to-sprintf.patch @@ -0,0 +1,48 @@ +From 6afb8e258a5a2a0e7c72c4c25927dde9d1e2ad89 Mon Sep 17 00:00:00 2001 +From: Michael Orlitzky <michael@orlitzky.com> +Date: Thu, 24 Aug 2017 07:34:36 -0400 +Subject: [PATCH 2/2] Fix redundant argument to sprintf warning. + +Perl 5.22 now warns about redundant (i.e. extra) arguments to the +sprintf function. If your format string only has two place-holders but +you pass three place-fillers, you get warned: + + Redundant argument in sprintf at ./postfix-logwatch line 1382... + +The issue there was that the format string passed to sprintf was +constructed dynamically; sometimes it would contain two place-holders, +and sometimes three. Three place-fillers were always passed, so when +only two place-holders were used, the warning would be thrown. This was +fixed by testing whether or not there are two or three place-holders, +and passing the appropriate number of place-fillers. +--- + postfix-logwatch | 13 +++++++++++-- + 1 file changed, 11 insertions(+), 2 deletions(-) + +diff --git a/postfix-logwatch b/postfix-logwatch +index 1e58a95..92ed621 100644 +--- a/postfix-logwatch ++++ b/postfix-logwatch +@@ -1378,8 +1378,17 @@ sub print_summary_report (\@) { + $$divisor == $Totals{$keyname} ? 100.00 : $Totals{$keyname} * 100 / $$divisor; + } + else { +- push @{$lines[$cur_level]}, +- sprintf "$fmt %-23s $extra\n", $total, $desc, commify ($Totals{$keyname}); ++ my $new_line; ++ if ($extra eq '') { ++ $new_line = sprintf("$fmt %-23s \n", $total, $desc); ++ } ++ else { ++ $new_line = sprintf("$fmt %-23s $extra\n", ++ $total, ++ $desc, ++ commify ($Totals{$keyname})); ++ } ++ push @{$lines[$cur_level]}, $new_line + } + } + } +-- +2.13.0 + diff --git a/net-mail/postfix-logwatch/files/unescaped-left-brace.patch b/net-mail/postfix-logwatch/files/unescaped-left-brace.patch new file mode 100644 index 000000000000..65139a3aff14 --- /dev/null +++ b/net-mail/postfix-logwatch/files/unescaped-left-brace.patch @@ -0,0 +1,37 @@ +From 84f9fb47783e63757f27e5990ee606ff01e079a9 Mon Sep 17 00:00:00 2001 +From: Michael Orlitzky <michael@orlitzky.com> +Date: Thu, 24 Aug 2017 07:09:28 -0400 +Subject: [PATCH 1/2] Fix unescaped left brace warning for "Config: {". + +New versions of Perl are starting to complain about unescaped braces +in regular expressions, and supposedly the warning will become a fatal +error in Perl 5.30. This particular warning is, + + Unescaped left brace in regex is deprecated, passed through in regex; + marked by <-- HERE in m/^Config: { <-- HERE / at ./postfix-logwatch + line 1850. + +and it was fixed by going to line 1850 and putting a backslash before +the left brace. + +Bug: https://sourceforge.net/p/logreporters/bugs/4/ +--- + postfix-logwatch | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/postfix-logwatch b/postfix-logwatch +index 3e4a673..1e58a95 100644 +--- a/postfix-logwatch ++++ b/postfix-logwatch +@@ -1847,7 +1847,7 @@ sub postfix_policy_spf($) { + # KeyboardInterrupt + $line =~ /^Read line: "/ or + $line =~ /^Found the end of entry$/ or +- $line =~ /^Config: {/ or ++ $line =~ /^Config: \{/ or + $line =~ /^spfcheck: pyspf result/ or + $line =~ /^Starting$/ or + $line =~ /^Normal exit$/ or +-- +2.13.0 + diff --git a/net-mail/postfix-logwatch/metadata.xml b/net-mail/postfix-logwatch/metadata.xml new file mode 100644 index 000000000000..c2f0518836b4 --- /dev/null +++ b/net-mail/postfix-logwatch/metadata.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="person"> + <email>mjo@gentoo.org</email> + </maintainer> + <upstream> + <remote-id type="sourceforge">logreporters</remote-id> + </upstream> +</pkgmetadata> diff --git a/net-mail/postfix-logwatch/postfix-logwatch-1.40.03-r2.ebuild b/net-mail/postfix-logwatch/postfix-logwatch-1.40.03-r2.ebuild new file mode 100644 index 000000000000..b798aeb3512f --- /dev/null +++ b/net-mail/postfix-logwatch/postfix-logwatch-1.40.03-r2.ebuild @@ -0,0 +1,43 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +DESCRIPTION="A log analyzer for postfix" +HOMEPAGE="http://logreporters.sourceforge.net/" +SRC_URI="mirror://sourceforge/logreporters/${P}.tgz" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~amd64 ~x86" + +RDEPEND="dev-lang/perl" + +PATCHES=( + "${FILESDIR}/unescaped-left-brace.patch" + "${FILESDIR}/redundant-argument-to-sprintf.patch" + "${FILESDIR}/multi-digit-enhanced-status.patch" +) + +src_prepare() { + default + # Replace the default config file location with ours. + local cfg_default='/usr/local/etc/${progname_prefix}-logwatch.conf' + local cfg_gentoo='/etc/${progname_prefix}-logwatch.conf'; + sed -i "s~${cfg_default}~${cfg_gentoo}~" ${PN} \ + || die 'failed to update the default config location' +} + +src_compile() { + # The default make target just outputs instructions. We don't want + # the user to see these, so we avoid the default emake. + : +} + +src_install() { + dodoc Bugs Changes README ${PN}.conf-topn + doman ${PN}.1 + dobin ${PN} + insinto /etc + doins ${PN}.conf +} diff --git a/net-mail/postfix-logwatch/postfix-logwatch-1.40.03.ebuild b/net-mail/postfix-logwatch/postfix-logwatch-1.40.03.ebuild new file mode 100644 index 000000000000..375d2ed98b4b --- /dev/null +++ b/net-mail/postfix-logwatch/postfix-logwatch-1.40.03.ebuild @@ -0,0 +1,36 @@ +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=5 + +DESCRIPTION="A log analyzer for postfix" +HOMEPAGE="http://logreporters.sourceforge.net/" +SRC_URI="mirror://sourceforge/logreporters/${P}.tgz" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="amd64 x86" + +RDEPEND="dev-lang/perl" + +src_prepare() { + # Replace the default config file location with ours. + local cfg_default='/usr/local/etc/${progname_prefix}-logwatch.conf' + local cfg_gentoo='/etc/${progname_prefix}-logwatch.conf'; + sed -i "s~${cfg_default}~${cfg_gentoo}~" ${PN} \ + || die 'failed to update the default config location' +} + +src_compile() { + # The default make target just outputs instructions. We don't want + # the user to see these, so we avoid the default emake. + : +} + +src_install() { + dodoc Bugs Changes README ${PN}.conf-topn + doman ${PN}.1 + dobin ${PN} + insinto /etc + doins ${PN}.conf +} |