1 |
commit: 882586d1c9845709e6cdf7a0f633c409ea0efbca |
2 |
Author: Benda Xu <heroxbd <AT> gentoo <DOT> org> |
3 |
AuthorDate: Tue Aug 2 09:44:59 2016 +0000 |
4 |
Commit: Benda XU <heroxbd <AT> gentoo <DOT> org> |
5 |
CommitDate: Tue Aug 2 09:45:14 2016 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=882586d1 |
7 |
|
8 |
sys-auth/munge: Prefix support. |
9 |
|
10 |
Bug: 590106 |
11 |
|
12 |
Package-Manager: portage-2.3.0 |
13 |
|
14 |
sys-auth/munge/munge-0.5.11.ebuild | 22 ++++++++++++---------- |
15 |
1 file changed, 12 insertions(+), 10 deletions(-) |
16 |
|
17 |
diff --git a/sys-auth/munge/munge-0.5.11.ebuild b/sys-auth/munge/munge-0.5.11.ebuild |
18 |
index 64bc557..5ca4865 100644 |
19 |
--- a/sys-auth/munge/munge-0.5.11.ebuild |
20 |
+++ b/sys-auth/munge/munge-0.5.11.ebuild |
21 |
@@ -1,9 +1,9 @@ |
22 |
-# Copyright 1999-2015 Gentoo Foundation |
23 |
+# Copyright 1999-2016 Gentoo Foundation |
24 |
# Distributed under the terms of the GNU General Public License v2 |
25 |
# $Id$ |
26 |
|
27 |
EAPI=5 |
28 |
-inherit autotools eutils user |
29 |
+inherit autotools eutils user prefix |
30 |
|
31 |
DESCRIPTION="An authentication service for creating and validating credentials" |
32 |
HOMEPAGE="https://github.com/dun/munge" |
33 |
@@ -30,12 +30,14 @@ src_prepare() { |
34 |
# Accepted upstream, https://github.com/dun/munge/pull/40 |
35 |
epatch "${FILESDIR}"/fixed-recursive-use-of-make-in-makefiles.patch |
36 |
|
37 |
+ hprefixify config/x_ac_path_openssl.m4 |
38 |
+ |
39 |
eautoreconf |
40 |
} |
41 |
|
42 |
src_configure() { |
43 |
econf \ |
44 |
- --localstatedir=/var \ |
45 |
+ --localstatedir="${EPREFIX}"/var \ |
46 |
--with-crypto-lib=$(usex gcrypt libgcrypt openssl) |
47 |
} |
48 |
|
49 |
@@ -45,19 +47,19 @@ src_install() { |
50 |
default |
51 |
|
52 |
# 450830 |
53 |
- if [ -d "${D}"/var/run ]; then |
54 |
- rm -rf "${D}"/var/run || die |
55 |
+ if [ -d "${ED}"/var/run ]; then |
56 |
+ rm -rf "${ED}"/var/run || die |
57 |
fi |
58 |
|
59 |
- diropts -o munge -g munge -m700 |
60 |
+ [[ ${EUID} = 0 ]] && diropts -o munge -g munge -m700 |
61 |
dodir /etc/munge |
62 |
|
63 |
for d in "init.d" "default" "sysconfig"; do |
64 |
- if [ -d "${D}"/etc/${d} ]; then |
65 |
- rm -r "${D}"/etc/${d} || die |
66 |
+ if [ -d "${ED}"/etc/${d} ]; then |
67 |
+ rm -r "${ED}"/etc/${d} || die |
68 |
fi |
69 |
done |
70 |
|
71 |
- newconfd "${FILESDIR}"/${PN}d.confd ${PN}d |
72 |
- newinitd "${FILESDIR}"/${PN}d.initd ${PN}d |
73 |
+ newconfd "$(prefixify_ro "${FILESDIR}"/${PN}d.confd)" ${PN}d |
74 |
+ newinitd "$(prefixify_ro "${FILESDIR}"/${PN}d.initd)" ${PN}d |
75 |
} |