Gentoo Archives: gentoo-commits

From: Dirkjan Ochtman <djc@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: mail-filter/rmilter/files/, mail-filter/rmilter/
Date: Tue, 03 Jan 2017 19:01:03
Message-Id: 1483470051.918473fa31099a4d596ad4ff50b52417b15169fe.djc@gentoo
1 commit: 918473fa31099a4d596ad4ff50b52417b15169fe
2 Author: Dirkjan Ochtman <djc <AT> gentoo <DOT> org>
3 AuthorDate: Tue Jan 3 19:00:39 2017 +0000
4 Commit: Dirkjan Ochtman <djc <AT> gentoo <DOT> org>
5 CommitDate: Tue Jan 3 19:00:51 2017 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=918473fa
7
8 mail-filter/rmilter: use checkpath in init script (fixes bug 603336)
9
10 Package-Manager: portage-2.3.0
11
12 mail-filter/rmilter/files/rmilter.initd-r1 | 25 +++++++++++++++
13 mail-filter/rmilter/rmilter-1.10.0-r1.ebuild | 46 ++++++++++++++++++++++++++++
14 2 files changed, 71 insertions(+)
15
16 diff --git a/mail-filter/rmilter/files/rmilter.initd-r1 b/mail-filter/rmilter/files/rmilter.initd-r1
17 new file mode 100644
18 index 00000000..03eaa25
19 --- /dev/null
20 +++ b/mail-filter/rmilter/files/rmilter.initd-r1
21 @@ -0,0 +1,25 @@
22 +#!/sbin/openrc-run
23 +# Copyright 2015-2017 Gentoo Foundation
24 +# Distributed under the terms of the GNU General Public License v2
25 +
26 +RUNDIR=/var/run/rmilter
27 +PIDFILE=$RUNDIR/rmilter.pid
28 +
29 +depend() {
30 + need net
31 +}
32 +
33 +start() {
34 + ebegin "Starting ${SVCNAME}"
35 + checkpath -d $RUNDIR -m2750 -o rmilter:rmilter
36 + rm -f $RUNDIR/$SVCNAME.sock
37 + start-stop-daemon --start --quiet --pidfile $PIDFILE -u rmilter \
38 + --exec /usr/sbin/rmilter -- -c /etc/rmilter/rmilter.conf
39 + eend $?
40 +}
41 +
42 +stop() {
43 + ebegin "Stopping ${SVCNAME}"
44 + start-stop-daemon --stop --quiet --pidfile $PIDFILE
45 + eend $?
46 +}
47
48 diff --git a/mail-filter/rmilter/rmilter-1.10.0-r1.ebuild b/mail-filter/rmilter/rmilter-1.10.0-r1.ebuild
49 new file mode 100644
50 index 00000000..7147ccf
51 --- /dev/null
52 +++ b/mail-filter/rmilter/rmilter-1.10.0-r1.ebuild
53 @@ -0,0 +1,46 @@
54 +# Copyright 1999-2017 Gentoo Foundation
55 +# Distributed under the terms of the GNU General Public License v2
56 +# $Id$
57 +
58 +EAPI=5
59 +
60 +inherit cmake-utils user
61 +
62 +DESCRIPTION="Another sendmail milter for different mail checks"
63 +SRC_URI="https://github.com/vstakhov/rmilter/archive/${PV}.tar.gz -> ${P}.tar.gz"
64 +HOMEPAGE="https://github.com/vstakhov/rmilter"
65 +
66 +LICENSE="BSD"
67 +SLOT="0"
68 +KEYWORDS="~amd64 ~x86"
69 +IUSE="dkim libressl +memcached"
70 +
71 +RDEPEND="dev-libs/libpcre
72 + !libressl? ( dev-libs/openssl:0= )
73 + libressl? ( dev-libs/libressl:0= )
74 + mail-filter/libmilter
75 + >=dev-libs/glib-2.28
76 + dkim? ( mail-filter/opendkim )
77 + memcached? ( dev-libs/libmemcached )"
78 +DEPEND="${RDEPEND}"
79 +
80 +pkg_setup() {
81 + enewgroup rmilter
82 + enewuser rmilter -1 -1 /var/run/rmilter rmilter
83 +}
84 +
85 +src_configure() {
86 + local mycmakeargs=(
87 + -DENABLE_DKIM=$(usex dkim ON OFF)
88 + -DENABLE_MEMCACHED=$(usex memcached ON OFF)
89 + )
90 + cmake-utils_src_configure
91 +}
92 +
93 +src_install() {
94 + cmake-utils_src_install
95 + newinitd "${FILESDIR}/rmilter.initd-r1" rmilter
96 + insinto /etc/rmilter
97 + newins rmilter.conf.sample rmilter.conf.sample
98 + newins rmilter-grey.conf rmilter-grey.conf
99 +}