diff options
Diffstat (limited to 'mail-filter')
-rw-r--r-- | mail-filter/gross/ChangeLog | 11 | ||||
-rw-r--r-- | mail-filter/gross/Manifest | 7 | ||||
-rw-r--r-- | mail-filter/gross/files/gross-fix-paths-and-rm-getline.patch | 48 | ||||
-rw-r--r-- | mail-filter/gross/files/grossd.confd | 9 | ||||
-rw-r--r-- | mail-filter/gross/files/grossd.initd | 40 | ||||
-rw-r--r-- | mail-filter/gross/gross-1.0.2.ebuild | 41 | ||||
-rw-r--r-- | mail-filter/gross/metadata.xml | 8 |
7 files changed, 164 insertions, 0 deletions
diff --git a/mail-filter/gross/ChangeLog b/mail-filter/gross/ChangeLog new file mode 100644 index 000000000..11afde8f6 --- /dev/null +++ b/mail-filter/gross/ChangeLog @@ -0,0 +1,11 @@ +# ChangeLog for mail-filter/gross +# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2 +# $Header: $ + + 11 Dec 2009; Marcin Miroslaw <bug@mejor.pl> +gross-1.0.2.ebuild, + +files/gross-fix-paths-and-rm-getline.patch, +files/grossd.confd, + +files/grossd.initd, +metadata.xml: + Initial commit, bug #247568. Many thanks to Stevan Bajic for base init + script,ebuild and information. Thanks to sedzimir and other people from + #gentoo-sunrise. + diff --git a/mail-filter/gross/Manifest b/mail-filter/gross/Manifest new file mode 100644 index 000000000..625a8892d --- /dev/null +++ b/mail-filter/gross/Manifest @@ -0,0 +1,7 @@ +AUX gross-fix-paths-and-rm-getline.patch 1990 RMD160 a4fff73300377bc3753f80f826ee08055726655d SHA1 f14d4cd6553f7b34f12a8a895607adfd8f611492 SHA256 93cced7d8e2cb6a6d54eb4efaff657bd5bf38af348e1ba8fbcfbf2766423a366 +AUX grossd.confd 220 RMD160 5193e5ef5e7286444f548ff87abecf2eab61dedd SHA1 729e59bdc5f261c64ead9a170e4b2793e89684d2 SHA256 d72c00baab66a998773b9684011542fc7119bb4bf0ce07171a8c9d8c784e31ea +AUX grossd.initd 811 RMD160 dffacf67ffd0f4c0057fc48e5cde690ce57aedc0 SHA1 dea75a6bdca831bc96c36fee59c3583c502f5731 SHA256 d640e6ed925eda5ee9f24df4c333ab5fb331c9b99da0921776de7f1352209aa9 +DIST gross-1.0.2.tar.gz 317461 RMD160 3de7411a07439db379c0cb36abdcee5d257a0d10 SHA1 00961feb7b9c8330bb6db2a33b8d5c378c1eaee2 SHA256 8443b9ba46537ed6470bda60109df68d40d3dd11b9f5a07c9180cb01af7147f9 +EBUILD gross-1.0.2.ebuild 1076 RMD160 3e5e6a50ee0b18bd23b4ae2314ad96e587b1fafe SHA1 21bb81416bb6d981ee1515c686ac5b564d189d84 SHA256 8e37e5e4710767e292a3887fc76a884460f14c8565cc7636c2a6fd9b523657a0 +MISC ChangeLog 458 RMD160 a0d0013fedf6b4b346aa165ea4ab99157f161d41 SHA1 64dd4be29ec76d30507577a22684a8227444708f SHA256 08961f066b9ad825ee53a374100219dac8dffcd103d74dc1646a5c0ca3a9ce15 +MISC metadata.xml 252 RMD160 2aea427db7b6a76d7f5a13ee881de091f4512117 SHA1 41baa5aa5b6ed70532f1c8f0d061c32670f4798a SHA256 5995ab258f6027aaaaa3e67bf128127e854252a91abdc87750063b95fc79081b diff --git a/mail-filter/gross/files/gross-fix-paths-and-rm-getline.patch b/mail-filter/gross/files/gross-fix-paths-and-rm-getline.patch new file mode 100644 index 000000000..7953a2250 --- /dev/null +++ b/mail-filter/gross/files/gross-fix-paths-and-rm-getline.patch @@ -0,0 +1,48 @@ +diff -ur gross-1.0.2-orig/doc/examples/grossd.conf gross-1.0.2/doc/examples/grossd.conf +--- gross-1.0.2-orig/doc/examples/grossd.conf 2009-09-20 15:57:57.000000000 +0200 ++++ gross-1.0.2/doc/examples/grossd.conf 2009-12-08 10:59:34.000000000 +0100 +@@ -69,13 +69,8 @@ + # DEFAULT: status_port = 5522 + + # 'statefile' is the full path of the file that the server will use to +-# store the state information. +-# statefile = /var/db/grossd.state +- +-# 'pidfile' is the full path of the file grossd writes its pid into. +-# You can set parameter 'check', if you want to keep grossd +-# from starting if pidfile already exists. +-# pidfile = /var/run/grossd.pid;check ++# store the state information. ++# statefile = /var/db/grossd/grossd.state + + # 'log_method' is used to list all the possible logging facilities. + # currently only syslog is implemented +diff -ur gross-1.0.2-orig/include/utils.h gross-1.0.2/include/utils.h +--- gross-1.0.2-orig/include/utils.h 2009-09-20 15:57:55.000000000 +0200 ++++ gross-1.0.2/include/utils.h 2009-12-08 10:27:04.000000000 +0100 +@@ -39,7 +39,6 @@ + #endif /* ! USE_GETTIMEOFDAY */ + + int readline(int fd, void *vptr, size_t maxlen); +-int getline(int fd, char *line, size_t maxlen); + ssize_t readn(int fd, void *vptr, size_t n); + ssize_t writen(int fd, const void *vptr, size_t n); + ssize_t writeline(int fd, const char *line); +diff -ur gross-1.0.2-orig/man/grossd.conf.5.in gross-1.0.2/man/grossd.conf.5.in +--- gross-1.0.2-orig/man/grossd.conf.5.in 2009-09-20 15:57:57.000000000 +0200 ++++ gross-1.0.2/man/grossd.conf.5.in 2009-12-08 10:27:04.000000000 +0100 +@@ -266,10 +266,10 @@ + .PP + Main section: + .PP +- GROSS_QUERY = sender=$sender_address\e\en\e\e +- recipient=$local_part@$domain\e\en\e\e +- client_address=$sender_host_address\e\en\e\e +- grossd_mode=single\e\en\e\en ++ GROSS_QUERY = sender=$sender_address\\n\\ ++ recipient=$local_part@$domain\\n\\ ++ client_address=$sender_host_address\\n\\ ++ grossd_mode=single\\n\\n + .PP + Acl section: + .PP diff --git a/mail-filter/gross/files/grossd.confd b/mail-filter/gross/files/grossd.confd new file mode 100644 index 000000000..41c63bc54 --- /dev/null +++ b/mail-filter/gross/files/grossd.confd @@ -0,0 +1,9 @@ +# default configuration file +CONF_FILE="/etc/mail/gross/grossd.conf" + +# default pid file +GROSS_PID="/var/run/grossd/grossd.pid" + +# Additional options for the grossd +# see grossd(8) for more information. +# GROSSD_OPTS="" diff --git a/mail-filter/gross/files/grossd.initd b/mail-filter/gross/files/grossd.initd new file mode 100644 index 000000000..73df1d165 --- /dev/null +++ b/mail-filter/gross/files/grossd.initd @@ -0,0 +1,40 @@ +#!/sbin/runscript +# Copyright 1999-2009 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +depend() { + use logger net + before mta +} + +checkconfig() { + if [ ! -r "${CONF_FILE}" ] + then + eerror "You need a gross configuration file in ${CONF_FILE}" + return 1 + fi + /usr/sbin/grossd -C -f "${CONF_FILE}" >/dev/null 2>&1 + return +} + +start() { + checkconfig || return 1 + ebegin "Starting ${SVCNAME}" + start-stop-daemon \ + --start \ + --name grossd \ + --pid "${GROSS_PID}" \ + --exec /usr/sbin/grossd -- -P ${GROSS_PID} -f "${CONF_FILE}" ${GROSSD_OPTS} + eend ${?} "Failed to start ${SVCNAME}" +} + +stop() { + ebegin "Shutting down ${SVCNAME}" + start-stop-daemon \ + --stop \ + --quiet \ + --name grossd \ + --pidfile "${GROSS_PID}" + eend ${?} "Failed to stop ${SVCNAME}" +} diff --git a/mail-filter/gross/gross-1.0.2.ebuild b/mail-filter/gross/gross-1.0.2.ebuild new file mode 100644 index 000000000..22a06fd69 --- /dev/null +++ b/mail-filter/gross/gross-1.0.2.ebuild @@ -0,0 +1,41 @@ +# Copyright 1999-2009 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +EAPI="2" + +inherit eutils + +DESCRIPTION="gross - Greylisting of suspicious sources" +HOMEPAGE="http://code.google.com/p/gross/" +SRC_URI="http://${PN}.googlecode.com/files/${P}.tar.gz" + +LICENSE="as-is" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="ares milter" + +DEPEND="ares? ( net-dns/c-ares ) + milter? ( || ( mail-filter/libmilter mail-mta/sendmail ) )" +RDEPEND="${DEPEND}" + +src_prepare() { + epatch "${FILESDIR}"/${PN}-fix-paths-and-rm-getline.patch +} + +src_configure() { + econf \ + --sysconfdir=/etc/mail/gross \ + $(use_enable milter) \ + $(use_enable ares dnsbl) +} + +src_install() { + emake DESTDIR="${D}" install || die "emake failed" + diropts -o nobody -g nobody + dodir /var/run/grossd || die "dodir failed" + keepdir /var/db/grossd || die "dodir db failed" + dodoc ChangeLog NEWS README doc/examples/* || die "dodoc failed" + newinitd "${FILESDIR}"/grossd.initd grossd || die "newinitd failed" + newconfd "${FILESDIR}"/grossd.confd grossd || die "newconfd failed" +} diff --git a/mail-filter/gross/metadata.xml b/mail-filter/gross/metadata.xml new file mode 100644 index 000000000..3a1611aad --- /dev/null +++ b/mail-filter/gross/metadata.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> +<herd>maintainer-wanted</herd> +<use> + <flag name='ares'>Enables dnsbl checking using c-ares library</flag> +</use> +</pkgmetadata>
\ No newline at end of file |