1 |
commit: a3998ce42d1c7ffc6314cfbc6a6758494b4e46dc |
2 |
Author: Mike Frysinger <vapier <AT> gentoo <DOT> org> |
3 |
AuthorDate: Tue Mar 29 09:56:22 2016 +0000 |
4 |
Commit: Mike Frysinger <vapier <AT> gentoo <DOT> org> |
5 |
CommitDate: Tue Mar 29 09:57:22 2016 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a3998ce4 |
7 |
|
8 |
sys-apps/sandbox: update EAPI & multilib handling |
9 |
|
10 |
sys-apps/sandbox/sandbox-2.10-r2.ebuild | 83 +++++++++++++++++++++++++++++++++ |
11 |
1 file changed, 83 insertions(+) |
12 |
|
13 |
diff --git a/sys-apps/sandbox/sandbox-2.10-r2.ebuild b/sys-apps/sandbox/sandbox-2.10-r2.ebuild |
14 |
new file mode 100644 |
15 |
index 0000000..e2ba4a7 |
16 |
--- /dev/null |
17 |
+++ b/sys-apps/sandbox/sandbox-2.10-r2.ebuild |
18 |
@@ -0,0 +1,83 @@ |
19 |
+# Copyright 1999-2016 Gentoo Foundation |
20 |
+# Distributed under the terms of the GNU General Public License v2 |
21 |
+ |
22 |
+# |
23 |
+# don't monkey with this ebuild unless contacting portage devs. |
24 |
+# period. |
25 |
+# |
26 |
+ |
27 |
+EAPI="5" |
28 |
+ |
29 |
+inherit eutils flag-o-matic multilib-minimal multiprocessing pax-utils |
30 |
+ |
31 |
+DESCRIPTION="sandbox'd LD_PRELOAD hack" |
32 |
+HOMEPAGE="https://www.gentoo.org/proj/en/portage/sandbox/" |
33 |
+SRC_URI="mirror://gentoo/${P}.tar.xz |
34 |
+ https://dev.gentoo.org/~vapier/dist/${P}.tar.xz" |
35 |
+ |
36 |
+LICENSE="GPL-2" |
37 |
+SLOT="0" |
38 |
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~sparc-fbsd ~x86-fbsd" |
39 |
+IUSE="" |
40 |
+ |
41 |
+DEPEND="app-arch/xz-utils |
42 |
+ >=app-misc/pax-utils-0.1.19" #265376 |
43 |
+RDEPEND="" |
44 |
+ |
45 |
+has sandbox_death_notice ${EBUILD_DEATH_HOOKS} || EBUILD_DEATH_HOOKS="${EBUILD_DEATH_HOOKS} sandbox_death_notice" |
46 |
+ |
47 |
+sandbox_death_notice() { |
48 |
+ ewarn "If configure failed with a 'cannot run C compiled programs' error, try this:" |
49 |
+ ewarn "FEATURES=-sandbox emerge sandbox" |
50 |
+} |
51 |
+ |
52 |
+src_prepare() { |
53 |
+ epatch "${FILESDIR}"/${P}-memory-corruption.patch #568714 |
54 |
+ epatch "${FILESDIR}"/${P}-disable-same.patch |
55 |
+ epatch_user |
56 |
+} |
57 |
+ |
58 |
+multilib_src_configure() { |
59 |
+ filter-lfs-flags #90228 |
60 |
+ |
61 |
+ local myconf=() |
62 |
+ host-is-pax && myconf+=( --disable-pch ) #301299 #425524 #572092 |
63 |
+ |
64 |
+ ECONF_SOURCE="${S}" \ |
65 |
+ econf "${myconf[@]}" |
66 |
+} |
67 |
+ |
68 |
+multilib_src_test() { |
69 |
+ # Default sandbox build will run with --jobs set to # cpus. |
70 |
+ emake check TESTSUITEFLAGS="--jobs=$(makeopts_jobs)" |
71 |
+} |
72 |
+ |
73 |
+multilib_src_install_all() { |
74 |
+ doenvd "${FILESDIR}"/09sandbox |
75 |
+ |
76 |
+ keepdir /var/log/sandbox |
77 |
+ fowners root:portage /var/log/sandbox |
78 |
+ fperms 0770 /var/log/sandbox |
79 |
+ |
80 |
+ cd "${S}" |
81 |
+ dodoc AUTHORS ChangeLog* NEWS README |
82 |
+} |
83 |
+ |
84 |
+pkg_preinst() { |
85 |
+ chown root:portage "${ED}"/var/log/sandbox |
86 |
+ chmod 0770 "${ED}"/var/log/sandbox |
87 |
+ |
88 |
+ if [[ ${REPLACING_VERSIONS} == 1.* ]] ; then |
89 |
+ local old=$(find "${EROOT}"/lib* -maxdepth 1 -name 'libsandbox*') |
90 |
+ if [[ -n ${old} ]] ; then |
91 |
+ elog "Removing old sandbox libraries for you:" |
92 |
+ find "${EROOT}"/lib* -maxdepth 1 -name 'libsandbox*' -print -delete |
93 |
+ fi |
94 |
+ fi |
95 |
+} |
96 |
+ |
97 |
+pkg_postinst() { |
98 |
+ if [[ ${REPLACING_VERSIONS} == 1.* ]] ; then |
99 |
+ chmod 0755 "${EROOT}"/etc/sandbox.d #265376 |
100 |
+ fi |
101 |
+} |