1 |
commit: e04b7e3bec0d7c6c53c1d3fd3c0f3ffce11cd74b |
2 |
Author: Fabian Groffen <grobian <AT> gentoo <DOT> org> |
3 |
AuthorDate: Mon Jan 7 10:27:58 2019 +0000 |
4 |
Commit: Fabian Groffen <grobian <AT> gentoo <DOT> org> |
5 |
CommitDate: Mon Jan 7 10:27:58 2019 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/proj/prefix.git/commit/?id=e04b7e3b |
7 |
|
8 |
sys-apps/portage: cleanup old, some unusable, versions |
9 |
|
10 |
Package-Manager: Portage-2.3.52.2-prefix, Repoman-2.3.12 |
11 |
Signed-off-by: Fabian Groffen <grobian <AT> gentoo.org> |
12 |
|
13 |
sys-apps/portage/Manifest | 5 - |
14 |
sys-apps/portage/portage-2.2.28-r5.ebuild | 259 ---------------------------- |
15 |
sys-apps/portage/portage-2.3.13.ebuild | 255 --------------------------- |
16 |
sys-apps/portage/portage-2.3.18.ebuild | 263 ---------------------------- |
17 |
sys-apps/portage/portage-2.3.40.3.ebuild | 274 ------------------------------ |
18 |
sys-apps/portage/portage-2.3.45.ebuild | 274 ------------------------------ |
19 |
6 files changed, 1330 deletions(-) |
20 |
|
21 |
diff --git a/sys-apps/portage/Manifest b/sys-apps/portage/Manifest |
22 |
index 994147bd0f..7a17270e13 100644 |
23 |
--- a/sys-apps/portage/Manifest |
24 |
+++ b/sys-apps/portage/Manifest |
25 |
@@ -1,6 +1 @@ |
26 |
-DIST prefix-portage-2.2.28.tar.bz2 1187416 BLAKE2B 1ec27def0b427f60b38dc60178461c2395d388500b6f20d5f9dcd76090c5e68e6578da0073cb5cc3b5b2beb2c2c55ef12afef70d7562fba0a6f0cf90847624ea SHA512 ea0661783d421d204272b9a210745aa2040a18ea347299b3d768588e10ca8dd2e24b46975249bf30010bf565514aea640f4edb9db2ca064312c899304a8c1f42 |
27 |
-DIST prefix-portage-2.3.13.tar.bz2 1205509 BLAKE2B 851492dc1d3bd55721dfc1662af98a193c8071d87b6b64a09a736864031fa6482fe59a1662789ce8320b156241470688a9a815d79f7367b79500e590a41604f5 SHA512 4d59d04b9d6a896a545a40e04973a1c29f421b5d90f08012cb00a27ba1081eb914ddb625f543c26c93c8c75ba690f6ec72e4d9301f4f8e01a5fc68a3438cf46c |
28 |
-DIST prefix-portage-2.3.18.tar.bz2 1230290 BLAKE2B 9a7a290493293f166520931aab32a720519ebec15f4c74fe0b0dcd7cc930d591c24e3c87cae4722da119d57826b020b37092ec492bb4e12b774e51334eccf156 SHA512 508a5891fc28297e68baf031f4e99674a58c6268b16d50e094adc6676fb42f81bb81bd6f3dc70c24636be64ae015db51df86c49267c8c5a98129fe5e006310d7 |
29 |
-DIST prefix-portage-2.3.40.3.tar.bz2 1253190 BLAKE2B 53e60b561e1f9b2a5367a1a23a74ba315358b8e7eb05eead2a46078198b92786745dbd07ab1bf69587866f462955a5dd6c0bc3eb51dbe507bfbff31d899c5f45 SHA512 67c2d7554c9236748b25a8b9f0f60736beda535298395ba2eb86dd5634b6520d645df193914f079d2c61cfa0d8f263f67c3476828319e2395dec2e45cf4b9b14 |
30 |
-DIST prefix-portage-2.3.45.tar.bz2 1255719 BLAKE2B 2a53b526418747edc02ab4cc8127425b92e8ae0f7fdc27af730f991f7cb6074aac51cdfd0ca75f7e6376c8059df1e02817963a0386cf1b1986eb798f21b8cf8c SHA512 dfea0774b5d801b3ca02fdd570c89c08b78f4e02e57c1b897a50af0056d4ed4522c6d236dcaf98ea3f1c446b0164abd1b45fd2cae12ed5ef6c34c83668894b5b |
31 |
DIST prefix-portage-2.3.52.2.tar.bz2 1258301 BLAKE2B 1334532e50df0c35a4694242f091395721ff8c6c5cd525c32d0b26cf11b207b17f42198ded88a49d7f2599fa3ad34feef0de2ac4219efe806e24913cb061a236 SHA512 d5f199b6c7545f49a8faa3ccdfcdecdb4bc3723513dad2c683db9d3a89a662c474aea0c95fead521f7dc8db71dd38cc55ac0cac9973710364032d8fc7877fbc2 |
32 |
|
33 |
diff --git a/sys-apps/portage/portage-2.2.28-r5.ebuild b/sys-apps/portage/portage-2.2.28-r5.ebuild |
34 |
deleted file mode 100644 |
35 |
index c8ecc510ce..0000000000 |
36 |
--- a/sys-apps/portage/portage-2.2.28-r5.ebuild |
37 |
+++ /dev/null |
38 |
@@ -1,259 +0,0 @@ |
39 |
-# Copyright 1999-2018 Gentoo Foundation |
40 |
-# Distributed under the terms of the GNU General Public License v2 |
41 |
-# $Id$ |
42 |
- |
43 |
-EAPI=5 |
44 |
- |
45 |
-PYTHON_COMPAT=( |
46 |
- pypy |
47 |
- python3_3 python3_4 python3_5 |
48 |
- python2_7 |
49 |
-) |
50 |
-PYTHON_REQ_USE='bzip2(+)' |
51 |
- |
52 |
-inherit eutils distutils-r1 multilib |
53 |
- |
54 |
-DESCRIPTION="Portage package manager used in Gentoo Prefix" |
55 |
-HOMEPAGE="http://prefix.gentoo.org/" |
56 |
-LICENSE="GPL-2" |
57 |
-KEYWORDS="~ppc-aix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" |
58 |
-SLOT="0" |
59 |
-IUSE="build doc epydoc +ipc selinux xattr prefix-chaining" |
60 |
- |
61 |
-DEPEND="!build? ( $(python_gen_impl_dep 'ssl(+)') ) |
62 |
- >=sys-devel/make-3.82 |
63 |
- >=app-arch/tar-1.27 |
64 |
- dev-lang/python-exec:2 |
65 |
- >=sys-apps/sed-4.0.5 sys-devel/patch |
66 |
- doc? ( app-text/xmlto ~app-text/docbook-xml-dtd-4.4 ) |
67 |
- epydoc? ( >=dev-python/epydoc-2.0[$(python_gen_usedep 'python2*')] )" |
68 |
-# Require sandbox-2.2 for bug #288863. |
69 |
-# For xattr, we can spawn getfattr and setfattr from sys-apps/attr, but that's |
70 |
-# quite slow, so it's not considered in the dependencies as an alternative to |
71 |
-# to python-3.3 / pyxattr. Also, xattr support is only tested with Linux, so |
72 |
-# for now, don't pull in xattr deps for other kernels. |
73 |
-# For whirlpool hash, require python[ssl] (bug #425046). |
74 |
-# For compgen, require bash[readline] (bug #445576). |
75 |
-RDEPEND=" |
76 |
- >=app-arch/tar-1.27 |
77 |
- dev-lang/python-exec:2 |
78 |
- !build? ( |
79 |
- >=sys-apps/sed-4.0.5 |
80 |
- app-shells/bash:0[readline] |
81 |
- >=app-admin/eselect-1.2 |
82 |
- ) |
83 |
- elibc_FreeBSD? ( !prefix? ( sys-freebsd/freebsd-bin ) ) |
84 |
- elibc_glibc? ( !prefix? ( >=sys-apps/sandbox-2.2 ) ) |
85 |
- elibc_uclibc? ( !prefix? ( >=sys-apps/sandbox-2.2 ) ) |
86 |
- kernel_linux? ( >=app-misc/pax-utils-0.1.17 ) |
87 |
- kernel_SunOS? ( >=app-misc/pax-utils-0.1.17 ) |
88 |
- kernel_FreeBSD? ( >=app-misc/pax-utils-0.1.17 ) |
89 |
- kernel_Darwin? ( >=app-misc/pax-utils-0.1.18 ) |
90 |
- kernel_AIX? ( >=sys-apps/aix-miscutils-0.1.1634 ) |
91 |
- selinux? ( >=sys-libs/libselinux-2.0.94[python,${PYTHON_USEDEP}] ) |
92 |
- xattr? ( kernel_linux? ( |
93 |
- >=sys-apps/install-xattr-0.3 |
94 |
- $(python_gen_cond_dep 'dev-python/pyxattr[${PYTHON_USEDEP}]' \ |
95 |
- python2_7 pypy) |
96 |
- ) ) |
97 |
- !prefix? ( !<app-admin/logrotate-3.8.0 )" |
98 |
-PDEPEND=" |
99 |
- !build? ( |
100 |
- >=net-misc/rsync-2.6.4 |
101 |
- userland_GNU? ( >=sys-apps/coreutils-6.4 ) |
102 |
- )" |
103 |
-# coreutils-6.4 rdep is for date format in emerge-webrsync #164532 |
104 |
-# NOTE: FEATURES=installsources requires debugedit and rsync |
105 |
- |
106 |
-REQUIRED_USE="epydoc? ( $(python_gen_useflags 'python2*') )" |
107 |
- |
108 |
-SRC_ARCHIVES="https://dev.gentoo.org/~dolsen/releases/portage https://dev.gentoo.org/~grobian/distfiles" |
109 |
- |
110 |
-prefix_src_archives() { |
111 |
- local x y |
112 |
- for x in ${@}; do |
113 |
- for y in ${SRC_ARCHIVES}; do |
114 |
- echo ${y}/${x} |
115 |
- done |
116 |
- done |
117 |
-} |
118 |
- |
119 |
-TARBALL_PV=${PV} |
120 |
-SRC_URI="mirror://gentoo/prefix-${PN}-${TARBALL_PV}.tar.bz2 |
121 |
- $(prefix_src_archives prefix-${PN}-${TARBALL_PV}.tar.bz2)" |
122 |
- |
123 |
-S="${WORKDIR}"/prefix-${PN}-${TARBALL_PV} |
124 |
- |
125 |
-pkg_setup() { |
126 |
- use epydoc && DISTUTILS_ALL_SUBPHASE_IMPLS=( python2.7 ) |
127 |
-} |
128 |
- |
129 |
-python_prepare_all() { |
130 |
- distutils-r1_python_prepare_all |
131 |
- |
132 |
- epatch "${FILESDIR}"/${PN}-2.2.28-ebuildshell-r1.patch # 155161 |
133 |
- epatch "${FILESDIR}"/${PN}-2.2.28-cygwin.patch # 583962 |
134 |
- use prefix-chaining && |
135 |
- epatch "${FILESDIR}"/${PN}-2.2.14-prefix-chaining.patch |
136 |
- |
137 |
- if ! use ipc ; then |
138 |
- einfo "Disabling ipc..." |
139 |
- sed -e "s:_enable_ipc_daemon = True:_enable_ipc_daemon = False:" \ |
140 |
- -i pym/_emerge/AbstractEbuildProcess.py || \ |
141 |
- die "failed to patch AbstractEbuildProcess.py" |
142 |
- fi |
143 |
- |
144 |
- if use xattr && use kernel_linux ; then |
145 |
- einfo "Adding FEATURES=xattr to make.globals ..." |
146 |
- echo -e '\nFEATURES="${FEATURES} xattr"' >> cnf/make.globals \ |
147 |
- || die "failed to append to make.globals" |
148 |
- fi |
149 |
- |
150 |
- if [[ -n ${EPREFIX} ]] ; then |
151 |
- # PREFIX LOCAL: only hack const_autotool |
152 |
- local extrapath="/usr/bin:/bin" |
153 |
- # ok, we can't rely on PORTAGE_ROOT_USER being there yet, as people |
154 |
- # tend not to update that often, as long as we are a separate ebuild |
155 |
- # we can assume when unset, it's time for some older trick |
156 |
- if [[ -z ${PORTAGE_ROOT_USER} ]] ; then |
157 |
- PORTAGE_ROOT_USER=$(python -c 'from portage.const import rootuser; print rootuser') |
158 |
- fi |
159 |
- # lazy check, but works for now |
160 |
- if [[ ${PORTAGE_ROOT_USER} == "root" ]] ; then |
161 |
- # we need this for e.g. mtree on FreeBSD (and Darwin) which is in |
162 |
- # /usr/sbin |
163 |
- extrapath="/usr/sbin:/usr/bin:/sbin:/bin" |
164 |
- fi |
165 |
- local defaultpath="${EPREFIX}/usr/sbin:${EPREFIX}/usr/bin:${EPREFIX}/sbin:${EPREFIX}/bin" |
166 |
- # We need to probe for bash in the Prefix, because it may not |
167 |
- # exist, in which case we fall back to the currently in use |
168 |
- # bash. This logic is necessary in particular during bootstrap, |
169 |
- # where we pull ourselves out of a temporary place with tools |
170 |
- local bash="${EPREFIX}/bin/bash" |
171 |
- [[ ! -x ${bash} ]] && bash=${BASH} |
172 |
- |
173 |
- einfo "Adjusting sources for ${EPREFIX}" |
174 |
- find . -type f -exec \ |
175 |
- sed -e "s|@PORTAGE_EPREFIX@|${EPREFIX}|" \ |
176 |
- -e "s|@PORTAGE_MV@|$(type -P mv)|" \ |
177 |
- -e "s|@PORTAGE_BASH@|${bash}|" \ |
178 |
- -e "s|@PREFIX_PORTAGE_PYTHON@|$(type -P python)|" \ |
179 |
- -e "s|@DEFAULT_PATH@|${defaultpath}|" \ |
180 |
- -e "s|@EXTRA_PATH@|${extrapath}|" \ |
181 |
- -e "s|@portagegroup@|${PORTAGE_GROUP:-portage}|" \ |
182 |
- -e "s|@portageuser@|${PORTAGE_USER:-portage}|" \ |
183 |
- -e "s|@rootuser@|${PORTAGE_ROOT_USER:-root}|" \ |
184 |
- -e "s|@rootuid@|$(id -u ${PORTAGE_ROOT_USER:-root})|" \ |
185 |
- -e "s|@rootgid@|$(id -g ${PORTAGE_ROOT_USER:-root})|" \ |
186 |
- -e "s|@sysconfdir@|${EPREFIX}/etc|" \ |
187 |
- -i '{}' + || \ |
188 |
- die "Failed to patch sources" |
189 |
- # We don't need the below, since setup.py deal with this (and |
190 |
- # more) so we don't have to make this correct |
191 |
- # -e "s|@PORTAGE_BASE@|${EPREFIX}/usr/lib/portage/${EPYTHON}|" \ |
192 |
- |
193 |
- # remove Makefiles, or else they will get installed |
194 |
- find . -name "Makefile.*" -delete |
195 |
- |
196 |
- einfo "Prefixing shebangs ..." |
197 |
- while read -r -d $'\0' ; do |
198 |
- local shebang=$(head -n1 "$REPLY") |
199 |
- if [[ ${shebang} == "#!"* && ! ${shebang} == "#!${EPREFIX}/"* ]] ; then |
200 |
- sed -i -e "1s:.*:#!${EPREFIX}${shebang:2}:" "$REPLY" || \ |
201 |
- die "sed failed" |
202 |
- fi |
203 |
- done < <(find . -type f -print0) |
204 |
- |
205 |
- einfo "Setting gentoo_prefix as reponame for emerge-webrsync" |
206 |
- sed -i -e 's/repo_name=gentoo/repo_name=gentoo_prefix/' \ |
207 |
- bin/emerge-webrsync || die |
208 |
- # END PREFIX LOCAL |
209 |
- fi |
210 |
- |
211 |
- # PREFIX LOCAL: make.conf is written by bootstrap-prefix.sh |
212 |
- if use !prefix ; then |
213 |
- cd "${S}/cnf" || die |
214 |
- if [ -f "make.conf.${ARCH}".diff ]; then |
215 |
- patch make.conf "make.conf.${ARCH}".diff || \ |
216 |
- die "Failed to patch make.conf.example" |
217 |
- else |
218 |
- eerror "" |
219 |
- eerror "Portage does not have an arch-specific configuration for this arch." |
220 |
- eerror "Please notify the arch maintainer about this issue. Using generic." |
221 |
- eerror "" |
222 |
- fi |
223 |
- fi |
224 |
-} |
225 |
- |
226 |
-python_compile_all() { |
227 |
- local targets=() |
228 |
- use doc && targets+=( docbook ) |
229 |
- use epydoc && targets+=( epydoc ) |
230 |
- |
231 |
- if [[ ${targets[@]} ]]; then |
232 |
- esetup.py "${targets[@]}" |
233 |
- fi |
234 |
-} |
235 |
- |
236 |
-python_test() { |
237 |
- esetup.py test |
238 |
-} |
239 |
- |
240 |
-python_install() { |
241 |
- # Install sbin scripts to bindir for python-exec linking |
242 |
- # they will be relocated in pkg_preinst() |
243 |
- distutils-r1_python_install \ |
244 |
- --system-prefix="${EPREFIX}/usr" \ |
245 |
- --bindir="$(python_get_scriptdir)" \ |
246 |
- --docdir="${EPREFIX}/usr/share/doc/${PF}" \ |
247 |
- --htmldir="${EPREFIX}/usr/share/doc/${PF}/html" \ |
248 |
- --portage-bindir="${EPREFIX}/usr/lib/portage/${EPYTHON}" \ |
249 |
- --sbindir="$(python_get_scriptdir)" \ |
250 |
- --sysconfdir="${EPREFIX}/etc" \ |
251 |
- "${@}" |
252 |
-} |
253 |
- |
254 |
-python_install_all() { |
255 |
- distutils-r1_python_install_all |
256 |
- |
257 |
- local targets=() |
258 |
- use doc && targets+=( install_docbook ) |
259 |
- use epydoc && targets+=( install_epydoc ) |
260 |
- |
261 |
- # install docs |
262 |
- if [[ ${targets[@]} ]]; then |
263 |
- esetup.py "${targets[@]}" |
264 |
- fi |
265 |
- |
266 |
- # Due to distutils/python-exec limitations |
267 |
- # these must be installed to /usr/bin. |
268 |
- local sbin_relocations='archive-conf dispatch-conf emaint env-update etc-update fixpackages regenworld' |
269 |
- einfo "Moving admin scripts to the correct directory" |
270 |
- dodir /usr/sbin |
271 |
- for target in ${sbin_relocations}; do |
272 |
- einfo "Moving /usr/bin/${target} to /usr/sbin/${target}" |
273 |
- mv "${ED}usr/bin/${target}" "${ED}usr/sbin/${target}" || die "sbin scripts move failed!" |
274 |
- done |
275 |
-} |
276 |
- |
277 |
-pkg_preinst() { |
278 |
- # comment out sanity test until it is fixed to work |
279 |
- # with the new PORTAGE_PYM_PATH |
280 |
- #if [[ $ROOT == / ]] ; then |
281 |
- ## Run some minimal tests as a sanity check. |
282 |
- #local test_runner=$(find "${ED}" -name runTests) |
283 |
- #if [[ -n $test_runner && -x $test_runner ]] ; then |
284 |
- #einfo "Running preinst sanity tests..." |
285 |
- #"$test_runner" || die "preinst sanity tests failed" |
286 |
- #fi |
287 |
- #fi |
288 |
- |
289 |
- # elog dir must exist to avoid logrotate error for bug #415911. |
290 |
- # This code runs in preinst in order to bypass the mapping of |
291 |
- # portage:portage to root:root which happens after src_install. |
292 |
- keepdir /var/log/portage/elog |
293 |
- # This is allowed to fail if the user/group are invalid for prefix users. |
294 |
- if chown ${PORTAGE_USER}:${PORTAGE_GROUP} "${ED}"var/log/portage{,/elog} 2>/dev/null ; then |
295 |
- chmod g+s,ug+rwx "${ED}"var/log/portage{,/elog} |
296 |
- fi |
297 |
-} |
298 |
|
299 |
diff --git a/sys-apps/portage/portage-2.3.13.ebuild b/sys-apps/portage/portage-2.3.13.ebuild |
300 |
deleted file mode 100644 |
301 |
index 6ed633fbda..0000000000 |
302 |
--- a/sys-apps/portage/portage-2.3.13.ebuild |
303 |
+++ /dev/null |
304 |
@@ -1,255 +0,0 @@ |
305 |
-# Copyright 1999-2018 Gentoo Foundation |
306 |
-# Distributed under the terms of the GNU General Public License v2 |
307 |
- |
308 |
-EAPI=5 |
309 |
- |
310 |
-PYTHON_COMPAT=( |
311 |
- pypy |
312 |
- python3_3 python3_4 python3_5 python3_6 |
313 |
- python2_7 |
314 |
-) |
315 |
-PYTHON_REQ_USE='bzip2(+),threads(+)' |
316 |
- |
317 |
-inherit eutils distutils-r1 multilib |
318 |
- |
319 |
-DESCRIPTION="Portage package manager used in Gentoo Prefix" |
320 |
-HOMEPAGE="http://prefix.gentoo.org/" |
321 |
-LICENSE="GPL-2" |
322 |
-KEYWORDS="~ppc-aix ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" |
323 |
-SLOT="0" |
324 |
-IUSE="build doc epydoc +ipc +native-extensions selinux xattr prefix-chaining" |
325 |
- |
326 |
-DEPEND="!build? ( $(python_gen_impl_dep 'ssl(+)') ) |
327 |
- >=app-arch/tar-1.27 |
328 |
- dev-lang/python-exec:2 |
329 |
- >=sys-apps/sed-4.0.5 sys-devel/patch |
330 |
- doc? ( app-text/xmlto ~app-text/docbook-xml-dtd-4.4 ) |
331 |
- epydoc? ( >=dev-python/epydoc-2.0[$(python_gen_usedep 'python2*')] )" |
332 |
-# Require sandbox-2.2 for bug #288863. |
333 |
-# For xattr, we can spawn getfattr and setfattr from sys-apps/attr, but that's |
334 |
-# quite slow, so it's not considered in the dependencies as an alternative to |
335 |
-# to python-3.3 / pyxattr. Also, xattr support is only tested with Linux, so |
336 |
-# for now, don't pull in xattr deps for other kernels. |
337 |
-# For whirlpool hash, require python[ssl] (bug #425046). |
338 |
-# For compgen, require bash[readline] (bug #445576). |
339 |
-RDEPEND=" |
340 |
- >=app-arch/tar-1.27 |
341 |
- dev-lang/python-exec:2 |
342 |
- !build? ( |
343 |
- >=sys-apps/sed-4.0.5 |
344 |
- app-shells/bash:0[readline] |
345 |
- >=app-admin/eselect-1.2 |
346 |
- ) |
347 |
- elibc_FreeBSD? ( !prefix? ( sys-freebsd/freebsd-bin ) ) |
348 |
- elibc_glibc? ( !prefix? ( >=sys-apps/sandbox-2.2 ) ) |
349 |
- elibc_uclibc? ( !prefix? ( >=sys-apps/sandbox-2.2 ) ) |
350 |
- kernel_linux? ( >=app-misc/pax-utils-0.1.17 ) |
351 |
- kernel_SunOS? ( >=app-misc/pax-utils-0.1.17 ) |
352 |
- kernel_FreeBSD? ( >=app-misc/pax-utils-0.1.17 ) |
353 |
- kernel_Darwin? ( >=app-misc/pax-utils-0.1.18 ) |
354 |
- kernel_AIX? ( >=sys-apps/aix-miscutils-0.1.1634 ) |
355 |
- selinux? ( >=sys-libs/libselinux-2.0.94[python,${PYTHON_USEDEP}] ) |
356 |
- xattr? ( kernel_linux? ( |
357 |
- >=sys-apps/install-xattr-0.3 |
358 |
- $(python_gen_cond_dep 'dev-python/pyxattr[${PYTHON_USEDEP}]' \ |
359 |
- python2_7 pypy) |
360 |
- ) ) |
361 |
- !prefix? ( !<app-admin/logrotate-3.8.0 )" |
362 |
-PDEPEND=" |
363 |
- !build? ( |
364 |
- >=net-misc/rsync-2.6.4 |
365 |
- userland_GNU? ( >=sys-apps/coreutils-6.4 ) |
366 |
- )" |
367 |
-# coreutils-6.4 rdep is for date format in emerge-webrsync #164532 |
368 |
-# NOTE: FEATURES=installsources requires debugedit and rsync |
369 |
- |
370 |
-REQUIRED_USE="epydoc? ( $(python_gen_useflags 'python2*') )" |
371 |
- |
372 |
-SRC_ARCHIVES="https://dev.gentoo.org/~dolsen/releases/portage https://dev.gentoo.org/~grobian/distfiles" |
373 |
- |
374 |
-prefix_src_archives() { |
375 |
- local x y |
376 |
- for x in ${@}; do |
377 |
- for y in ${SRC_ARCHIVES}; do |
378 |
- echo ${y}/${x} |
379 |
- done |
380 |
- done |
381 |
-} |
382 |
- |
383 |
-TARBALL_PV=${PV} |
384 |
-SRC_URI="mirror://gentoo/prefix-${PN}-${TARBALL_PV}.tar.bz2 |
385 |
- $(prefix_src_archives prefix-${PN}-${TARBALL_PV}.tar.bz2)" |
386 |
- |
387 |
-S="${WORKDIR}"/prefix-${PN}-${TARBALL_PV} |
388 |
- |
389 |
-pkg_setup() { |
390 |
- use epydoc && DISTUTILS_ALL_SUBPHASE_IMPLS=( python2.7 ) |
391 |
-} |
392 |
- |
393 |
-python_prepare_all() { |
394 |
- distutils-r1_python_prepare_all |
395 |
- |
396 |
- epatch "${FILESDIR}"/${PN}-2.3.10-ebuildshell.patch # 155161 |
397 |
- use prefix-chaining && |
398 |
- epatch "${FILESDIR}"/${PN}-2.3.8-prefix-chaining.patch |
399 |
- |
400 |
- if use native-extensions; then |
401 |
- printf "[build_ext]\nportage-ext-modules=true\n" >> \ |
402 |
- setup.cfg || die |
403 |
- fi |
404 |
- |
405 |
- if ! use ipc ; then |
406 |
- einfo "Disabling ipc..." |
407 |
- sed -e "s:_enable_ipc_daemon = True:_enable_ipc_daemon = False:" \ |
408 |
- -i pym/_emerge/AbstractEbuildProcess.py || \ |
409 |
- die "failed to patch AbstractEbuildProcess.py" |
410 |
- fi |
411 |
- |
412 |
- if use xattr && use kernel_linux ; then |
413 |
- einfo "Adding FEATURES=xattr to make.globals ..." |
414 |
- echo -e '\nFEATURES="${FEATURES} xattr"' >> cnf/make.globals \ |
415 |
- || die "failed to append to make.globals" |
416 |
- fi |
417 |
- |
418 |
- if [[ -n ${EPREFIX} ]] ; then |
419 |
- # PREFIX LOCAL: only hack const_autotool |
420 |
- local extrapath="/usr/sbin:/usr/bin:/sbin:/bin" |
421 |
- # ok, we can't rely on PORTAGE_ROOT_USER being there yet, as people |
422 |
- # tend not to update that often, as long as we are a separate ebuild |
423 |
- # we can assume when unset, it's time for some older trick |
424 |
- if [[ -z ${PORTAGE_ROOT_USER} ]] ; then |
425 |
- PORTAGE_ROOT_USER=$(python -c 'from portage.const import rootuser; print rootuser') |
426 |
- fi |
427 |
- local defaultpath="${EPREFIX}/usr/sbin:${EPREFIX}/usr/bin:${EPREFIX}/sbin:${EPREFIX}/bin" |
428 |
- # We need to probe for bash in the Prefix, because it may not |
429 |
- # exist, in which case we fall back to the currently in use |
430 |
- # bash. This logic is necessary in particular during bootstrap, |
431 |
- # where we pull ourselves out of a temporary place with tools |
432 |
- local bash="${EPREFIX}/bin/bash" |
433 |
- [[ ! -x ${bash} ]] && bash=${BASH} |
434 |
- |
435 |
- einfo "Adjusting sources for ${EPREFIX}" |
436 |
- find . -type f -exec \ |
437 |
- sed -e "s|@PORTAGE_EPREFIX@|${EPREFIX}|" \ |
438 |
- -e "s|@PORTAGE_MV@|$(type -P mv)|" \ |
439 |
- -e "s|@PORTAGE_BASH@|${bash}|" \ |
440 |
- -e "s|@PREFIX_PORTAGE_PYTHON@|$(type -P python)|" \ |
441 |
- -e "s|@DEFAULT_PATH@|${defaultpath}|" \ |
442 |
- -e "s|@EXTRA_PATH@|${extrapath}|" \ |
443 |
- -e "s|@portagegroup@|${PORTAGE_GROUP:-portage}|" \ |
444 |
- -e "s|@portageuser@|${PORTAGE_USER:-portage}|" \ |
445 |
- -e "s|@rootuser@|${PORTAGE_ROOT_USER:-root}|" \ |
446 |
- -e "s|@rootuid@|$(id -u ${PORTAGE_ROOT_USER:-root})|" \ |
447 |
- -e "s|@rootgid@|$(id -g ${PORTAGE_ROOT_USER:-root})|" \ |
448 |
- -e "s|@sysconfdir@|${EPREFIX}/etc|" \ |
449 |
- -i '{}' + || \ |
450 |
- die "Failed to patch sources" |
451 |
- # We don't need the below, since setup.py deals with this (and |
452 |
- # more) so we don't have to make this correct |
453 |
- # -e "s|@PORTAGE_BASE@|${EPREFIX}/usr/lib/portage/${EPYTHON}|" \ |
454 |
- |
455 |
- # remove Makefiles, or else they will get installed |
456 |
- find . -name "Makefile.*" -delete |
457 |
- |
458 |
- einfo "Prefixing shebangs ..." |
459 |
- while read -r -d $'\0' ; do |
460 |
- local shebang=$(head -n1 "$REPLY") |
461 |
- if [[ ${shebang} == "#!"* && ! ${shebang} == "#!${EPREFIX}/"* ]] ; then |
462 |
- sed -i -e "1s:.*:#!${EPREFIX}${shebang:2}:" "$REPLY" || \ |
463 |
- die "sed failed" |
464 |
- fi |
465 |
- done < <(find . -type f -print0) |
466 |
- |
467 |
- einfo "Setting gentoo_prefix as reponame for emerge-webrsync" |
468 |
- sed -i -e 's/repo_name=gentoo/repo_name=gentoo_prefix/' \ |
469 |
- bin/emerge-webrsync || die |
470 |
- # END PREFIX LOCAL |
471 |
- fi |
472 |
- |
473 |
- # PREFIX LOCAL: make.conf is written by bootstrap-prefix.sh |
474 |
- if use !prefix ; then |
475 |
- cd "${S}/cnf" || die |
476 |
- if [ -f "make.conf.example.${ARCH}".diff ]; then |
477 |
- patch make.conf.example "make.conf.example.${ARCH}".diff || \ |
478 |
- die "Failed to patch make.conf.example" |
479 |
- else |
480 |
- eerror "" |
481 |
- eerror "Portage does not have an arch-specific configuration for this arch." |
482 |
- eerror "Please notify the arch maintainer about this issue. Using generic." |
483 |
- eerror "" |
484 |
- fi |
485 |
- fi |
486 |
-} |
487 |
- |
488 |
-python_compile_all() { |
489 |
- local targets=() |
490 |
- use doc && targets+=( docbook ) |
491 |
- use epydoc && targets+=( epydoc ) |
492 |
- |
493 |
- if [[ ${targets[@]} ]]; then |
494 |
- esetup.py "${targets[@]}" |
495 |
- fi |
496 |
-} |
497 |
- |
498 |
-python_test() { |
499 |
- esetup.py test |
500 |
-} |
501 |
- |
502 |
-python_install() { |
503 |
- # Install sbin scripts to bindir for python-exec linking |
504 |
- # they will be relocated in pkg_preinst() |
505 |
- distutils-r1_python_install \ |
506 |
- --system-prefix="${EPREFIX}/usr" \ |
507 |
- --bindir="$(python_get_scriptdir)" \ |
508 |
- --docdir="${EPREFIX}/usr/share/doc/${PF}" \ |
509 |
- --htmldir="${EPREFIX}/usr/share/doc/${PF}/html" \ |
510 |
- --portage-bindir="${EPREFIX}/usr/lib/portage/${EPYTHON}" \ |
511 |
- --sbindir="$(python_get_scriptdir)" \ |
512 |
- --sysconfdir="${EPREFIX}/etc" \ |
513 |
- "${@}" |
514 |
-} |
515 |
- |
516 |
-python_install_all() { |
517 |
- distutils-r1_python_install_all |
518 |
- |
519 |
- local targets=() |
520 |
- use doc && targets+=( install_docbook ) |
521 |
- use epydoc && targets+=( install_epydoc ) |
522 |
- |
523 |
- # install docs |
524 |
- if [[ ${targets[@]} ]]; then |
525 |
- esetup.py "${targets[@]}" |
526 |
- fi |
527 |
- |
528 |
- # Due to distutils/python-exec limitations |
529 |
- # these must be installed to /usr/bin. |
530 |
- local sbin_relocations='archive-conf dispatch-conf emaint env-update etc-update fixpackages regenworld' |
531 |
- einfo "Moving admin scripts to the correct directory" |
532 |
- dodir /usr/sbin |
533 |
- for target in ${sbin_relocations}; do |
534 |
- einfo "Moving /usr/bin/${target} to /usr/sbin/${target}" |
535 |
- mv "${ED}usr/bin/${target}" "${ED}usr/sbin/${target}" || die "sbin scripts move failed!" |
536 |
- done |
537 |
-} |
538 |
- |
539 |
-pkg_preinst() { |
540 |
- # comment out sanity test until it is fixed to work |
541 |
- # with the new PORTAGE_PYM_PATH |
542 |
- #if [[ $ROOT == / ]] ; then |
543 |
- ## Run some minimal tests as a sanity check. |
544 |
- #local test_runner=$(find "${ED}" -name runTests) |
545 |
- #if [[ -n $test_runner && -x $test_runner ]] ; then |
546 |
- #einfo "Running preinst sanity tests..." |
547 |
- #"$test_runner" || die "preinst sanity tests failed" |
548 |
- #fi |
549 |
- #fi |
550 |
- |
551 |
- # elog dir must exist to avoid logrotate error for bug #415911. |
552 |
- # This code runs in preinst in order to bypass the mapping of |
553 |
- # portage:portage to root:root which happens after src_install. |
554 |
- keepdir /var/log/portage/elog |
555 |
- # This is allowed to fail if the user/group are invalid for prefix users. |
556 |
- if chown ${PORTAGE_USER}:${PORTAGE_GROUP} "${ED}"var/log/portage{,/elog} 2>/dev/null ; then |
557 |
- chmod g+s,ug+rwx "${ED}"var/log/portage{,/elog} |
558 |
- fi |
559 |
-} |
560 |
|
561 |
diff --git a/sys-apps/portage/portage-2.3.18.ebuild b/sys-apps/portage/portage-2.3.18.ebuild |
562 |
deleted file mode 100644 |
563 |
index f1b6e82970..0000000000 |
564 |
--- a/sys-apps/portage/portage-2.3.18.ebuild |
565 |
+++ /dev/null |
566 |
@@ -1,263 +0,0 @@ |
567 |
-# Copyright 1999-2018 Gentoo Foundation |
568 |
-# Distributed under the terms of the GNU General Public License v2 |
569 |
- |
570 |
-EAPI=5 |
571 |
- |
572 |
-PYTHON_COMPAT=( |
573 |
- pypy |
574 |
- python3_4 python3_5 python3_6 |
575 |
- python2_7 |
576 |
-) |
577 |
-PYTHON_REQ_USE='bzip2(+),threads(+)' |
578 |
- |
579 |
-inherit eutils distutils-r1 multilib |
580 |
- |
581 |
-DESCRIPTION="Portage package manager used in Gentoo Prefix" |
582 |
-HOMEPAGE="https://wiki.gentoo.org/wiki/Project:Portage" |
583 |
-LICENSE="GPL-2" |
584 |
-KEYWORDS="~ppc-aix ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" |
585 |
-SLOT="0" |
586 |
-IUSE="build doc epydoc +ipc +native-extensions selinux xattr prefix-chaining" |
587 |
- |
588 |
-DEPEND="!build? ( $(python_gen_impl_dep 'ssl(+)') ) |
589 |
- >=app-arch/tar-1.27 |
590 |
- dev-lang/python-exec:2 |
591 |
- >=sys-apps/sed-4.0.5 sys-devel/patch |
592 |
- doc? ( app-text/xmlto ~app-text/docbook-xml-dtd-4.4 ) |
593 |
- epydoc? ( >=dev-python/epydoc-2.0[$(python_gen_usedep 'python2*')] )" |
594 |
-# Require sandbox-2.2 for bug #288863. |
595 |
-# For xattr, we can spawn getfattr and setfattr from sys-apps/attr, but that's |
596 |
-# quite slow, so it's not considered in the dependencies as an alternative to |
597 |
-# to python-3.3 / pyxattr. Also, xattr support is only tested with Linux, so |
598 |
-# for now, don't pull in xattr deps for other kernels. |
599 |
-# For whirlpool hash, require python[ssl] (bug #425046). |
600 |
-# For compgen, require bash[readline] (bug #445576). |
601 |
-RDEPEND=" |
602 |
- >=app-arch/tar-1.27 |
603 |
- dev-lang/python-exec:2 |
604 |
- !build? ( |
605 |
- >=sys-apps/sed-4.0.5 |
606 |
- app-shells/bash:0[readline] |
607 |
- >=app-admin/eselect-1.2 |
608 |
- $(python_gen_cond_dep 'dev-python/pyblake2[${PYTHON_USEDEP}]' \ |
609 |
- python{2_7,3_4,3_5} pypy) |
610 |
- ) |
611 |
- elibc_FreeBSD? ( !prefix? ( sys-freebsd/freebsd-bin ) ) |
612 |
- elibc_glibc? ( !prefix? ( >=sys-apps/sandbox-2.2 ) ) |
613 |
- elibc_uclibc? ( !prefix? ( >=sys-apps/sandbox-2.2 ) ) |
614 |
- kernel_linux? ( >=app-misc/pax-utils-0.1.17 ) |
615 |
- kernel_SunOS? ( >=app-misc/pax-utils-0.1.17 ) |
616 |
- kernel_FreeBSD? ( >=app-misc/pax-utils-0.1.17 ) |
617 |
- kernel_Darwin? ( >=app-misc/pax-utils-0.1.18 ) |
618 |
- kernel_AIX? ( >=sys-apps/aix-miscutils-0.1.1634 ) |
619 |
- selinux? ( >=sys-libs/libselinux-2.0.94[python,${PYTHON_USEDEP}] ) |
620 |
- xattr? ( kernel_linux? ( |
621 |
- >=sys-apps/install-xattr-0.3 |
622 |
- $(python_gen_cond_dep 'dev-python/pyxattr[${PYTHON_USEDEP}]' \ |
623 |
- python2_7 pypy) |
624 |
- ) ) |
625 |
- !<app-admin/logrotate-3.8.0" |
626 |
-PDEPEND=" |
627 |
- !build? ( |
628 |
- >=net-misc/rsync-2.6.4 |
629 |
- userland_GNU? ( >=sys-apps/coreutils-6.4 ) |
630 |
- )" |
631 |
-# coreutils-6.4 rdep is for date format in emerge-webrsync #164532 |
632 |
-# NOTE: FEATURES=installsources requires debugedit and rsync |
633 |
- |
634 |
-REQUIRED_USE="epydoc? ( $(python_gen_useflags 'python2*') )" |
635 |
- |
636 |
-SRC_ARCHIVES="https://dev.gentoo.org/~zmedico/portage/archives https://dev.gentoo.org/~grobian/distfiles" |
637 |
- |
638 |
-prefix_src_archives() { |
639 |
- local x y |
640 |
- for x in ${@}; do |
641 |
- for y in ${SRC_ARCHIVES}; do |
642 |
- echo ${y}/${x} |
643 |
- done |
644 |
- done |
645 |
-} |
646 |
- |
647 |
-TARBALL_PV=${PV} |
648 |
-SRC_URI="mirror://gentoo/prefix-${PN}-${TARBALL_PV}.tar.bz2 |
649 |
- $(prefix_src_archives prefix-${PN}-${TARBALL_PV}.tar.bz2)" |
650 |
- |
651 |
-S="${WORKDIR}"/prefix-${PN}-${TARBALL_PV} |
652 |
- |
653 |
-pkg_setup() { |
654 |
- use epydoc && DISTUTILS_ALL_SUBPHASE_IMPLS=( python2.7 ) |
655 |
-} |
656 |
- |
657 |
-python_prepare_all() { |
658 |
- distutils-r1_python_prepare_all |
659 |
- |
660 |
- epatch "${FILESDIR}"/${PN}-2.3.10-ebuildshell.patch # 155161 |
661 |
- use prefix-chaining && |
662 |
- epatch "${FILESDIR}"/${PN}-2.3.18-prefix-chaining.patch |
663 |
- |
664 |
- if use native-extensions; then |
665 |
- printf "[build_ext]\nportage-ext-modules=true\n" >> \ |
666 |
- setup.cfg || die |
667 |
- fi |
668 |
- |
669 |
- if ! use ipc ; then |
670 |
- einfo "Disabling ipc..." |
671 |
- sed -e "s:_enable_ipc_daemon = True:_enable_ipc_daemon = False:" \ |
672 |
- -i pym/_emerge/AbstractEbuildProcess.py || \ |
673 |
- die "failed to patch AbstractEbuildProcess.py" |
674 |
- fi |
675 |
- |
676 |
- if use xattr && use kernel_linux ; then |
677 |
- einfo "Adding FEATURES=xattr to make.globals ..." |
678 |
- echo -e '\nFEATURES="${FEATURES} xattr"' >> cnf/make.globals \ |
679 |
- || die "failed to append to make.globals" |
680 |
- fi |
681 |
- |
682 |
- if [[ -n ${EPREFIX} ]] ; then |
683 |
- # PREFIX LOCAL: only hack const_autotool |
684 |
- local extrapath="/usr/sbin:/usr/bin:/sbin:/bin" |
685 |
- # ok, we can't rely on PORTAGE_ROOT_USER being there yet, as people |
686 |
- # tend not to update that often, as long as we are a separate ebuild |
687 |
- # we can assume when unset, it's time for some older trick |
688 |
- if [[ -z ${PORTAGE_ROOT_USER} ]] ; then |
689 |
- PORTAGE_ROOT_USER=$(python -c 'from portage.const import rootuser; print rootuser') |
690 |
- fi |
691 |
- local defaultpath="${EPREFIX}/usr/sbin:${EPREFIX}/usr/bin:${EPREFIX}/sbin:${EPREFIX}/bin" |
692 |
- # We need to probe for bash in the Prefix, because it may not |
693 |
- # exist, in which case we fall back to the currently in use |
694 |
- # bash. This logic is necessary in particular during bootstrap, |
695 |
- # where we pull ourselves out of a temporary place with tools |
696 |
- local bash="${EPREFIX}/bin/bash" |
697 |
- [[ ! -x ${bash} ]] && bash=${BASH} |
698 |
- |
699 |
- einfo "Adjusting sources for ${EPREFIX}" |
700 |
- find . -type f -exec \ |
701 |
- sed -e "s|@PORTAGE_EPREFIX@|${EPREFIX}|" \ |
702 |
- -e "s|@PORTAGE_MV@|$(type -P mv)|" \ |
703 |
- -e "s|@PORTAGE_BASH@|${bash}|" \ |
704 |
- -e "s|@PREFIX_PORTAGE_PYTHON@|$(type -P python)|" \ |
705 |
- -e "s|@DEFAULT_PATH@|${defaultpath}|" \ |
706 |
- -e "s|@EXTRA_PATH@|${extrapath}|" \ |
707 |
- -e "s|@portagegroup@|${PORTAGE_GROUP:-portage}|" \ |
708 |
- -e "s|@portageuser@|${PORTAGE_USER:-portage}|" \ |
709 |
- -e "s|@rootuser@|${PORTAGE_ROOT_USER:-root}|" \ |
710 |
- -e "s|@rootuid@|$(id -u ${PORTAGE_ROOT_USER:-root})|" \ |
711 |
- -e "s|@rootgid@|$(id -g ${PORTAGE_ROOT_USER:-root})|" \ |
712 |
- -e "s|@sysconfdir@|${EPREFIX}/etc|" \ |
713 |
- -i '{}' + || \ |
714 |
- die "Failed to patch sources" |
715 |
- # We don't need the below, since setup.py deals with this (and |
716 |
- # more) so we don't have to make this correct |
717 |
- # -e "s|@PORTAGE_BASE@|${EPREFIX}/usr/lib/portage/${EPYTHON}|" \ |
718 |
- |
719 |
- # remove Makefiles, or else they will get installed |
720 |
- find . -name "Makefile.*" -delete |
721 |
- |
722 |
- einfo "Prefixing shebangs ..." |
723 |
- while read -r -d $'\0' ; do |
724 |
- local shebang=$(head -n1 "$REPLY") |
725 |
- if [[ ${shebang} == "#!"* && ! ${shebang} == "#!${EPREFIX}/"* ]] ; then |
726 |
- sed -i -e "1s:.*:#!${EPREFIX}${shebang:2}:" "$REPLY" || \ |
727 |
- die "sed failed" |
728 |
- fi |
729 |
- done < <(find . -type f -print0) |
730 |
- |
731 |
- einfo "Setting gentoo_prefix as reponame for emerge-webrsync" |
732 |
- sed -i -e 's/repo_name=gentoo/repo_name=gentoo_prefix/' \ |
733 |
- bin/emerge-webrsync || die |
734 |
- # END PREFIX LOCAL |
735 |
- fi |
736 |
- |
737 |
- # PREFIX LOCAL: make.conf is written by bootstrap-prefix.sh |
738 |
- if use !prefix ; then |
739 |
- cd "${S}/cnf" || die |
740 |
- if [ -f "make.conf.example.${ARCH}".diff ]; then |
741 |
- patch make.conf.example "make.conf.example.${ARCH}".diff || \ |
742 |
- die "Failed to patch make.conf.example" |
743 |
- else |
744 |
- eerror "" |
745 |
- eerror "Portage does not have an arch-specific configuration for this arch." |
746 |
- eerror "Please notify the arch maintainer about this issue. Using generic." |
747 |
- eerror "" |
748 |
- fi |
749 |
- fi |
750 |
-} |
751 |
- |
752 |
-python_compile_all() { |
753 |
- local targets=() |
754 |
- use doc && targets+=( docbook ) |
755 |
- use epydoc && targets+=( epydoc ) |
756 |
- |
757 |
- if [[ ${targets[@]} ]]; then |
758 |
- esetup.py "${targets[@]}" |
759 |
- fi |
760 |
-} |
761 |
- |
762 |
-python_test() { |
763 |
- esetup.py test |
764 |
-} |
765 |
- |
766 |
-python_install() { |
767 |
- # Install sbin scripts to bindir for python-exec linking |
768 |
- # they will be relocated in pkg_preinst() |
769 |
- distutils-r1_python_install \ |
770 |
- --system-prefix="${EPREFIX}/usr" \ |
771 |
- --bindir="$(python_get_scriptdir)" \ |
772 |
- --docdir="${EPREFIX}/usr/share/doc/${PF}" \ |
773 |
- --htmldir="${EPREFIX}/usr/share/doc/${PF}/html" \ |
774 |
- --portage-bindir="${EPREFIX}/usr/lib/portage/${EPYTHON}" \ |
775 |
- --sbindir="$(python_get_scriptdir)" \ |
776 |
- --sysconfdir="${EPREFIX}/etc" \ |
777 |
- "${@}" |
778 |
-} |
779 |
- |
780 |
-python_install_all() { |
781 |
- distutils-r1_python_install_all |
782 |
- |
783 |
- local targets=() |
784 |
- use doc && targets+=( |
785 |
- install_docbook |
786 |
- --htmldir="${EPREFIX}/usr/share/doc/${PF}/html" |
787 |
- ) |
788 |
- use epydoc && targets+=( |
789 |
- install_epydoc |
790 |
- --htmldir="${EPREFIX}/usr/share/doc/${PF}/html" |
791 |
- ) |
792 |
- |
793 |
- # install docs |
794 |
- if [[ ${targets[@]} ]]; then |
795 |
- esetup.py "${targets[@]}" |
796 |
- fi |
797 |
- |
798 |
- # Due to distutils/python-exec limitations |
799 |
- # these must be installed to /usr/bin. |
800 |
- local sbin_relocations='archive-conf dispatch-conf emaint env-update etc-update fixpackages regenworld' |
801 |
- einfo "Moving admin scripts to the correct directory" |
802 |
- dodir /usr/sbin |
803 |
- for target in ${sbin_relocations}; do |
804 |
- einfo "Moving /usr/bin/${target} to /usr/sbin/${target}" |
805 |
- mv "${ED}usr/bin/${target}" "${ED}usr/sbin/${target}" || die "sbin scripts move failed!" |
806 |
- done |
807 |
-} |
808 |
- |
809 |
-pkg_preinst() { |
810 |
- # comment out sanity test until it is fixed to work |
811 |
- # with the new PORTAGE_PYM_PATH |
812 |
- #if [[ $ROOT == / ]] ; then |
813 |
- ## Run some minimal tests as a sanity check. |
814 |
- #local test_runner=$(find "${ED}" -name runTests) |
815 |
- #if [[ -n $test_runner && -x $test_runner ]] ; then |
816 |
- #einfo "Running preinst sanity tests..." |
817 |
- #"$test_runner" || die "preinst sanity tests failed" |
818 |
- #fi |
819 |
- #fi |
820 |
- |
821 |
- # elog dir must exist to avoid logrotate error for bug #415911. |
822 |
- # This code runs in preinst in order to bypass the mapping of |
823 |
- # portage:portage to root:root which happens after src_install. |
824 |
- keepdir /var/log/portage/elog |
825 |
- # This is allowed to fail if the user/group are invalid for prefix users. |
826 |
- if chown ${PORTAGE_USER}:${PORTAGE_GROUP} "${ED}"var/log/portage{,/elog} 2>/dev/null ; then |
827 |
- chmod g+s,ug+rwx "${ED}"var/log/portage{,/elog} |
828 |
- fi |
829 |
-} |
830 |
|
831 |
diff --git a/sys-apps/portage/portage-2.3.40.3.ebuild b/sys-apps/portage/portage-2.3.40.3.ebuild |
832 |
deleted file mode 100644 |
833 |
index 2ebda124cb..0000000000 |
834 |
--- a/sys-apps/portage/portage-2.3.40.3.ebuild |
835 |
+++ /dev/null |
836 |
@@ -1,274 +0,0 @@ |
837 |
-# Copyright 1999-2018 Gentoo Foundation |
838 |
-# Distributed under the terms of the GNU General Public License v2 |
839 |
- |
840 |
-EAPI=5 |
841 |
- |
842 |
-PYTHON_COMPAT=( |
843 |
- pypy |
844 |
- python3_4 python3_5 python3_6 |
845 |
- python2_7 |
846 |
-) |
847 |
-PYTHON_REQ_USE='bzip2(+),threads(+)' |
848 |
- |
849 |
-inherit eutils distutils-r1 multilib |
850 |
- |
851 |
-DESCRIPTION="Portage package manager used in Gentoo Prefix" |
852 |
-HOMEPAGE="https://wiki.gentoo.org/wiki/Project:Portage" |
853 |
-LICENSE="GPL-2" |
854 |
-KEYWORDS="~ppc-aix ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" |
855 |
-SLOT="0" |
856 |
-IUSE="build doc epydoc +ipc +native-extensions selinux xattr prefix-chaining" |
857 |
- |
858 |
-DEPEND="!build? ( $(python_gen_impl_dep 'ssl(+)') ) |
859 |
- >=app-arch/tar-1.27 |
860 |
- dev-lang/python-exec:2 |
861 |
- >=sys-apps/sed-4.0.5 sys-devel/patch |
862 |
- doc? ( app-text/xmlto ~app-text/docbook-xml-dtd-4.4 ) |
863 |
- epydoc? ( >=dev-python/epydoc-2.0[$(python_gen_usedep 'python2*')] )" |
864 |
-# Require sandbox-2.2 for bug #288863. |
865 |
-# For xattr, we can spawn getfattr and setfattr from sys-apps/attr, but that's |
866 |
-# quite slow, so it's not considered in the dependencies as an alternative to |
867 |
-# to python-3.3 / pyxattr. Also, xattr support is only tested with Linux, so |
868 |
-# for now, don't pull in xattr deps for other kernels. |
869 |
-# For whirlpool hash, require python[ssl] (bug #425046). |
870 |
-# For compgen, require bash[readline] (bug #445576). |
871 |
-RDEPEND=" |
872 |
- >=app-arch/tar-1.27 |
873 |
- dev-lang/python-exec:2 |
874 |
- !build? ( |
875 |
- >=sys-apps/sed-4.0.5 |
876 |
- app-shells/bash:0[readline] |
877 |
- >=app-admin/eselect-1.2 |
878 |
- $(python_gen_cond_dep 'dev-python/pyblake2[${PYTHON_USEDEP}]' \ |
879 |
- python{2_7,3_4,3_5} pypy) |
880 |
- ) |
881 |
- elibc_FreeBSD? ( !prefix? ( sys-freebsd/freebsd-bin ) ) |
882 |
- elibc_glibc? ( !prefix? ( >=sys-apps/sandbox-2.2 ) ) |
883 |
- elibc_uclibc? ( !prefix? ( >=sys-apps/sandbox-2.2 ) ) |
884 |
- kernel_linux? ( >=app-misc/pax-utils-0.1.17 ) |
885 |
- kernel_SunOS? ( >=app-misc/pax-utils-0.1.17 ) |
886 |
- kernel_FreeBSD? ( >=app-misc/pax-utils-0.1.17 ) |
887 |
- kernel_Darwin? ( >=app-misc/pax-utils-0.1.18 ) |
888 |
- kernel_AIX? ( >=sys-apps/aix-miscutils-0.1.1634 ) |
889 |
- selinux? ( >=sys-libs/libselinux-2.0.94[python,${PYTHON_USEDEP}] ) |
890 |
- xattr? ( kernel_linux? ( |
891 |
- >=sys-apps/install-xattr-0.3 |
892 |
- $(python_gen_cond_dep 'dev-python/pyxattr[${PYTHON_USEDEP}]' \ |
893 |
- python2_7 pypy) |
894 |
- ) ) |
895 |
- !<app-admin/logrotate-3.8.0" |
896 |
-PDEPEND=" |
897 |
- !build? ( |
898 |
- >=net-misc/rsync-2.6.4 |
899 |
- userland_GNU? ( >=sys-apps/coreutils-6.4 ) |
900 |
- )" |
901 |
-# coreutils-6.4 rdep is for date format in emerge-webrsync #164532 |
902 |
-# NOTE: FEATURES=installsources requires debugedit and rsync |
903 |
- |
904 |
-REQUIRED_USE="epydoc? ( $(python_gen_useflags 'python2*') )" |
905 |
- |
906 |
-SRC_ARCHIVES="https://dev.gentoo.org/~zmedico/portage/archives https://dev.gentoo.org/~grobian/distfiles" |
907 |
- |
908 |
-prefix_src_archives() { |
909 |
- local x y |
910 |
- for x in ${@}; do |
911 |
- for y in ${SRC_ARCHIVES}; do |
912 |
- echo ${y}/${x} |
913 |
- done |
914 |
- done |
915 |
-} |
916 |
- |
917 |
-TARBALL_PV=${PV} |
918 |
-SRC_URI="mirror://gentoo/prefix-${PN}-${TARBALL_PV}.tar.bz2 |
919 |
- $(prefix_src_archives prefix-${PN}-${TARBALL_PV}.tar.bz2)" |
920 |
- |
921 |
-S="${WORKDIR}"/prefix-${PN}-${TARBALL_PV} |
922 |
- |
923 |
-pkg_setup() { |
924 |
- use epydoc && DISTUTILS_ALL_SUBPHASE_IMPLS=( python2.7 ) |
925 |
-} |
926 |
- |
927 |
-python_prepare_all() { |
928 |
- distutils-r1_python_prepare_all |
929 |
- |
930 |
- epatch "${FILESDIR}"/${PN}-2.3.40-ebuildshell.patch # 155161 |
931 |
- use prefix-chaining && # maybe useful even with stacked-prefix |
932 |
- epatch "${FILESDIR}"/${PN}-2.3.40-prefix-chaining.patch |
933 |
- |
934 |
- if use native-extensions; then |
935 |
- printf "[build_ext]\nportage-ext-modules=true\n" >> \ |
936 |
- setup.cfg || die |
937 |
- fi |
938 |
- |
939 |
- if ! use ipc ; then |
940 |
- einfo "Disabling ipc..." |
941 |
- sed -e "s:_enable_ipc_daemon = True:_enable_ipc_daemon = False:" \ |
942 |
- -i pym/_emerge/AbstractEbuildProcess.py || \ |
943 |
- die "failed to patch AbstractEbuildProcess.py" |
944 |
- fi |
945 |
- |
946 |
- if use xattr && use kernel_linux ; then |
947 |
- einfo "Adding FEATURES=xattr to make.globals ..." |
948 |
- echo -e '\nFEATURES="${FEATURES} xattr"' >> cnf/make.globals \ |
949 |
- || die "failed to append to make.globals" |
950 |
- fi |
951 |
- |
952 |
- if [[ -n ${EPREFIX} ]] ; then |
953 |
- # PREFIX LOCAL: only hack const_autotool |
954 |
- local extrapath="/usr/sbin:/usr/bin:/sbin:/bin" |
955 |
- # ok, we can't rely on PORTAGE_ROOT_USER being there yet, as people |
956 |
- # tend not to update that often, as long as we are a separate ebuild |
957 |
- # we can assume when unset, it's time for some older trick |
958 |
- if [[ -z ${PORTAGE_ROOT_USER} ]] ; then |
959 |
- PORTAGE_ROOT_USER=$(python -c 'from portage.const import rootuser; print rootuser') |
960 |
- fi |
961 |
- local defaultpath="${EPREFIX}/usr/sbin:${EPREFIX}/usr/bin:${EPREFIX}/sbin:${EPREFIX}/bin" |
962 |
- # We need to probe for bash in the Prefix, because it may not |
963 |
- # exist, in which case we fall back to the currently in use |
964 |
- # bash. This logic is necessary in particular during bootstrap, |
965 |
- # where we pull ourselves out of a temporary place with tools |
966 |
- local bash="${EPREFIX}/bin/bash" |
967 |
- [[ ! -x ${bash} ]] && bash=${BASH} |
968 |
- |
969 |
- einfo "Adjusting sources for ${EPREFIX}" |
970 |
- find . -type f -exec \ |
971 |
- sed -e "s|@PORTAGE_EPREFIX@|${EPREFIX}|" \ |
972 |
- -e "s|@PORTAGE_MV@|$(type -P mv)|" \ |
973 |
- -e "s|@PORTAGE_BASH@|${bash}|" \ |
974 |
- -e "s|@PREFIX_PORTAGE_PYTHON@|$(type -P python)|" \ |
975 |
- -e "s|@DEFAULT_PATH@|${defaultpath}|" \ |
976 |
- -e "s|@EXTRA_PATH@|${extrapath}|" \ |
977 |
- -e "s|@portagegroup@|${PORTAGE_GROUP:-portage}|" \ |
978 |
- -e "s|@portageuser@|${PORTAGE_USER:-portage}|" \ |
979 |
- -e "s|@rootuser@|${PORTAGE_ROOT_USER:-root}|" \ |
980 |
- -e "s|@rootuid@|$(id -u ${PORTAGE_ROOT_USER:-root})|" \ |
981 |
- -e "s|@rootgid@|$(id -g ${PORTAGE_ROOT_USER:-root})|" \ |
982 |
- -e "s|@sysconfdir@|${EPREFIX}/etc|" \ |
983 |
- -i '{}' + || \ |
984 |
- die "Failed to patch sources" |
985 |
- # We don't need the below, since setup.py deals with this (and |
986 |
- # more) so we don't have to make this correct |
987 |
- # -e "s|@PORTAGE_BASE@|${EPREFIX}/usr/lib/portage/${EPYTHON}|" \ |
988 |
- |
989 |
- # remove Makefiles, or else they will get installed |
990 |
- find . -name "Makefile.*" -delete |
991 |
- |
992 |
- einfo "Prefixing shebangs ..." |
993 |
- while read -r -d $'\0' ; do |
994 |
- local shebang=$(head -n1 "$REPLY") |
995 |
- if [[ ${shebang} == "#!"* && ! ${shebang} == "#!${EPREFIX}/"* ]] ; then |
996 |
- sed -i -e "1s:.*:#!${EPREFIX}${shebang:2}:" "$REPLY" || \ |
997 |
- die "sed failed" |
998 |
- fi |
999 |
- done < <(find . -type f -print0) |
1000 |
- |
1001 |
- einfo "Setting gentoo_prefix as reponame for emerge-webrsync" |
1002 |
- sed -i -e 's/repo_name=gentoo/repo_name=gentoo_prefix/' \ |
1003 |
- bin/emerge-webrsync || die |
1004 |
- |
1005 |
- einfo "Making absent gemato non-fatal" |
1006 |
- sed -i -e '/exitcode = 127/d' \ |
1007 |
- pym/portage/sync/modules/rsync/rsync.py || die |
1008 |
- |
1009 |
- if [[ ${CHOST} == powerpc*-darwin* ]] ; then |
1010 |
- # asyncio triggers some python bug, not worth fixing on |
1011 |
- # ppc-macos, bug #656830 |
1012 |
- sed -i -e '/^_asyncio_enabled/s/=.*$/= False/' \ |
1013 |
- pym/portage/util/_eventloop/global_event_loop.py || die |
1014 |
- fi |
1015 |
- # END PREFIX LOCAL |
1016 |
- fi |
1017 |
- |
1018 |
- # PREFIX LOCAL: make.conf is written by bootstrap-prefix.sh |
1019 |
- if use !prefix ; then |
1020 |
- cd "${S}/cnf" || die |
1021 |
- if [ -f "make.conf.example.${ARCH}".diff ]; then |
1022 |
- patch make.conf.example "make.conf.example.${ARCH}".diff || \ |
1023 |
- die "Failed to patch make.conf.example" |
1024 |
- else |
1025 |
- eerror "" |
1026 |
- eerror "Portage does not have an arch-specific configuration for this arch." |
1027 |
- eerror "Please notify the arch maintainer about this issue. Using generic." |
1028 |
- eerror "" |
1029 |
- fi |
1030 |
- fi |
1031 |
-} |
1032 |
- |
1033 |
-python_compile_all() { |
1034 |
- local targets=() |
1035 |
- use doc && targets+=( docbook ) |
1036 |
- use epydoc && targets+=( epydoc ) |
1037 |
- |
1038 |
- if [[ ${targets[@]} ]]; then |
1039 |
- esetup.py "${targets[@]}" |
1040 |
- fi |
1041 |
-} |
1042 |
- |
1043 |
-python_test() { |
1044 |
- esetup.py test |
1045 |
-} |
1046 |
- |
1047 |
-python_install() { |
1048 |
- # Install sbin scripts to bindir for python-exec linking |
1049 |
- # they will be relocated in pkg_preinst() |
1050 |
- distutils-r1_python_install \ |
1051 |
- --system-prefix="${EPREFIX}/usr" \ |
1052 |
- --bindir="$(python_get_scriptdir)" \ |
1053 |
- --docdir="${EPREFIX}/usr/share/doc/${PF}" \ |
1054 |
- --htmldir="${EPREFIX}/usr/share/doc/${PF}/html" \ |
1055 |
- --portage-bindir="${EPREFIX}/usr/lib/portage/${EPYTHON}" \ |
1056 |
- --sbindir="$(python_get_scriptdir)" \ |
1057 |
- --sysconfdir="${EPREFIX}/etc" \ |
1058 |
- "${@}" |
1059 |
-} |
1060 |
- |
1061 |
-python_install_all() { |
1062 |
- distutils-r1_python_install_all |
1063 |
- |
1064 |
- local targets=() |
1065 |
- use doc && targets+=( |
1066 |
- install_docbook |
1067 |
- --htmldir="${EPREFIX}/usr/share/doc/${PF}/html" |
1068 |
- ) |
1069 |
- use epydoc && targets+=( |
1070 |
- install_epydoc |
1071 |
- --htmldir="${EPREFIX}/usr/share/doc/${PF}/html" |
1072 |
- ) |
1073 |
- |
1074 |
- # install docs |
1075 |
- if [[ ${targets[@]} ]]; then |
1076 |
- esetup.py "${targets[@]}" |
1077 |
- fi |
1078 |
- |
1079 |
- # Due to distutils/python-exec limitations |
1080 |
- # these must be installed to /usr/bin. |
1081 |
- local sbin_relocations='archive-conf dispatch-conf emaint env-update etc-update fixpackages regenworld' |
1082 |
- einfo "Moving admin scripts to the correct directory" |
1083 |
- dodir /usr/sbin |
1084 |
- for target in ${sbin_relocations}; do |
1085 |
- einfo "Moving /usr/bin/${target} to /usr/sbin/${target}" |
1086 |
- mv "${ED}usr/bin/${target}" "${ED}usr/sbin/${target}" || die "sbin scripts move failed!" |
1087 |
- done |
1088 |
-} |
1089 |
- |
1090 |
-pkg_preinst() { |
1091 |
- # comment out sanity test until it is fixed to work |
1092 |
- # with the new PORTAGE_PYM_PATH |
1093 |
- #if [[ $ROOT == / ]] ; then |
1094 |
- ## Run some minimal tests as a sanity check. |
1095 |
- #local test_runner=$(find "${ED}" -name runTests) |
1096 |
- #if [[ -n $test_runner && -x $test_runner ]] ; then |
1097 |
- #einfo "Running preinst sanity tests..." |
1098 |
- #"$test_runner" || die "preinst sanity tests failed" |
1099 |
- #fi |
1100 |
- #fi |
1101 |
- |
1102 |
- # elog dir must exist to avoid logrotate error for bug #415911. |
1103 |
- # This code runs in preinst in order to bypass the mapping of |
1104 |
- # portage:portage to root:root which happens after src_install. |
1105 |
- keepdir /var/log/portage/elog |
1106 |
- # This is allowed to fail if the user/group are invalid for prefix users. |
1107 |
- if chown ${PORTAGE_USER}:${PORTAGE_GROUP} "${ED}"var/log/portage{,/elog} 2>/dev/null ; then |
1108 |
- chmod g+s,ug+rwx "${ED}"var/log/portage{,/elog} |
1109 |
- fi |
1110 |
-} |
1111 |
|
1112 |
diff --git a/sys-apps/portage/portage-2.3.45.ebuild b/sys-apps/portage/portage-2.3.45.ebuild |
1113 |
deleted file mode 100644 |
1114 |
index ee4c5d27f7..0000000000 |
1115 |
--- a/sys-apps/portage/portage-2.3.45.ebuild |
1116 |
+++ /dev/null |
1117 |
@@ -1,274 +0,0 @@ |
1118 |
-# Copyright 1999-2018 Gentoo Authors |
1119 |
-# Distributed under the terms of the GNU General Public License v2 |
1120 |
- |
1121 |
-EAPI=5 |
1122 |
- |
1123 |
-PYTHON_COMPAT=( |
1124 |
- pypy |
1125 |
- python3_4 python3_5 python3_6 python3_7 |
1126 |
- python2_7 |
1127 |
-) |
1128 |
-PYTHON_REQ_USE='bzip2(+),threads(+)' |
1129 |
- |
1130 |
-inherit eutils distutils-r1 multilib |
1131 |
- |
1132 |
-DESCRIPTION="Portage package manager used in Gentoo Prefix" |
1133 |
-HOMEPAGE="https://wiki.gentoo.org/wiki/Project:Portage" |
1134 |
-LICENSE="GPL-2" |
1135 |
-KEYWORDS="~ppc-aix ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" |
1136 |
-SLOT="0" |
1137 |
-IUSE="build doc epydoc +ipc +native-extensions selinux xattr prefix-chaining" |
1138 |
- |
1139 |
-DEPEND="!build? ( $(python_gen_impl_dep 'ssl(+)') ) |
1140 |
- >=app-arch/tar-1.27 |
1141 |
- dev-lang/python-exec:2 |
1142 |
- >=sys-apps/sed-4.0.5 sys-devel/patch |
1143 |
- doc? ( app-text/xmlto ~app-text/docbook-xml-dtd-4.4 ) |
1144 |
- epydoc? ( >=dev-python/epydoc-2.0[$(python_gen_usedep 'python2*')] )" |
1145 |
-# Require sandbox-2.2 for bug #288863. |
1146 |
-# For xattr, we can spawn getfattr and setfattr from sys-apps/attr, but that's |
1147 |
-# quite slow, so it's not considered in the dependencies as an alternative to |
1148 |
-# to python-3.3 / pyxattr. Also, xattr support is only tested with Linux, so |
1149 |
-# for now, don't pull in xattr deps for other kernels. |
1150 |
-# For whirlpool hash, require python[ssl] (bug #425046). |
1151 |
-# For compgen, require bash[readline] (bug #445576). |
1152 |
-RDEPEND=" |
1153 |
- >=app-arch/tar-1.27 |
1154 |
- dev-lang/python-exec:2 |
1155 |
- !build? ( |
1156 |
- >=sys-apps/sed-4.0.5 |
1157 |
- app-shells/bash:0[readline] |
1158 |
- >=app-admin/eselect-1.2 |
1159 |
- $(python_gen_cond_dep 'dev-python/pyblake2[${PYTHON_USEDEP}]' \ |
1160 |
- python{2_7,3_4,3_5} pypy) |
1161 |
- ) |
1162 |
- elibc_FreeBSD? ( !prefix? ( sys-freebsd/freebsd-bin ) ) |
1163 |
- elibc_glibc? ( !prefix? ( >=sys-apps/sandbox-2.2 ) ) |
1164 |
- elibc_uclibc? ( !prefix? ( >=sys-apps/sandbox-2.2 ) ) |
1165 |
- kernel_linux? ( >=app-misc/pax-utils-0.1.17 ) |
1166 |
- kernel_SunOS? ( >=app-misc/pax-utils-0.1.17 ) |
1167 |
- kernel_FreeBSD? ( >=app-misc/pax-utils-0.1.17 ) |
1168 |
- kernel_Darwin? ( >=app-misc/pax-utils-0.1.18 ) |
1169 |
- kernel_AIX? ( >=sys-apps/aix-miscutils-0.1.1634 ) |
1170 |
- selinux? ( >=sys-libs/libselinux-2.0.94[python,${PYTHON_USEDEP}] ) |
1171 |
- xattr? ( kernel_linux? ( |
1172 |
- >=sys-apps/install-xattr-0.3 |
1173 |
- $(python_gen_cond_dep 'dev-python/pyxattr[${PYTHON_USEDEP}]' \ |
1174 |
- python2_7 pypy) |
1175 |
- ) ) |
1176 |
- !<app-admin/logrotate-3.8.0" |
1177 |
-PDEPEND=" |
1178 |
- !build? ( |
1179 |
- >=net-misc/rsync-2.6.4 |
1180 |
- userland_GNU? ( >=sys-apps/coreutils-6.4 ) |
1181 |
- )" |
1182 |
-# coreutils-6.4 rdep is for date format in emerge-webrsync #164532 |
1183 |
-# NOTE: FEATURES=installsources requires debugedit and rsync |
1184 |
- |
1185 |
-REQUIRED_USE="epydoc? ( $(python_gen_useflags 'python2*') )" |
1186 |
- |
1187 |
-SRC_ARCHIVES="https://dev.gentoo.org/~zmedico/portage/archives https://dev.gentoo.org/~grobian/distfiles" |
1188 |
- |
1189 |
-prefix_src_archives() { |
1190 |
- local x y |
1191 |
- for x in ${@}; do |
1192 |
- for y in ${SRC_ARCHIVES}; do |
1193 |
- echo ${y}/${x} |
1194 |
- done |
1195 |
- done |
1196 |
-} |
1197 |
- |
1198 |
-TARBALL_PV=${PV} |
1199 |
-SRC_URI="mirror://gentoo/prefix-${PN}-${TARBALL_PV}.tar.bz2 |
1200 |
- $(prefix_src_archives prefix-${PN}-${TARBALL_PV}.tar.bz2)" |
1201 |
- |
1202 |
-S="${WORKDIR}"/prefix-${PN}-${TARBALL_PV} |
1203 |
- |
1204 |
-pkg_setup() { |
1205 |
- use epydoc && DISTUTILS_ALL_SUBPHASE_IMPLS=( python2.7 ) |
1206 |
-} |
1207 |
- |
1208 |
-python_prepare_all() { |
1209 |
- distutils-r1_python_prepare_all |
1210 |
- |
1211 |
- epatch "${FILESDIR}"/${PN}-2.3.45-ebuildshell.patch # 155161 |
1212 |
- use prefix-chaining && # maybe useful even with stacked-prefix |
1213 |
- epatch "${FILESDIR}"/${PN}-2.3.40-prefix-chaining.patch |
1214 |
- |
1215 |
- if use native-extensions; then |
1216 |
- printf "[build_ext]\nportage-ext-modules=true\n" >> \ |
1217 |
- setup.cfg || die |
1218 |
- fi |
1219 |
- |
1220 |
- if ! use ipc ; then |
1221 |
- einfo "Disabling ipc..." |
1222 |
- sed -e "s:_enable_ipc_daemon = True:_enable_ipc_daemon = False:" \ |
1223 |
- -i lib/_emerge/AbstractEbuildProcess.py || \ |
1224 |
- die "failed to patch AbstractEbuildProcess.py" |
1225 |
- fi |
1226 |
- |
1227 |
- if use xattr && use kernel_linux ; then |
1228 |
- einfo "Adding FEATURES=xattr to make.globals ..." |
1229 |
- echo -e '\nFEATURES="${FEATURES} xattr"' >> cnf/make.globals \ |
1230 |
- || die "failed to append to make.globals" |
1231 |
- fi |
1232 |
- |
1233 |
- if [[ -n ${EPREFIX} ]] ; then |
1234 |
- # PREFIX LOCAL: only hack const_autotool |
1235 |
- local extrapath="/usr/sbin:/usr/bin:/sbin:/bin" |
1236 |
- # ok, we can't rely on PORTAGE_ROOT_USER being there yet, as people |
1237 |
- # tend not to update that often, as long as we are a separate ebuild |
1238 |
- # we can assume when unset, it's time for some older trick |
1239 |
- if [[ -z ${PORTAGE_ROOT_USER} ]] ; then |
1240 |
- PORTAGE_ROOT_USER=$(python -c 'from portage.const import rootuser; print rootuser') |
1241 |
- fi |
1242 |
- local defaultpath="${EPREFIX}/usr/sbin:${EPREFIX}/usr/bin:${EPREFIX}/sbin:${EPREFIX}/bin" |
1243 |
- # We need to probe for bash in the Prefix, because it may not |
1244 |
- # exist, in which case we fall back to the currently in use |
1245 |
- # bash. This logic is necessary in particular during bootstrap, |
1246 |
- # where we pull ourselves out of a temporary place with tools |
1247 |
- local bash="${EPREFIX}/bin/bash" |
1248 |
- [[ ! -x ${bash} ]] && bash=${BASH} |
1249 |
- |
1250 |
- einfo "Adjusting sources for ${EPREFIX}" |
1251 |
- find . -type f -exec \ |
1252 |
- sed -e "s|@PORTAGE_EPREFIX@|${EPREFIX}|" \ |
1253 |
- -e "s|@PORTAGE_MV@|$(type -P mv)|" \ |
1254 |
- -e "s|@PORTAGE_BASH@|${bash}|" \ |
1255 |
- -e "s|@PREFIX_PORTAGE_PYTHON@|$(type -P python)|" \ |
1256 |
- -e "s|@DEFAULT_PATH@|${defaultpath}|" \ |
1257 |
- -e "s|@EXTRA_PATH@|${extrapath}|" \ |
1258 |
- -e "s|@portagegroup@|${PORTAGE_GROUP:-portage}|" \ |
1259 |
- -e "s|@portageuser@|${PORTAGE_USER:-portage}|" \ |
1260 |
- -e "s|@rootuser@|${PORTAGE_ROOT_USER:-root}|" \ |
1261 |
- -e "s|@rootuid@|$(id -u ${PORTAGE_ROOT_USER:-root})|" \ |
1262 |
- -e "s|@rootgid@|$(id -g ${PORTAGE_ROOT_USER:-root})|" \ |
1263 |
- -e "s|@sysconfdir@|${EPREFIX}/etc|" \ |
1264 |
- -i '{}' + || \ |
1265 |
- die "Failed to patch sources" |
1266 |
- # We don't need the below, since setup.py deals with this (and |
1267 |
- # more) so we don't have to make this correct |
1268 |
- # -e "s|@PORTAGE_BASE@|${EPREFIX}/usr/lib/portage/${EPYTHON}|" \ |
1269 |
- |
1270 |
- # remove Makefiles, or else they will get installed |
1271 |
- find . -name "Makefile.*" -delete |
1272 |
- |
1273 |
- einfo "Prefixing shebangs ..." |
1274 |
- while read -r -d $'\0' ; do |
1275 |
- local shebang=$(head -n1 "$REPLY") |
1276 |
- if [[ ${shebang} == "#!"* && ! ${shebang} == "#!${EPREFIX}/"* ]] ; then |
1277 |
- sed -i -e "1s:.*:#!${EPREFIX}${shebang:2}:" "$REPLY" || \ |
1278 |
- die "sed failed" |
1279 |
- fi |
1280 |
- done < <(find . -type f -print0) |
1281 |
- |
1282 |
- einfo "Setting gentoo_prefix as reponame for emerge-webrsync" |
1283 |
- sed -i -e 's/repo_name=gentoo/repo_name=gentoo_prefix/' \ |
1284 |
- bin/emerge-webrsync || die |
1285 |
- |
1286 |
- einfo "Making absent gemato non-fatal" |
1287 |
- sed -i -e '/exitcode = 127/d' \ |
1288 |
- lib/portage/sync/modules/rsync/rsync.py || die |
1289 |
- |
1290 |
- if [[ ${CHOST} == powerpc*-darwin* ]] ; then |
1291 |
- # asyncio triggers some python bug, not worth fixing on |
1292 |
- # ppc-macos, bug #656830 |
1293 |
- sed -i -e '/^_asyncio_enabled/s/=.*$/= False/' \ |
1294 |
- lib/portage/util/_eventloop/global_event_loop.py || die |
1295 |
- fi |
1296 |
- # END PREFIX LOCAL |
1297 |
- fi |
1298 |
- |
1299 |
- # PREFIX LOCAL: make.conf is written by bootstrap-prefix.sh |
1300 |
- if use !prefix ; then |
1301 |
- cd "${S}/cnf" || die |
1302 |
- if [ -f "make.conf.example.${ARCH}".diff ]; then |
1303 |
- patch make.conf.example "make.conf.example.${ARCH}".diff || \ |
1304 |
- die "Failed to patch make.conf.example" |
1305 |
- else |
1306 |
- eerror "" |
1307 |
- eerror "Portage does not have an arch-specific configuration for this arch." |
1308 |
- eerror "Please notify the arch maintainer about this issue. Using generic." |
1309 |
- eerror "" |
1310 |
- fi |
1311 |
- fi |
1312 |
-} |
1313 |
- |
1314 |
-python_compile_all() { |
1315 |
- local targets=() |
1316 |
- use doc && targets+=( docbook ) |
1317 |
- use epydoc && targets+=( epydoc ) |
1318 |
- |
1319 |
- if [[ ${targets[@]} ]]; then |
1320 |
- esetup.py "${targets[@]}" |
1321 |
- fi |
1322 |
-} |
1323 |
- |
1324 |
-python_test() { |
1325 |
- esetup.py test |
1326 |
-} |
1327 |
- |
1328 |
-python_install() { |
1329 |
- # Install sbin scripts to bindir for python-exec linking |
1330 |
- # they will be relocated in pkg_preinst() |
1331 |
- distutils-r1_python_install \ |
1332 |
- --system-prefix="${EPREFIX}/usr" \ |
1333 |
- --bindir="$(python_get_scriptdir)" \ |
1334 |
- --docdir="${EPREFIX}/usr/share/doc/${PF}" \ |
1335 |
- --htmldir="${EPREFIX}/usr/share/doc/${PF}/html" \ |
1336 |
- --portage-bindir="${EPREFIX}/usr/lib/portage/${EPYTHON}" \ |
1337 |
- --sbindir="$(python_get_scriptdir)" \ |
1338 |
- --sysconfdir="${EPREFIX}/etc" \ |
1339 |
- "${@}" |
1340 |
-} |
1341 |
- |
1342 |
-python_install_all() { |
1343 |
- distutils-r1_python_install_all |
1344 |
- |
1345 |
- local targets=() |
1346 |
- use doc && targets+=( |
1347 |
- install_docbook |
1348 |
- --htmldir="${EPREFIX}/usr/share/doc/${PF}/html" |
1349 |
- ) |
1350 |
- use epydoc && targets+=( |
1351 |
- install_epydoc |
1352 |
- --htmldir="${EPREFIX}/usr/share/doc/${PF}/html" |
1353 |
- ) |
1354 |
- |
1355 |
- # install docs |
1356 |
- if [[ ${targets[@]} ]]; then |
1357 |
- esetup.py "${targets[@]}" |
1358 |
- fi |
1359 |
- |
1360 |
- # Due to distutils/python-exec limitations |
1361 |
- # these must be installed to /usr/bin. |
1362 |
- local sbin_relocations='archive-conf dispatch-conf emaint env-update etc-update fixpackages regenworld' |
1363 |
- einfo "Moving admin scripts to the correct directory" |
1364 |
- dodir /usr/sbin |
1365 |
- for target in ${sbin_relocations}; do |
1366 |
- einfo "Moving /usr/bin/${target} to /usr/sbin/${target}" |
1367 |
- mv "${ED}usr/bin/${target}" "${ED}usr/sbin/${target}" || die "sbin scripts move failed!" |
1368 |
- done |
1369 |
-} |
1370 |
- |
1371 |
-pkg_preinst() { |
1372 |
- # comment out sanity test until it is fixed to work |
1373 |
- # with the new PORTAGE_PYM_PATH |
1374 |
- #if [[ $ROOT == / ]] ; then |
1375 |
- ## Run some minimal tests as a sanity check. |
1376 |
- #local test_runner=$(find "${ED}" -name runTests) |
1377 |
- #if [[ -n $test_runner && -x $test_runner ]] ; then |
1378 |
- #einfo "Running preinst sanity tests..." |
1379 |
- #"$test_runner" || die "preinst sanity tests failed" |
1380 |
- #fi |
1381 |
- #fi |
1382 |
- |
1383 |
- # elog dir must exist to avoid logrotate error for bug #415911. |
1384 |
- # This code runs in preinst in order to bypass the mapping of |
1385 |
- # portage:portage to root:root which happens after src_install. |
1386 |
- keepdir /var/log/portage/elog |
1387 |
- # This is allowed to fail if the user/group are invalid for prefix users. |
1388 |
- if chown ${PORTAGE_USER}:${PORTAGE_GROUP} "${ED}"var/log/portage{,/elog} 2>/dev/null ; then |
1389 |
- chmod g+s,ug+rwx "${ED}"var/log/portage{,/elog} |
1390 |
- fi |
1391 |
-} |