diff options
Diffstat (limited to 'net-mail/qmailanalog')
-rw-r--r-- | net-mail/qmailanalog/Manifest | 7 | ||||
-rw-r--r-- | net-mail/qmailanalog/files/0.70-errno.patch | 11 | ||||
-rw-r--r-- | net-mail/qmailanalog/files/tai64nfrac.c | 66 | ||||
-rw-r--r-- | net-mail/qmailanalog/metadata.xml | 12 | ||||
-rw-r--r-- | net-mail/qmailanalog/qmailanalog-0.70-r1.ebuild | 46 |
5 files changed, 142 insertions, 0 deletions
diff --git a/net-mail/qmailanalog/Manifest b/net-mail/qmailanalog/Manifest new file mode 100644 index 000000000000..0ca183790032 --- /dev/null +++ b/net-mail/qmailanalog/Manifest @@ -0,0 +1,7 @@ +AUX 0.70-errno.patch 243 SHA256 924e0154181011e67dde22da580af340d7feb9aacc8fa350112eab00a7514c54 SHA512 1d4c1abde8eb0b4d6dd2254be29b685c922265ededa02a19010bc487e2e2013ef2df9a86a5dd797e0d7a30567cc18ae72324f2a67558633aae76262b2a9681a1 WHIRLPOOL 4816f339c317b6a3283498462ced0353bc5db7d57bacd3c421b1179f988172472f9839a1f918b482f19603df18e082da13eb1d815a6699fd57b97b2336bb0bb4 +AUX tai64nfrac.c 1461 SHA256 0621bf277f6ee021211141126b3641c9301f6dbf8e15a87f1b02b222a62d1e75 SHA512 0febee72c3a0328f651134105e6c9c7db1f2822458fa873694cad9807847a9a1bfb7d91a3f7a7ecbb99564515d001e10f2829f70b9a8e768d26764c0ab408be4 WHIRLPOOL efe3b2b04d21d858880f0e2f49c88006b8bf1519f35f3260f320d51f7e83c25344acedec2d08be874656b7a8b606d7da4f550152e0c0778d1c37f62ee2560607 +DIST qmailanalog-0.70.tar.gz 28416 SHA256 3b76f4c35c980ce8d09def568657fb1402a66c8bea9b56d204c5d3df3798a55b SHA512 0a4991a9ac13b64494b15a6ad42df1bee273a7a3c5ead923450d5516d747989e80e3a0f88e29203dce24dc833cc3bb46d5935633f67bed547f27ac22ad866f3d WHIRLPOOL 727910467b37de38fbed0ed45cb3fd2c9b6e0b26d2671facc626f560764d1d4eb752c7ad4454d92df91558b5c4f55a1a75fe361b4840679519b91cca98f691c6 +EBUILD qmailanalog-0.70-r1.ebuild 1269 SHA256 209319a6793c900a85d99210c5ff06e7f3db6b5c8c0ecb34eca7830e3649c454 SHA512 d2d6ca9421b204a32072474a536314865e82b2d1776b8c927ae282ae26a761da722a03a12813ac87e8267ecdbae5873064b43bc5aa577910a521f2e02f433d1e WHIRLPOOL 68578402f78fe1100cf7c4b0e6f01ff9b31cd861a1c2e616e57189516bcbc06044860236dce86273f563f949e17b2021a3e733a60ac03d5771d809c74915260c +MISC ChangeLog 2489 SHA256 513d0f541579620750f33520ab5f8d6514ce58df9da741a45e20ff190fa6b3c0 SHA512 590538d8e90242bc4cd1a89fba11eaba9dfef4c5745124f82f7fa43c01a05bb580f99126c078661283a1888e3a934bc6a40d993a120a72b99a0b2826378668d6 WHIRLPOOL 1486eac792d62e23b8da3fcfaae282dd34730b571c75f80fd745cdfcb3e76485c6945a4eaf46a48ad80dcbac7e3ce8f9af59e1b24e425b084e61769cd2d3e63c +MISC ChangeLog-2015 1733 SHA256 c1eb7ea8719905ddbe7b9eade20efd174d083060630c75817e0dc1d8604dc17a SHA512 771ef1a273a1e06f453260637b6958762a1d7061eddd02618569b2a61752baeb8177523c47c8bc4158b2cd8d423a4bbe602cc7374fb9886780759624b4b2f264 WHIRLPOOL eefd85dbe66d0784d40fc683e51e993b76463b2ea78a6bea95deb05d8f1a4a0679b385ab413d815c3aa30b1d369dc114b4b37073fb2acb22421d40e9dcb8cee0 +MISC metadata.xml 387 SHA256 78297e62b5cfb99e13992f7a6c7d2cb18d5533439e2c5c9d5fa08e25cbc8ec37 SHA512 be8f5c847c3229d17400cad4230398bc68046166e080ad1998c9c659a6dfb68a4ddb6d39d059c38ec0c11702c8c786b8c49a7a42147fe51bd53fbdfc52624c25 WHIRLPOOL 54058bcedea46b89b0cde9877b236be14f295ab7e729113a31ae56e8bb89b9509d0fc34f92512c7827f99cd8577dfe748582bbf72d7518632ec2e74162420909 diff --git a/net-mail/qmailanalog/files/0.70-errno.patch b/net-mail/qmailanalog/files/0.70-errno.patch new file mode 100644 index 000000000000..4aca1b2b4e58 --- /dev/null +++ b/net-mail/qmailanalog/files/0.70-errno.patch @@ -0,0 +1,11 @@ +--- error.h.orig 2003-03-05 15:42:51.000000000 -0500 ++++ error.h 2003-03-05 15:43:00.000000000 -0500 +@@ -1,7 +1,7 @@ + #ifndef ERROR_H + #define ERROR_H + +-extern int errno; ++#include <errno.h> + + extern int error_intr; + extern int error_nomem; diff --git a/net-mail/qmailanalog/files/tai64nfrac.c b/net-mail/qmailanalog/files/tai64nfrac.c new file mode 100644 index 000000000000..28e6cdbb8754 --- /dev/null +++ b/net-mail/qmailanalog/files/tai64nfrac.c @@ -0,0 +1,66 @@ +/* + Convert external TAI64N timestamps to fractional seconds since epoch. + + Written by Russ Allbery <rra@stanford.edu> + This work is in the public domain. + +Usage: + +tai64nfrac < input > output + +Expects the input stream to be a sequence of lines beginning with @, a +timestamp in external TAI64N format, and a space. Replaces the @ and the +timestamp with fractional seconds since epoch (1970-01-01 00:00:00 UTC). +The input time format is the format written by tai64n and multilog. The +output time format is expected by qmailanalog. */ + +#include <stdio.h> + +/* Read a TAI64N external format timestamp from stdin and write fractional + seconds since epoch (TAI, not UTC) to stdout. Return the character after + the timestamp. */ +int decode(void) +{ + int c; + unsigned long u; + unsigned long seconds = 0; + unsigned long nanoseconds = 0; + + while ((c = getchar()) != EOF) + { + u = c - '0'; + if (u >= 10) + { + u = c - 'a'; + if (u >= 6) break; + u += 10; + } + seconds <<= 4; + seconds += nanoseconds >> 28; + nanoseconds &= 0xfffffff; + nanoseconds <<= 4; + nanoseconds += u; + } + seconds -= 4611686018427387914ULL; + printf("%lu.%lu ", seconds, nanoseconds); + return c; +} + + +int main(void) +{ + int c; + unsigned long seconds; + unsigned long nanoseconds; + + while ((c = getchar()) != EOF) + { + if (c == '@') c = decode(); + while (c != EOF) + { + putchar(c); + if (c == '\n') break; + c = getchar(); + } + } +} diff --git a/net-mail/qmailanalog/metadata.xml b/net-mail/qmailanalog/metadata.xml new file mode 100644 index 000000000000..8f7804014a0e --- /dev/null +++ b/net-mail/qmailanalog/metadata.xml @@ -0,0 +1,12 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="person"> + <email>robbat2@gentoo.org</email> + <name>Robin H. Johnson</name> + </maintainer> +<maintainer type="project"> + <email>net-mail@gentoo.org</email> + <name>Net-Mail</name> + </maintainer> +</pkgmetadata> diff --git a/net-mail/qmailanalog/qmailanalog-0.70-r1.ebuild b/net-mail/qmailanalog/qmailanalog-0.70-r1.ebuild new file mode 100644 index 000000000000..604881b35545 --- /dev/null +++ b/net-mail/qmailanalog/qmailanalog-0.70-r1.ebuild @@ -0,0 +1,46 @@ +# Copyright 1999-2013 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +inherit eutils fixheadtails toolchain-funcs + +DESCRIPTION="collection of tools to help you analyze qmail's activity record" +SRC_URI="http://cr.yp.to/software/${P}.tar.gz" +HOMEPAGE="http://cr.yp.to/qmailanalog.html" + +LICENSE="freedist public-domain" # public-domain for files/tai64nfrac.c +SLOT="0" +KEYWORDS="x86 sparc ~amd64" +IUSE="" + +DEPEND="sys-apps/groff" + +src_unpack() { + unpack ${A} + cd "${S}" + epatch "${FILESDIR}"/${PV}-errno.patch + ht_fix_file auto_home.c.do default.do Makefile +} + +src_compile() { + echo "/var/qmail" > conf-home + echo "$(tc-getCC) ${CFLAGS}" > conf-cc + echo "$(tc-getCC) ${LDFLAGS}" > conf-ld + + emake || die + $(tc-getCC) ${CFLAGS} "${FILESDIR}"/tai64nfrac.c -o tai64nfrac || die +} + +src_test() { :; } + +src_install() { + doman matchup.1 xqp.1 xsender.1 xrecipient.1 columnt.1 + dodoc MATCHUP ACCOUNTING BLURB + + insopts -o root -g qmail -m 755 + insinto /var/qmail/bin + into /var/qmail + dobin columnt ddist deferrals failures matchup recipients rhosts + dobin rxdelay senders successes suids xqp xrecipient xsender + dobin zddist zdeferrals zfailures zoverall zrecipients zrhosts + dobin zrxdelay zsenders zsendmail zsuccesses zsuids tai64nfrac +} |