summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2012-12-11 22:03:05 +0000
committerZac Medico <zmedico@gentoo.org>2012-12-11 22:03:05 +0000
commit548b2fce57e614704c54bead5093c30545add903 (patch)
tree2381c031e1de6c62927c3b86afe45177115d0559
parentUse the udev_dorules function from udev.eclass (diff)
downloadhistorical-548b2fce57e614704c54bead5093c30545add903.tar.gz
historical-548b2fce57e614704c54bead5093c30545add903.tar.bz2
historical-548b2fce57e614704c54bead5093c30545add903.zip
2.1.11.37 version bump. This fixes bug #446136 (duplicate elog messages),
bug #446774 (regression triggers die during strip), and bug #446420 (preserve xattrs for stripped binaries) Bug #445274 tracks all bugs fixed since portage-2.1.11.31. Package-Manager: portage-2.2.0_alpha148/cvs/Linux i686 Manifest-Sign-Key: 0xFDE8EF85AE5719A3
-rw-r--r--sys-apps/portage/ChangeLog10
-rw-r--r--sys-apps/portage/Manifest10
-rw-r--r--sys-apps/portage/portage-2.1.11.37.ebuild287
3 files changed, 302 insertions, 5 deletions
diff --git a/sys-apps/portage/ChangeLog b/sys-apps/portage/ChangeLog
index 9790f73c0d9d..e7829da26539 100644
--- a/sys-apps/portage/ChangeLog
+++ b/sys-apps/portage/ChangeLog
@@ -1,6 +1,14 @@
# ChangeLog for sys-apps/portage
# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sys-apps/portage/ChangeLog,v 1.1150 2012/12/11 19:24:00 armin76 Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-apps/portage/ChangeLog,v 1.1151 2012/12/11 22:03:02 zmedico Exp $
+
+*portage-2.1.11.37 (11 Dec 2012)
+
+ 11 Dec 2012; Zac Medico <zmedico@gentoo.org> +portage-2.1.11.37.ebuild:
+ 2.1.11.37 version bump. This fixes bug #446136 (duplicate elog messages), bug
+ #446774 (regression triggers die during strip), and bug #446420 (preserve
+ xattrs for stripped binaries) Bug #445274 tracks all bugs fixed since
+ portage-2.1.11.31.
11 Dec 2012; Raúl Porcel <armin76@gentoo.org> portage-2.1.11.31.ebuild:
alpha/ia64/m68k/s390/sh/sparc stable wrt #440852
diff --git a/sys-apps/portage/Manifest b/sys-apps/portage/Manifest
index e0806ff48a80..ace130dc6118 100644
--- a/sys-apps/portage/Manifest
+++ b/sys-apps/portage/Manifest
@@ -5,6 +5,7 @@ AUX README.RESCUE 137 SHA256 69bea0c755eab59b6b4d90838b8551744f0b0c8eeac170b1cd1
DIST portage-2.1.11.31.tar.bz2 848585 SHA256 3013e9ba1fc3f87a5fedff8e5a1d2b36d6a9e06538fdebee6ab7b4cf61d273ce SHA512 12222ecb8e3f3b239c7616568475d87f2ef705b83cb72311c0d70df49c7eef1f1bb4e898afb6f17023b40077a80f9ae26129aef0a52f9f16e22140e5ea8d8522 WHIRLPOOL b3d3b0fc90476c6bd6c41a1dea17999ca21598db547c8e691fdd378e9bbacb991954f03378a033755008d7bc27d15b2505f62e6408ec914e840ead4edc0a5c9a
DIST portage-2.1.11.33.tar.bz2 858457 SHA256 4ac573855730a5955e1cdfd45fd380464f99b1f9a59a1bf2618813bf74fe82e3 SHA512 44a858e67290dddb59edebf9ad42e0fc1a82b34bbdbb0861f614a94f4ec499631f4c462aec14cf3e1eb62ecaedfd65d732b95f46e1496d1300a91d7aa002db29 WHIRLPOOL 8843922e85422e4eed4e83eebca16c60cd217df5957c558a576d18c307349649ebddb059f46b7e7277ad46e28d575ae947a40149457dec09add57c3144c98a23
DIST portage-2.1.11.36.tar.bz2 859202 SHA256 46b8f0df3b8123b7c4b2262ae4c3f5b81585ba2e29fc6a16b478d05c5593e675 SHA512 9746812922db46405389f0e1a2e0d2d23b17f59af8121b894ea3955a81b6ee686bfee8f9861a0f81a4f157fa4b831e95060a26c4075d45f4931858ee1905fc4d WHIRLPOOL ec2b862b15960cf06615820eb160864913bdf8833a23c1b63949af5f7130ebc161ad6ce5bb15b0181c2b1c3a7f12d08bf51dd325a3690bc6af9a129207406af4
+DIST portage-2.1.11.37.tar.bz2 861499 SHA256 eafb5be7c9bf8c05bfef0d317c835047fc4015e007196112c1ab927bbe755ccd SHA512 f76a29d14fa6a649493368486a0cbad6098c2baefc9a8a4f665e267a30a6d866169ad1d4aa3ecf90a00fe3eef5aaad334583f1d929ceff749c7ae3bdf49c7ea2 WHIRLPOOL 5abec26bf88e568238c8338ee92b3130753feb7276931c5ae8d8182d411f90f9f6e8bd30eefe13717f21ce22996de68becee4b4c310e65534acf6020df5a5e5c
DIST portage-2.1.11.9.tar.bz2 844344 SHA256 590ecdae12581e0ead0eca6e4b8e0ca6bc5f1ecaafb98a5d3b684db5b1af7a05 SHA512 64919b833a719f6f1de5bc3ec8a921dd5fca75ea8c4535ce21faa608ff2bf811632ef627845e9b050fcd1ebf56f5792c7bd471925e75c1264d01277979d704a8 WHIRLPOOL d325c2b5ec50cde40f4b2ce127728b3712321febef58897b3141287776424610bd12701c159f15c5cec41f2eb35569e302a5692045406205e833f8e4cfd3d9fd
DIST portage-2.1.6.7.patch.bz2 50118 SHA256 5f0605b51a24d23703330b040d2f7154322284db3e0cefa7499002ff1fa733c0 SHA512 dd2acc1d436cad77cfc83c4dec79316763c1fb88d61b7702e8e47e6f31b2b9fe49e8a4cf4a947614a2acd6db2ef080ed8b4ae5fce9d9be29d7e218a0ec1576c0 WHIRLPOOL 050f923249fde7c4774a2a8a944889e4270a89b00441f1923c01ab0be38f107503e018d7ab7a7f42615e7e375f0f6c0eb3bdbf3ff4ce1ce226957238a729b1ee
DIST portage-2.1.6.7_p1.patch.bz2 4741 SHA256 ddaae2ad8c01e6477bfe22e23a4da57eb9d079a27a17a08385d56fe2c49eec30 SHA512 39058d815827b340787d813515ed4fb8c52c4fb0caa12ae70c8a9a97b9ba16c2bf4177190cb7d1c508055ce8a7aaa390ba9b31642c7d74bfb4a14d729e720617 WHIRLPOOL 8eab9574ed2e6cabac593d93f8b6ff71465c01376e7eec4cf357c336b5ed3d4f3fb3521991148ba4e34ba00c56bec5534c98311167c03866812277a8d88b0494
@@ -16,18 +17,19 @@ DIST portage-man-pl-2.1.2.tar.bz2 53893 SHA256 960eaa7c6f3a2af44bdc665266a8e8846
EBUILD portage-2.1.11.31.ebuild 9906 SHA256 c3a41de56a8ddff0cdf98b3e42c1bef82b78c055a72ef24dfdaf16a23402ffed SHA512 0a1a545dd57cb5c1845969703a18a7ef53b26bcf88236131ad80e1b94cd4a3eb58a6b47d1b6597149788d7a0a2b9477f74b05433861eacb576d1e3db4382998e WHIRLPOOL bd9a44ed54c79b3a3f8188779829fb9063c2df88867e8cb737676d68da10f78c9f77f482b58268fd5c470b255cca91322c4e6ad189cef720e0fdfd5bc9855f35
EBUILD portage-2.1.11.33.ebuild 9918 SHA256 b4396d7b09c36507478306390bcd70542ac3d58635cd95b0f78e5e351912ca15 SHA512 504a44a1919dc420fd28069c6b23bf20ab7d2b458ed43ec6c6c15f6dd71eb9a27039e08df89b256804fd8b9a04eda733e0266ec7fd9e63d9263f6728a5161977 WHIRLPOOL e41fa3b41b0d83cf1d4d9f3552483e0813a856fc3fb3f2b16dc29b81bc84246e08bfdb26470297f53b5aaa919157c38e67fb3151975ad0b2f15d9f5c382cd571
EBUILD portage-2.1.11.36.ebuild 9918 SHA256 26062ba6bdd40a1706727af2793586ec7d2054ce6910c2fdf2b7e23bcbeb3c7d SHA512 e8083b607d995101924ed82cf297a96761f59524a8186e88abdf6fd6fc2689894eaa054eb0dbca65157abca46b13e15d3bf3f610d801ad3a5ad55b75e892a162 WHIRLPOOL 2aecb180e2aa338840f3b91cf71837b2b80b966361fe31c8b930892b70a11cb1af6d75a807629af11b3f8f242117dc9d6e1c76d20ae37d107b675cfbfb06da3d
+EBUILD portage-2.1.11.37.ebuild 9918 SHA256 fd88548d64d6def027e20f818fb43abc93134304b2b4c3a3939aafc0d9b0bceb SHA512 a447f10bde2cf21a0413f8d88751f53d712747b677c1a1a99e75196f76d274a735e824f45eb13c9da5f49371f0e2c08f3323e9525477b8f7bfe850c1c206c154 WHIRLPOOL 14ef67ab426d6a04d0a7416a81b89f5642c549172c549237297d159f823da28abffd42f5dcd20dd8489f225e8ad2cfff491ef4f4a0babdf0f90e9e2dc1c14b57
EBUILD portage-2.1.11.9.ebuild 9958 SHA256 24a15073630680cfee90d715de38af74d7fb46b5b19cd327a1c4e8bd89959db2 SHA512 1053fc8d346abcb10f9b2378834fe8cfc43a1d642a2e0373b37b5dcc21fe336718b41a043468600e0d6a329add4065e0d7e990b46d80c6ef3c348ed8a59b5791 WHIRLPOOL 887f2e9fcd0c6778c7dae0172821dddddf32b6b8b9c010d441316f69f6bc2969685936641196f97f8d1cb9fc1a2ad586386f76ffa52916d5872dc337a16e77ec
EBUILD portage-2.1.6.7_p1.ebuild 8392 SHA256 75dfa3bdb1100ca28ba46eb83e34ffc196cb3e57204e7b4f451cfb19a1644e62 SHA512 ac70b4ba9d658c4d79953088b2fdaeed8d0e31986ff7c649272c39a743ddfdf112e44d3f0f8078941c47a06b373002cfcd454100585d5bbaa807a2079b19eb8c WHIRLPOOL 57c26b40de86f3d6969fe66d5b1fd6df55f5478e03c855813ff83b1e485f99d1b34cbf30422b5b60986263cae4d4ee066daaa01c0166a04f53c7bb829fd214e1
EBUILD portage-2.2.0_alpha142.ebuild 12020 SHA256 4e20a45b39950e0b02e8533e82ca983bb5405322d2fa73047c79b588d88201ec SHA512 a18933b44d974b61756ce2dfdbcf27b3d17ffbb12b18e0703e7cc056cdcd4a58af9fa51e6889c47f3e8301cfcb34b71e5f4dfceb43b4f61f4e59780e27e1cd92 WHIRLPOOL 09c3220612a5a37bafdba97cbebb5c0db2ef1bb209d73bf9afd4deac55749e641afe588be91b4b54a990890dc1e7f50644b38956d21a2e78b29a461b8258b072
EBUILD portage-2.2.0_alpha144.ebuild 12020 SHA256 ab6c62645648bb5f352eb53630616f10ac9f06e08ae2dec1e6aa03c2b2dfe467 SHA512 0ce76c18b06dd460ef81da318ed26cac6e41edb114c4c5420d7ff32fa48c28fe438967b008af42c4693178cd370443df141b094037a3cd51757a6762d329a539 WHIRLPOOL ed5fa7ade21b0c90e13a3f0ce94d8b660bbe6588f680a3af0ae76c5bd48edaed52a2fc7465317aaa187848c2904519c336aab030f1eceda350dbd72fafab6bb6
EBUILD portage-2.2.0_alpha147.ebuild 12020 SHA256 04e310260467ca66f3dbb1321c39a5c51d0790f764feb2587d185ad94472e437 SHA512 d43eb53e986c6532d68db87bfce2fe4e5cbef150b2a2ded8894f1d090f04019888a53e14d0602a7d7d11dc163ef0d9a872327195b22432ad59cebbf3e20f2efd WHIRLPOOL 9080fe3a1a3c8b0948072da61e2920569637cd2884939ca65b5cd7956543f7cd444ec7bb3438b3dc79994f71818938e0c35400601e67de98e638d78cae3a2de7
EBUILD portage-9999.ebuild 11270 SHA256 5c685435f2cbc26f345944149580fcc859676c18707c42fd442871c5fd01080c SHA512 c05cd3dbcf05789d6f6cc66122f67813b35e2f1b28ed469aae836f078cbd1d966e9772f5e90e9220121de0214a789049dd1d08f1cccd23d60ef83c80fe7a465f WHIRLPOOL 427a6f5f9926931dbba924f8f5f7a7271ecbbf5c29b5ad23bd59f965b7f378500d844279df9f569aa5cda7298ff37e2967c5596918deff1738e01eb2272df04e
-MISC ChangeLog 132022 SHA256 3abb4f8486d84f50400c69e34d5f00ab0ce16635bb72974ac898a5188e31a6ae SHA512 5715580a05f1730d6c77217222a9a5f10eaba015ffd8ac9aa62438c70cae6ce7a18660b0c02ef91bdfd6937a92373a75dc026a2a225e26c50adfa4b2398f0469 WHIRLPOOL 778f4121c32463baeac8d1078bb922284e81a7deac661332806a452235aa8f1c51e3f9a15e8797bc9bfd9d1607267e23683801fcc397977c68c94c318fc695a4
+MISC ChangeLog 132380 SHA256 70f62c7f532faa95e11b265a5bf06831cbf23f6885d3d42bf02201a8d0906988 SHA512 cbb0b9d9b32af7e6a417342ec8be9bdbc993023b5da56da65c5dccb99ce647c15ddb8a1ba4cbf1da2fab2763e2e1924bbde5b3009b5b0c6c9a79433aa93f471f WHIRLPOOL 938db8cd06ba582d4c9ac605649d0950df6bede6d9beb5b37373a4d52085c57f0c4914ef7846efdce5093d26110aa4ef1a8486e594f1be457366f171c982d731
MISC metadata.xml 926 SHA256 23463fa1d9a37979e2dffb502fffdd4dcd5dc932f4b5b3053999609012e4fc65 SHA512 41478467f90c58d8044471ed85ad6365e976b8cdb43556f024345861d08f1e9ae2f2fc728d114521adece630793248f2598fa330233eb98ae7b42950cf056d08 WHIRLPOOL 1aff07692c1fbca18cd3498f1cac2e64749b784a3135d881fc4cb95040bdfb93af079df1e053a547cfe08ea4384268e36ec98fc25160ad94e6ef65c6d04e5452
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.19 (GNU/Linux)
-iEYEAREIAAYFAlDHiFEACgkQuQc30/atMkCZcQCZAXQWWecgA6QK4Vo8U0qlSnBq
-5FIAoLWlEKEgAVrjsBRoJ09DaAgplGWj
-=gZSI
+iEYEAREIAAYFAlDHrZoACgkQ/ejvha5XGaOCLQCgxUr+bUxYlJ9UOtYuvOZp/+1/
+zGIAoIfr7V/BePVE8gdwg5aPbEsJs+nA
+=atkN
-----END PGP SIGNATURE-----
diff --git a/sys-apps/portage/portage-2.1.11.37.ebuild b/sys-apps/portage/portage-2.1.11.37.ebuild
new file mode 100644
index 000000000000..f7731fc8b8f2
--- /dev/null
+++ b/sys-apps/portage/portage-2.1.11.37.ebuild
@@ -0,0 +1,287 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sys-apps/portage/portage-2.1.11.37.ebuild,v 1.1 2012/12/11 22:03:02 zmedico Exp $
+
+# Require EAPI 2 since we now require at least python-2.6 (for python 3
+# syntax support) which also requires EAPI 2.
+EAPI=2
+inherit eutils python
+
+DESCRIPTION="Portage is the package management and distribution system for Gentoo"
+HOMEPAGE="http://www.gentoo.org/proj/en/portage/index.xml"
+LICENSE="GPL-2"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~sparc-fbsd ~x86-fbsd"
+SLOT="0"
+IUSE="build doc epydoc +ipc linguas_pl pypy1_9 python2 python3 selinux xattr"
+
+# Import of the io module in python-2.6 raises ImportError for the
+# thread module if threading is disabled.
+python_dep_ssl="python3? ( =dev-lang/python-3*[ssl] )
+ !pypy1_9? ( !python2? ( !python3? (
+ || ( >=dev-lang/python-2.7[ssl] dev-lang/python:2.6[threads,ssl] )
+ ) ) )
+ pypy1_9? ( !python2? ( !python3? ( dev-python/pypy:1.9[bzip2,ssl] ) ) )
+ python2? ( !python3? ( || ( dev-lang/python:2.7[ssl] dev-lang/python:2.6[ssl,threads] ) ) )"
+python_dep="${python_dep_ssl//\[ssl\]}"
+python_dep="${python_dep//,ssl}"
+python_dep="${python_dep//ssl,}"
+
+# The pysqlite blocker is for bug #282760.
+DEPEND="${python_dep}
+ >=sys-apps/sed-4.0.5 sys-devel/patch
+ doc? ( app-text/xmlto ~app-text/docbook-xml-dtd-4.4 )
+ epydoc? ( >=dev-python/epydoc-2.0 !<=dev-python/pysqlite-2.4.1 )"
+# Require sandbox-2.2 for bug #288863.
+# For xattr, we can spawn getfattr and setfattr from sys-apps/attr, but that's
+# quite slow, so it's not considered in the dependencies as an alternative to
+# to python-3.3 / pyxattr. Also, xattr support is only tested with Linux, so
+# for now, don't pull in xattr deps for other kernels.
+# For whirlpool hash, require python[ssl] or python-mhash (bug #425046).
+# For compgen, require bash[readline] (bug #445576).
+RDEPEND="${python_dep}
+ !build? ( >=sys-apps/sed-4.0.5
+ || ( >=app-shells/bash-4.2_p37[readline] ( <app-shells/bash-4.2_p37 >=app-shells/bash-3.2_p17 ) )
+ >=app-admin/eselect-1.2
+ || ( ${python_dep_ssl} dev-python/python-mhash )
+ )
+ elibc_FreeBSD? ( sys-freebsd/freebsd-bin )
+ elibc_glibc? ( >=sys-apps/sandbox-2.2 )
+ elibc_uclibc? ( >=sys-apps/sandbox-2.2 )
+ >=app-misc/pax-utils-0.1.17
+ xattr? ( kernel_linux? ( || ( >=dev-lang/python-3.3_pre20110902 dev-python/pyxattr ) ) )
+ selinux? ( || ( >=sys-libs/libselinux-2.0.94[python] <sys-libs/libselinux-2.0.94 ) )
+ !<app-shells/bash-3.2_p17
+ !<app-admin/logrotate-3.8.0"
+PDEPEND="
+ !build? (
+ >=net-misc/rsync-2.6.4
+ userland_GNU? ( >=sys-apps/coreutils-6.4 )
+ )"
+# coreutils-6.4 rdep is for date format in emerge-webrsync #164532
+# NOTE: FEATURES=install-sources requires debugedit and rsync
+
+SRC_ARCHIVES="http://dev.gentoo.org/~zmedico/portage/archives"
+
+prefix_src_archives() {
+ local x y
+ for x in ${@}; do
+ for y in ${SRC_ARCHIVES}; do
+ echo ${y}/${x}
+ done
+ done
+}
+
+PV_PL="2.1.2"
+PATCHVER_PL=""
+TARBALL_PV=$PV
+SRC_URI="mirror://gentoo/${PN}-${TARBALL_PV}.tar.bz2
+ $(prefix_src_archives ${PN}-${TARBALL_PV}.tar.bz2)
+ linguas_pl? ( mirror://gentoo/${PN}-man-pl-${PV_PL}.tar.bz2
+ $(prefix_src_archives ${PN}-man-pl-${PV_PL}.tar.bz2) )"
+
+PATCHVER=
+[[ $TARBALL_PV = $PV ]] || PATCHVER=$PV
+if [ -n "${PATCHVER}" ]; then
+ SRC_URI="${SRC_URI} mirror://gentoo/${PN}-${PATCHVER}.patch.bz2
+ $(prefix_src_archives ${PN}-${PATCHVER}.patch.bz2)"
+fi
+
+S="${WORKDIR}"/${PN}-${TARBALL_PV}
+S_PL="${WORKDIR}"/${PN}-${PV_PL}
+
+compatible_python_is_selected() {
+ [[ $(/usr/bin/python -c 'import sys ; sys.stdout.write(sys.hexversion >= 0x2060000 and "good" or "bad")') = good ]]
+}
+
+current_python_has_xattr() {
+ [[ $(/usr/bin/python -c 'import sys ; sys.stdout.write(sys.hexversion >= 0x3030000 and "yes" or "no")') = yes ]] || \
+ /usr/bin/python -c 'import xattr' 2>/dev/null
+}
+
+pkg_setup() {
+ if use python2 && use python3 ; then
+ ewarn "Both python2 and python3 USE flags are enabled, but only one"
+ ewarn "can be in the shebangs. Using python3."
+ fi
+ if use pypy1_9 && use python3 ; then
+ ewarn "Both pypy1_9 and python3 USE flags are enabled, but only one"
+ ewarn "can be in the shebangs. Using python3."
+ fi
+ if use pypy1_9 && use python2 ; then
+ ewarn "Both pypy1_9 and python2 USE flags are enabled, but only one"
+ ewarn "can be in the shebangs. Using python2"
+ fi
+ if ! use pypy1_9 && ! use python2 && ! use python3 && \
+ ! compatible_python_is_selected ; then
+ ewarn "Attempting to select a compatible default python interpreter"
+ local x success=0
+ for x in /usr/bin/python2.* ; do
+ x=${x#/usr/bin/python2.}
+ if [[ $x -ge 6 ]] 2>/dev/null ; then
+ eselect python set python2.$x
+ if compatible_python_is_selected ; then
+ elog "Default python interpreter is now set to python-2.$x"
+ success=1
+ break
+ fi
+ fi
+ done
+ if [ $success != 1 ] ; then
+ eerror "Unable to select a compatible default python interpreter!"
+ die "This version of portage requires at least python-2.6 to be selected as the default python interpreter (see \`eselect python --help\`)."
+ fi
+ fi
+
+ if use python3; then
+ python_set_active_version 3
+ elif use python2; then
+ python_set_active_version 2
+ elif use pypy1_9; then
+ python_set_active_version 2.7-pypy-1.9
+ fi
+}
+
+src_prepare() {
+ if [ -n "${PATCHVER}" ] ; then
+ if [[ -L $S/bin/ebuild-helpers/portageq ]] ; then
+ rm "$S/bin/ebuild-helpers/portageq" \
+ || die "failed to remove portageq helper symlink"
+ fi
+ epatch "${WORKDIR}/${PN}-${PATCHVER}.patch"
+ fi
+ einfo "Setting portage.VERSION to ${PVR} ..."
+ sed -e "s/^VERSION=.*/VERSION=\"${PVR}\"/" -i pym/portage/__init__.py || \
+ die "Failed to patch portage.VERSION"
+ sed -e "1s/VERSION/${PVR}/" -i doc/fragment/version || \
+ die "Failed to patch VERSION in doc/fragment/version"
+ sed -e "1s/VERSION/${PVR}/" -i man/* || \
+ die "Failed to patch VERSION in man page headers"
+
+ if ! use ipc ; then
+ einfo "Disabling ipc..."
+ sed -e "s:_enable_ipc_daemon = True:_enable_ipc_daemon = False:" \
+ -i pym/_emerge/AbstractEbuildProcess.py || \
+ die "failed to patch AbstractEbuildProcess.py"
+ fi
+
+ if use xattr && use kernel_linux ; then
+ einfo "Adding FEATURES=xattr to make.globals ..."
+ echo -e '\nFEATURES="${FEATURES} xattr"' >> cnf/make.globals \
+ || die "failed to append to make.globals"
+ fi
+
+ if use python3; then
+ einfo "Converting shebangs for python3..."
+ python_convert_shebangs -r 3 .
+ elif use python2; then
+ einfo "Converting shebangs for python2..."
+ python_convert_shebangs -r 2 .
+ elif use pypy1_9; then
+ einfo "Converting shebangs for pypy-c1.9..."
+ python_convert_shebangs -r 2.7-pypy-1.9 .
+ fi
+
+ cd "${S}/cnf" || die
+ if [ -f "make.conf.${ARCH}".diff ]; then
+ patch make.conf "make.conf.${ARCH}".diff || \
+ die "Failed to patch make.conf.example"
+ else
+ eerror ""
+ eerror "Portage does not have an arch-specific configuration for this arch."
+ eerror "Please notify the arch maintainer about this issue. Using generic."
+ eerror ""
+ fi
+}
+
+src_compile() {
+ if use doc; then
+ emake docbook || die
+ fi
+
+ if use epydoc; then
+ einfo "Generating api docs"
+ emake epydoc || die
+ fi
+}
+
+src_test() {
+ emake test || die
+}
+
+src_install() {
+ emake DESTDIR="${D}" \
+ sysconfdir="/etc" \
+ prefix="/usr" \
+ install || die
+
+ # Extended set config is currently disabled in portage-2.1.x.
+ rm -rf "${D}/usr/share/portage/config/sets" || die
+
+ # Use dodoc for compression, since the Makefile doesn't do that.
+ dodoc "${S}"/{ChangeLog,NEWS,RELEASE-NOTES} || die
+
+ if use linguas_pl; then
+ doman -i18n=pl "${S_PL}"/man/pl/*.[0-9] || die
+ doman -i18n=pl_PL.UTF-8 "${S_PL}"/man/pl_PL.UTF-8/*.[0-9] || die
+ fi
+
+ # Set PYTHONPATH for portage API consumers. This way we don't have
+ # to rely on patched python having the correct path, since it has
+ # been known to incorrectly add /usr/libx32/portage/pym to sys.path.
+ echo "PYTHONPATH=\"/usr/lib/portage/pym\"" > \
+ "${T}/05portage" || die
+ doenvd "${T}/05portage" || die
+}
+
+pkg_preinst() {
+ if [[ $ROOT == / ]] ; then
+ # Run some minimal tests as a sanity check.
+ local test_runner=$(find "$D" -name runTests)
+ if [[ -n $test_runner && -x $test_runner ]] ; then
+ einfo "Running preinst sanity tests..."
+ "$test_runner" || die "preinst sanity tests failed"
+ fi
+ fi
+
+ if use xattr && ! current_python_has_xattr ; then
+ ewarn "For optimal performance in xattr handling, install"
+ ewarn "dev-python/pyxattr, or install >=dev-lang/python-3.3 and"
+ ewarn "enable USE=python3 for $CATEGORY/$PN."
+ fi
+
+ if ! use build && ! has_version dev-python/pycrypto && \
+ ! has_version '>=dev-lang/python-2.6[ssl]' ; then
+ ewarn "If you are an ebuild developer and you plan to commit ebuilds"
+ ewarn "with this system then please install dev-python/pycrypto or"
+ ewarn "enable the ssl USE flag for >=dev-lang/python-2.6 in order"
+ ewarn "to enable RMD160 hash support."
+ ewarn "See bug #198398 for more information."
+ fi
+
+ if [[ -d ${ROOT}var/log/portage && \
+ $(ls -ld "${ROOT}var/log/portage") != *" portage portage "* ]] && \
+ has_version '<sys-apps/portage-2.1.10.11' ; then
+ # Initialize permissions for bug #378451 and bug #377177, since older
+ # portage does not create /var/log/portage with the desired default
+ # permissions.
+ einfo "Applying portage group permission to ${ROOT}var/log/portage for bug #378451"
+ chown portage:portage "${ROOT}var/log/portage"
+ chmod g+ws "${ROOT}var/log/portage"
+ fi
+
+ if has_version '<sys-apps/portage-2.1.10.61' ; then
+ ewarn "FEATURES=config-protect-if-modified is now enabled by default."
+ ewarn "This causes the CONFIG_PROTECT behavior to be skipped for"
+ ewarn "files that have not been modified since they were installed."
+ fi
+}
+
+pkg_postinst() {
+ # Compile all source files recursively. Any orphans
+ # will be identified and removed in postrm.
+ python_mod_optimize /usr/lib/portage/pym
+}
+
+pkg_postrm() {
+ python_mod_cleanup /usr/lib/portage/pym
+}