commit: bead9cd7487a3f40a79af807bc615160191ae103 Author: Fabian Groffen <grobian <AT> gentoo <DOT> org> AuthorDate: Wed Dec 27 18:35:08 2017 +0000 Commit: Fabian Groffen <grobian <AT> gentoo <DOT> org> CommitDate: Wed Dec 27 18:35:08 2017 +0000 URL: https://gitweb.gentoo.org/repo/proj/prefix.git/commit/?id=bead9cd7
dev-lang/python: cleanup ebuilds Package-Manager: Portage-2.3.18-prefix, Repoman-2.3.6 dev-lang/python/Manifest | 12 - dev-lang/python/python-2.7.11-r2.ebuild | 632 -------------------------------- dev-lang/python/python-3.4.3-r5.ebuild | 436 ---------------------- dev-lang/python/python-3.5.1-r3.ebuild | 434 ---------------------- dev-lang/python/python-3.5.2.ebuild | 437 ---------------------- 5 files changed, 1951 deletions(-) diff --git a/dev-lang/python/Manifest b/dev-lang/python/Manifest index ab0377dc47..e9b4feefe1 100644 --- a/dev-lang/python/Manifest +++ b/dev-lang/python/Manifest @@ -1,29 +1,17 @@ DIST 7be648659ef46f33db6913ca0ca5a809219d5629.zip 9199 SHA256 f813f6f9437cb152824670e46b9c5d4235d29b8b433b40d74bd936a8e540828b SHA512 cabc21d2d7379daf1f4bafe7ab00b70e5b4f707d3102496b96ff0dfdced26347097ad771c69e0b9488b7c54b1ef36f9bc019bee72f1ffcbb55dcd0e71095edfe WHIRLPOOL 2c0a08deb24940c58c9e524d47bbadab6706fb0873e5899fe98a41af0b9ab07ed9ca7b03ac57c2aa199572e347b5c500371a9ef63fdc2201043595a227cae0ad DIST 8ee84829be03c2a1aa74f0f095c994c1f43f4688.zip 14239 SHA256 811b6fe82630a04a44a6d16074af76964e7e4005136ba479647eb741639099da SHA512 2f3ada7ff2bd97f90e3b972b681624ddf45c6d1db8d5e89f1313b4693db240a3c4e27c84bd2cf8ff71d5fb276b381ca6a3b8a6945f8db53ff3496cc4cc0b1d62 WHIRLPOOL 73eba606051ed1232de22965f0879cd2dc3895d2d280a3e355581be788adf1af20e96c7eb725af2e71df1d022e6b208ab2ffe70515693536d6464f033224cd14 -DIST Python-2.7.11.tar.xz 12277476 BLAKE2B 398e8505b503819268c786b989406934301216a083f05d000b17e39d1d6d0befdf6ab5e01810bb8e585813fc28ae9397b250456fdc597fcc74756a1d2b23054b SHA512 72166763a2fe6aab45ecf378f55a1efc7322d1742c4638bae84f4ed4b9fb4c01f2a0293733c64426ae2c70df24d95ff2b1e2a4f3c2715de00d8f320d4d939ea0 DIST Python-2.7.12.tar.xz 12390820 BLAKE2B 97446bca10005277cf1a92ce7fc9e847d5df93f656a6a3b66e9f064d1c2ba35d5a8b420aaa64b92247d6a3fcd3852876450faebc466c7a8e841fd0c2e62fd306 SHA512 6ddbbce47cc49597433d98ca05c2f62f07ed1070807b645602a8e9e9b996adc6fa66fa20a33cd7d23d4e7e925e25071d7301d288149fbe4e8c5f06d5438dda1f DIST Python-2.7.14.tar.xz 12576112 BLAKE2B e03c4134cfdd88678acc26f383130a598ce4de908ab6bb9ee00e9235de3e0fcb9e653fec86f39db64fb895ef797d33736524655c5b94fab2cde2544b966b2cfb SHA512 78310b0be6388ffa15f29a80afb9ab3c03a572cb094e9da00cfe391afadb51696e41f592eb658d6a31a2f422fdac8a55214a382cbb8cfb43d4a127d5b35ea7f9 -DIST Python-3.4.3.tar.xz 14421964 BLAKE2B 170d4a26430a7489ef88671757d74be38377e41180fd907d928e1ef7b231f8da688b2208ec1bb22431f8846a03d95560b94646a61de9f02ff1ada258e5dd0263 SHA512 55b2d7c07da8ad3a3971b4687da2e45809c6f1474732e93b0432f121f287d0b63ad8a9bf381987ea70f47a03d9474c3e55b7d86d14800bf7ef29b3324d8d35b9 DIST Python-3.4.5.tar.xz 14516820 BLAKE2B f9ddabd2df2241089d07756d3a8ba1c70096bee60d7cdef84041edbb20c488c3a573762441a4b7f543dbc0ce403ce84ff7d02e7d25699917bd014ab96deead85 SHA512 b548a5338d141b3086dea372fa2cc245ba5350ee9f0d1304ef6222dc45380b66d380b092e547d54206d56ca68563b95036f445f97f72bb0ef1d48f81a74a3d4c -DIST Python-3.5.1.tar.xz 14830408 BLAKE2B b93e51c6d2a8507b27f4c9db577276acbe77993badfaafd571daf8fb12922643b2007e6f7a2cc952f6d763966b7b5ec8c4a1de2d85d4f4f62fe2b1e64fbd864a SHA512 261c9e42ae351853c718707a8887817e308b3ba7a37e9463a0bc8f50ee9be9ac1a011b2891f8877ecdb40beab99279bcfa8e04f813b8998fcf6cefb7fd52d850 -DIST Python-3.5.2.tar.xz 15222676 BLAKE2B 54b16452536a2a48ee825227328a76b49fd3295d3dc5859197b0bee3ca47662fb0f4eb277f2b18c136f8b447e02afd52d6f7321073a620efb523662f7639d728 SHA512 c07c3366f1c81e214241444bb9da6db9d11da32ad66bfa29cdad5a3b2e34e4d870bda6d4ce3c3910b582942e91f1d8c8a1c1a7b9464cc147b83c9e0007012742 DIST Python-3.5.4.tar.xz 15332320 BLAKE2B 1fc3ba4eb1ed949062961c13fd1f9851c7f9cbeb4916c06a0389349ee2d4872b2b1c2d30138822e6329b6a715f35a66df704b7a04aa4adeb95b685b8d6e45d61 SHA512 dbbe2740ee1cce5404b7b6436a9b3887e15f415a1006efa22014ec7e5b1e48c43eed0ff98f6f5b365c527b8d2525be4ce72bbe404ce71c0835529fcd6f0267ff DIST Python-3.6.3.tar.xz 16974296 BLAKE2B 8220fc0c2eaa315d3972085b0f531f169adb6cfad57023ad2c115603b5a484573ea3540eb3216edd0f4514256c8edb07469cf38d17727d69cdc15cdf1f601623 SHA512 32f24a3adcb7880003c7ecdc5e53e838e774adda76b308961d8215e28db630b2fa2828097817924c76afa4212b2df3362eb64d4e10f37c0147f512ec5aa8662b -DIST python-gentoo-patches-2.7.11-0.tar.xz 12916 BLAKE2B 6df9187ad5ab54699f6723b502863ced90f4aa76bdd7c9e6a41c0540502fcd783ee753a74c4a713ec40beed99166b893829171ea1dd5077c23051817e447cb27 SHA512 f0447bb699a163afc08df39b111394377539935546ae23732d7239e78d2bff0c04bc94949f86aef0c1be83736127dbd25c2c531e49befed2d638c3cd4940ac52 DIST python-gentoo-patches-2.7.12-0.tar.xz 13576 BLAKE2B 6ae9fc3e8d3e7dca2e8f5fa6ec9709be9e41982bcd8ca71764766c1a21e596c42d389afd65379c65c469dbbe53918cfa5a23ec7ca7e825f35bc462ff3110f949 SHA512 8bf530fca15c47fa5d9bc958e433b35943a12c98e4172806a45aa60dc85ec92f8ab6ffcd90f752dc5bf8ffc711414894c15820c4b6ef72dbcedc2808119fb1f6 DIST python-gentoo-patches-2.7.14-0.tar.xz 13428 BLAKE2B 0048e48ddaaa4bef08451354fde95a123042880f26dddc9267c7f9a90fd8abb40955e26ee8c9dfc5a1165556bb3e11585b27288e635d42a4000dd3d7654c41ad SHA512 6da5b52065752b54e9215d0f0809c75167dc3690d0e94fa21dd7595626925bc5c1dd065d31b3bd696d7087f3986de145d3a335a29eb7bd77442637a7ec2863c1 -DIST python-gentoo-patches-3.4.3-0.tar.xz 11736 BLAKE2B 7af06fdf3127047f4ac604e3ae37ba616347ee456e9259c003ab00cbf9da4265f502fa4e8eec9aeb35532bdd2b6e2f5e879d2ed1f13a64c474d22bc49e06f5a9 SHA512 7ad1b30cf8bb7900fe518ed71e4ee55dd92ce7e23ae583a1f2f851b26cfa8c4f4271d28f418e780f3725a48d4ca8eeb8fd083f850810c66c29fb08c430828d72 DIST python-gentoo-patches-3.4.5-0.tar.xz 12044 BLAKE2B 7fb3cc7dcd987debd5aa263d8e26b21aad439d8e3177c06c3683406a53bbda9652175673b09b6300f6a5b62148190cd8a75c9b65a5de04d770866733fcc0ebcb SHA512 108a4845667ecdf4001fcbeffab0cfbbac87439a449a7351428b0f3e2f159e3848ee0c0dfa45c9fba893b9f9584b33722fc8bb0bd7485a1d0909c3a35ede6ed8 -DIST python-gentoo-patches-3.5.1-0.tar.xz 11788 BLAKE2B 6fd0634ce38b446e4858ee6706b0edd88387da07b71fe1e97f2831505b782823f307a9d11f5d081b06eb6575a14918235445bed3859bbc4d93391643dda80109 SHA512 3948af801e3e70b55b15165d6cc56fb33cdb9fcc9d80b913550c8609273bad28db0c10ec64cb14d010b80020716a1e45d720e08864f6ac850291cb1713800a1a -DIST python-gentoo-patches-3.5.2-0.tar.xz 12008 BLAKE2B d4bb4cf064a6b535cfdd8b79b8b14a8803917829d78f481c7fb64fdb549372e0567631b58ae9fab090943fbbdcd25c6ae61fb5f3e5bb9bdd214820e78089eded SHA512 e2ef1b8f10f9ea849bf52a0be65d48f7cfecf07bdf151cbbd7e3a1c9428a8d96e901650496c4ae7fd0093af8cc90de8df674dc1a4c66ad21916a4ee45a81efc8 DIST python-gentoo-patches-3.5.4-0.tar.xz 11704 BLAKE2B 4a7d71feff18c7c8c109bed10748348484d314183c3de3ec950d5ca5ce7048bb322c470f3f5bff2d63eb7f2ed99c0fe75c621df050273d9d118681b28926061d SHA512 d395a87695f700598026038d6929ea5038abd7d494294037a4dfa02d5262203dbbaa6ae258a5a7f35ff5542f6266dcf69cc0b9c3df2a047cd2f6699a87e182ec DIST python-gentoo-patches-3.6.2-0.tar.xz 10744 BLAKE2B 3075754627617ac2ceee879eaf1a0e6564505655cdbdff380233a09df701a6188d64fe1f6a8c642b1fb05ef3c460a07042b6a362d655cd02717d6d9ba47983a1 SHA512 2aac1700c541202aa4f43bff4cb521b996d52ab350133318abaddb43f4b6e20548f37de472ace8024ef325ebf63fdfff0d43f8aa1f717d3c56f974b7aa1764e3 -DIST python-prefix-2.7.11-gentoo-patches-r1.tar.xz 17268 BLAKE2B 8d5c0cb25a8588de78a993e851858f34ac52ff28898dd375b773891f6b6f998289a01491f5b248a8a5f1576cefa5a53937efb4dfc782ee29b9a669cf815eb7a6 SHA512 22218128ff83856dd042ecd6aab3615282ab29c4420e6cce4a0bba8b6508e3f5649c27cdf50cf342fffd3c87ea29f8b7d32d28b9b1f4dc200771b52ee41f27e5 DIST python-prefix-2.7.12-gentoo-patches-r0.tar.xz 17380 BLAKE2B 566c47624d054cd251ea4350bf57735ad63057a6ef7968dbe572a02156a03c080303ba2aa6c26e10077070507317b22eb7665595aaf903b4ffd4a45104fbfa31 SHA512 ef17c8e8083da0ed0e6a63c96f59cc1243b0376fc6d4d7fcecb165e557403c54ae87625ed6dfe4d7d73693f8220ec98ef8a3f16124d8022dbac6a3a9d5514d9c DIST python-prefix-2.7.14-gentoo-patches-r0.tar.xz 14736 BLAKE2B 75422fc7390f559d9864f6e22a0b85982ccbdb07d5f2507db8e528285e56d1f11d4bc0b21a0b78d5340eafd562220d2f1b9d0a78b1f7c811c5689a426a81f9f3 SHA512 bf8e5039fff834d03a5a671269905f1ea10961995f2327ea023f6ad4d9b49bf210ec746ac6f45a01ff7501f1eb616013951d164410f6c64bce04df0e8b9715c8 -DIST python-prefix-3.4.3-gentoo-patches-r1.tar.xz 12896 BLAKE2B d9a6453391228a0b6a7c39953798641f2b7a07252ad48365521fa14caf35694664553c9ed29932b0e334c3cd3089712eebe309d9002b645c2c0b1e2add20947e SHA512 dd1082ef9605fdcb84bcc769318be6934c889a5b6134971fb121b3be8301cb9519fb687841a359c65e0614d05a8c27eab4b3dbfe94ed8dbbf2fc64f82206a6d9 DIST python-prefix-3.4.5-gentoo-patches-r0.tar.xz 12932 BLAKE2B 228cea390cd16f68579896ccec06025446d6378ee164090a7f8ab8174d28e73e35b0e311b95ab78be7a54b21eefce7c01238e3cb31fae1f49a1706476c5abda5 SHA512 e32556c63e48d8dacd86218945147d1bbbc5777a6bb3441373827da47771a8eb387f26885acd35343cc598c719c9feec63007144fc1fdd1aca253a2ec1a19825 -DIST python-prefix-3.5.1-gentoo-patches-r2.tar.xz 12680 BLAKE2B 26d9149dca4aec253c5589f72b299412a62739b48ee05f2cd18c1500b8eee409f7a132a64a5910fa621e94aee08f92ee035ad94973f80dfd3b136f5096a63c5c SHA512 82b08b8cf7f3620c4c2a6a6c3ed5ec8c3318c6f43e4bcc4950c7aeb56ec755e0e47d46f068843f5b04159583994c8620dab14827278a199789a3867532cc6e0c -DIST python-prefix-3.5.2-gentoo-patches-r0.tar.xz 12652 BLAKE2B f248701de779840be6cc8c9921c0f598c228d218c628754e7b7fe0c00d031a20d60b05c2142a3f7d720dd97b73863b6bd9afb00fa2a456f5c2a8efe53eb99ff8 SHA512 e214583393aaf6ec603495531fd2c8d3c668c1fc72c4e3226a4daa537ad34e763302d7110b9ca8a58eb77955aad22371f6cf13247c6d06350f56989301faae8b DIST python-prefix-3.5.4-gentoo-patches-r0.tar.xz 12768 BLAKE2B ab0cbc5430e9588f71cfd7b001a07f9a77097262f17e1f980e3945e39855e1c9437117bf4eb2d424dadf701d37d025e09627d7efdbb9f8867714039f62f261a7 SHA512 334cd8990483f973386cc6bbc962d2843449c493f7d33349fcc8f68120e246c52ea80236c99685555974e439fa877b537b32ef7d181198f58950f5e9b835b1c5 DIST python-prefix-3.6.3-gentoo-patches-r0.tar.xz 12676 BLAKE2B 5221ae00d16db401d5674947923451d850978d930d9449d9b4f6ae6d117c26971e2f384c5a698b7acc8d62e6a6b673f4ec870da3788f87372593a5ac4897a227 SHA512 9d1673bc7b327be6b7e95491940eeeaa40db9e94f2183f4605a9a5a7fd2e187017164e9b2ef31f3bc8d694e467de6843706d3341b4ce24d4d8717513c246b62f diff --git a/dev-lang/python/python-2.7.11-r2.ebuild b/dev-lang/python/python-2.7.11-r2.ebuild deleted file mode 100644 index 4143e8b7a4..0000000000 --- a/dev-lang/python/python-2.7.11-r2.ebuild +++ /dev/null @@ -1,632 +0,0 @@ -# Copyright 1999-2017 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -EAPI="5" -WANT_LIBTOOL="none" - -inherit autotools eutils flag-o-matic multilib pax-utils python-utils-r1 toolchain-funcs multiprocessing - -MY_P="Python-${PV}" -PATCHSET_VERSION="2.7.11-0" -PREFIX_PATCHREV="r1" -CYGWINPORTS_GITREV="7be648659ef46f33db6913ca0ca5a809219d5629" - -DESCRIPTION="An interpreted, interactive, object-oriented programming language" -HOMEPAGE="http://www.python.org/" -SRC_URI="http://www.python.org/ftp/python/${PV}/${MY_P}.tar.xz - https://dev.gentoo.org/~djc/python-gentoo-patches-${PATCHSET_VERSION}.tar.xz - https://dev.gentoo.org/~grobian/distfiles/python-prefix-${PV}-gentoo-patches-${PREFIX_PATCHREV}.tar.xz" - -[[ -n ${CYGWINPORTS_GITREV} ]] && -SRC_URI+=" elibc_Cygwin? ( https://github.com/cygwinports/python2/archive/${CYGWINPORTS_GITREV}.zip )" - -LICENSE="PSF-2" -SLOT="2.7" -KEYWORDS="~ppc-aix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" -IUSE="aqua -berkdb build doc elibc_uclibc examples gdbm hardened ipv6 libressl +ncurses +readline sqlite +ssl +threads tk +wide-unicode wininst +xml" - -# Do not add a dependency on dev-lang/python to this ebuild. -# If you need to apply a patch which requires python for bootstrapping, please -# run the bootstrap code on your dev box and include the results in the -# patchset. See bug 447752. - -RDEPEND="app-arch/bzip2:0= - >=sys-libs/zlib-1.1.3:0= - !m68k-mint? ( virtual/libffi ) - virtual/libintl - berkdb? ( || ( - sys-libs/db:5.3 - sys-libs/db:5.2 - sys-libs/db:5.1 - sys-libs/db:5.0 - sys-libs/db:4.8 - sys-libs/db:4.7 - sys-libs/db:4.6 - sys-libs/db:4.5 - sys-libs/db:4.4 - sys-libs/db:4.3 - sys-libs/db:4.2 - ) ) - gdbm? ( sys-libs/gdbm:0=[berkdb] ) - ncurses? ( - >=sys-libs/ncurses-5.2:0= - readline? ( >=sys-libs/readline-4.1:0= ) - ) - sqlite? ( >=dev-db/sqlite-3.3.8:3= ) - ssl? ( - !libressl? ( dev-libs/openssl:0= ) - libressl? ( dev-libs/libressl:= ) - ) - tk? ( - >=dev-lang/tcl-8.0:0= - >=dev-lang/tk-8.0:0=[-aqua] - dev-tcltk/blt:0= - dev-tcltk/tix - ) - xml? ( >=dev-libs/expat-2.1 ) - !!<sys-apps/portage-2.1.9" -DEPEND="${RDEPEND} - virtual/pkgconfig - >=sys-devel/autoconf-2.65 - !sys-devel/gcc[libffi]" -RDEPEND+=" !build? ( app-misc/mime-types ) - doc? ( dev-python/python-docs:${SLOT} )" -PDEPEND=">=app-eselect/eselect-python-20140125-r1 - app-admin/python-updater" - -S="${WORKDIR}/${MY_P}" - -pkg_setup() { - if use berkdb; then - ewarn "'bsddb' module is out-of-date and no longer maintained inside" - ewarn "dev-lang/python. 'bsddb' and 'dbhash' modules have been additionally" - ewarn "removed in Python 3. A maintained alternative of 'bsddb3' module" - ewarn "is provided by dev-python/bsddb3." - else - if has_version "=${CATEGORY}/${PN}-${PV%%.*}*[berkdb]"; then - ewarn "You are migrating from =${CATEGORY}/${PN}-${PV%%.*}*[berkdb]" - ewarn "to =${CATEGORY}/${PN}-${PV%%.*}*[-berkdb]." - ewarn "You might need to migrate your databases." - fi - fi -} - -src_prepare() { - # Ensure that internal copies of expat, libffi and zlib are not used. - rm -r Modules/expat || die - rm -r Modules/_ctypes/libffi* || die - rm -r Modules/zlib || die - - if tc-is-cross-compiler; then - local EPATCH_EXCLUDE="*_regenerate_platform-specific_modules.patch" - fi - - EPATCH_SUFFIX="patch" epatch "${WORKDIR}/patches" - - # if building a patched source-tar, comment the rm's above, and uncomment - # this line: - #local EPATCH_EXCLUDE=" 01_all_prefix-no-patch-invention.patch" - - # Prefix' round of patches - # http://prefix.gentooexperimental.org:8000/python-patches-2_7 - EPATCH_EXCLUDE="${excluded_patches}" EPATCH_SUFFIX="patch" \ - epatch "${WORKDIR}"/python-prefix-${PV}-gentoo-patches-${PREFIX_PATCHREV} - - if use aqua ; then - # make sure we don't get a framework reference here - sed -i -e '/-DPREFIX=/s:$(prefix):$(FRAMEWORKUNIXTOOLSPREFIX):' \ - -e '/-DEXEC_PREFIX=/s:$(exec_prefix):$(FRAMEWORKUNIXTOOLSPREFIX):' \ - Makefile.pre.in || die - # Python upstream refuses to listen to configure arguments - sed -i -e '/FRAMEWORKINSTALLAPPSPREFIX=/s:="[^"]*":="${prefix}/../Applications":' \ - configure.ac configure || die - # we handle creation of symlinks in src_install - sed -i -e '/ln -fs .*PYTHONFRAMEWORK/d' Makefile.pre.in || die - fi - # don't try to do fancy things on Darwin - sed -i -e 's/__APPLE__/__NO_MUCKING_AROUND__/g' Modules/readline.c || die - - # Fix for cross-compiling. - epatch "${FILESDIR}/python-2.7.5-nonfatal-compileall.patch" - epatch "${FILESDIR}/python-2.7.9-ncurses-pkg-config.patch" - epatch "${FILESDIR}/python-2.7.10-cross-compile-warn-test.patch" - epatch "${FILESDIR}/python-2.7.10-system-libffi.patch" - epatch "${FILESDIR}/python-3.4-pyfpe-dll.patch" # Cygwin: --with-fpectl - - # On AIX, we've wrapped /usr/ccs/bin/nm to work around long TMPDIR. - sed -i -e "/^NM=.*nm$/s,^.*$,NM=$(tc-getNM)," Modules/makexp_aix || die - - # Make sure python doesn't use the host libffi. - use prefix && epatch "${FILESDIR}/python-2.7-libffi-pkgconfig.patch" - - if [[ -n ${CYGWINPORTS_GITREV} ]] && use elibc_Cygwin; then - local p d="${WORKDIR}/python2-${CYGWINPORTS_GITREV}" - for p in $( - eval "$(sed -ne '/PATCH_URI="/,/"/p' < "${d}"/python.cygport)" - echo ${PATCH_URI} - ); do - # dropped by 01_all_prefix-no-patch-invention.patch - [[ ${p} == *-tkinter-* ]] && continue - epatch "${d}/${p}" - done - fi - - epatch_user - - sed -i -e "s:@@GENTOO_LIBDIR@@:$(get_libdir):g" \ - Lib/distutils/command/install.py \ - Lib/distutils/sysconfig.py \ - Lib/site.py \ - Lib/sysconfig.py \ - Lib/test/test_site.py \ - Makefile.pre.in \ - Modules/Setup.dist \ - Modules/getpath.c \ - setup.py || die "sed failed to replace @@GENTOO_LIBDIR@@" - - eautoreconf -} - -src_configure() { - # dbm module can be linked against berkdb or gdbm. - # Defaults to gdbm when both are enabled, #204343. - local disable - use berkdb || use gdbm || disable+=" dbm" - use berkdb || disable+=" _bsddb" - use gdbm || disable+=" gdbm" - use ncurses || disable+=" _curses _curses_panel" - use readline || disable+=" readline" - use sqlite || disable+=" _sqlite3" - use ssl || export PYTHON_DISABLE_SSL="1" - use tk || disable+=" _tkinter" - use xml || disable+=" _elementtree pyexpat" # _elementtree uses pyexpat. - [[ ${CHOST} == *64-apple-darwin* ]] && disable+=" Nav _Qt" # Carbon - [[ ${CHOST} == *-apple-darwin11 ]] && disable+=" _Fm _Qd _Qdoffs" - export PYTHON_DISABLE_MODULES="${disable}" - - if ! use xml; then - ewarn "You have configured Python without XML support." - ewarn "This is NOT a recommended configuration as you" - ewarn "may face problems parsing any XML documents." - fi - - if [[ -n "${PYTHON_DISABLE_MODULES}" ]]; then - einfo "Disabled modules: ${PYTHON_DISABLE_MODULES}" - fi - - if [[ "$(gcc-major-version)" -ge 4 ]]; then - append-flags -fwrapv - fi - - filter-flags -malign-double - - # https://bugs.gentoo.org/show_bug.cgi?id=50309 - if is-flagq -O3; then - is-flagq -fstack-protector-all && replace-flags -O3 -O2 - use hardened && replace-flags -O3 -O2 - fi - - if tc-is-cross-compiler; then - # Force some tests that try to poke fs paths. - export ac_cv_file__dev_ptc=no - export ac_cv_file__dev_ptmx=yes - fi - - # http://bugs.gentoo.org/show_bug.cgi?id=302137 - if [[ ${CHOST} == powerpc-*-darwin* ]] && \ - ( is-flag "-mtune=*" || is-flag "-mcpu=*" ) || \ - [[ ${CHOST} == powerpc64-*-darwin* ]]; - then - replace-flags -O2 -O3 - replace-flags -Os -O3 # comment #14 - fi - - # Set LDFLAGS so we link modules with -lpython2.7 correctly. - # Needed on FreeBSD unless Python 2.7 is already installed. - # Please query BSD team before removing this! - # On AIX this is not needed, but would record '.' as runpath. - [[ ${CHOST} == *-aix* ]] || - append-ldflags "-L." - - if use prefix ; then - # for Python's setup.py not to do false assumptions (only looking in - # host paths) we need to make explicit where Prefix stuff is - append-cppflags -I"${EPREFIX}"/usr/include - append-ldflags -L"${EPREFIX}"/$(get_libdir) - append-ldflags -L"${EPREFIX}"/usr/$(get_libdir) - # fix compilation on some 64-bits Linux hosts, #381163, #473520 - for hostlibdir in /usr/lib32 /usr/lib64 /usr/lib /lib32 /lib64; do - [[ -d ${hostlibdir} ]] || continue - append-ldflags -L${hostlibdir} - done - # Have to move $(CPPFLAGS) to before $(CFLAGS) to ensure that - # local include paths - set in $(CPPFLAGS) - are searched first. - sed -i -e "/^PY_CFLAGS[ \\t]*=/s,\\\$(CFLAGS)[ \\t]*\\\$(CPPFLAGS),\$(CPPFLAGS) \$(CFLAGS)," Makefile.pre.in || die - fi - - # Export CC so even AIX will use gcc instead of xlc_r. - # Export CXX so it ends up in /usr/lib/python2.X/config/Makefile. - tc-export CC CXX - # The configure script fails to use pkg-config correctly. - # http://bugs.python.org/issue15506 - export ac_cv_path_PKG_CONFIG=$(tc-getPKG_CONFIG) - - # Fix compilation on Solaris, easier to force the compiler in the - # standard mode that this Python version assumed (contrast to C99) - [[ ${CHOST} == *-solaris* ]] && CC="${CC} -std=gnu89" - - local dbmliborder - if use gdbm; then - dbmliborder+="${dbmliborder:+:}gdbm" - fi - if use berkdb; then - dbmliborder+="${dbmliborder:+:}bdb" - fi - - [[ ${CHOST} == *-mint* ]] && export ac_cv_func_poll=no - - # we need this to get pythonw, the GUI version of python - # --enable-framework and --enable-shared are mutually exclusive: - # http://bugs.python.org/issue5809 - local myshared= - use aqua \ - && myshared="--enable-framework=${EPREFIX}/usr/lib" \ - || myshared="--enable-shared" - - BUILD_DIR="${WORKDIR}/${CHOST}" - mkdir -p "${BUILD_DIR}" || die - cd "${BUILD_DIR}" || die - - # note: for a framework build we need to use ucs2 because OSX - # uses that internally too: - # http://bugs.python.org/issue763708 - # HAS_HG to avoid finding obsolete hg of the host - ECONF_SOURCE="${S}" OPT="" HAS_HG="no" \ - econf \ - --with-fpectl \ - ${myshared} \ - $(use_enable ipv6) \ - $(use_with threads) \ - $( (use wide-unicode && use !aqua) && echo "--enable-unicode=ucs4" || echo "--enable-unicode=ucs2") \ - --infodir='${prefix}/share/info' \ - --mandir='${prefix}/share/man' \ - --with-computed-gotos \ - --with-dbmliborder="${dbmliborder}" \ - --with-libc="" \ - --enable-loadable-sqlite-extensions \ - --with-system-expat \ - --with-system-ffi \ - --without-ensurepip - - if use threads && grep -q "#define POSIX_SEMAPHORES_NOT_ENABLED 1" pyconfig.h; then - eerror "configure has detected that the sem_open function is broken." - eerror "Please ensure that /dev/shm is mounted as a tmpfs with mode 1777." - die "Broken sem_open function (bug 496328)" - fi -} - -src_compile() { - # Avoid invoking pgen for cross-compiles. - touch Include/graminit.h Python/graminit.c - - cd "${BUILD_DIR}" || die - emake - - # Work around bug 329499. See also bug 413751 and 457194. - if has_version dev-libs/libffi[pax_kernel]; then - pax-mark E python - else - pax-mark m python - fi -} - -src_test() { - # Tests will not work when cross compiling. - if tc-is-cross-compiler; then - elog "Disabling tests due to crosscompiling." - return - fi - - cd "${BUILD_DIR}" || die - - # Skip failing tests. - local skipped_tests="distutils gdb" - - for test in ${skipped_tests}; do - mv "${S}"/Lib/test/test_${test}.py "${T}" - done - - # Rerun failed tests in verbose mode (regrtest -w). - emake test EXTRATESTOPTS="-w" < /dev/tty - local result="$?" - - for test in ${skipped_tests}; do - mv "${T}/test_${test}.py" "${S}"/Lib/test - done - - elog "The following tests have been skipped:" - for test in ${skipped_tests}; do - elog "test_${test}.py" - done - - elog "If you would like to run them, you may:" - elog "cd '${EPREFIX}/usr/$(get_libdir)/python${SLOT}/test'" - elog "and run the tests separately." - - if [[ "${result}" -ne 0 ]]; then - die "emake test failed" - fi -} - -src_install() { - local libdir=${ED}/usr/$(get_libdir)/python${SLOT} - - cd "${BUILD_DIR}" || die - [[ ${CHOST} == *-mint* ]] && keepdir /usr/lib/python${SLOT}/lib-dynload/ - if use aqua ; then - local fwdir="${EPREFIX}"/usr/$(get_libdir)/Python.framework - - # do not make multiple targets in parallel when there are broken - # sharedmods (during bootstrap), would build them twice in parallel. - - # Python_Launcher is kind of a wrapper, and we should fix it for - # Prefix (it uses /usr/bin/pythonw) so useless - # IDLE doesn't run, no idea, but definitely not used - sed -i -e 's/install_\(BuildApplet\|PythonLauncher\|IDLE\)[^:]//g' \ - Mac/Makefile || die - - # let the makefiles do their thing - emake -j1 CC="$(tc-getCC)" DESTDIR="${D}" STRIPFLAG= altinstall - rmdir "${ED}"/Applications/Python* || die - rmdir "${ED}"/Applications || die - - # avoid framework incompatability, degrade to a normal UNIX lib - mkdir -p "${ED}"/usr/$(get_libdir) - cp "${D}${fwdir}"/Versions/${SLOT}/Python \ - "${ED}"/usr/$(get_libdir)/libpython${SLOT}.dylib || die - chmod u+w "${ED}"/usr/$(get_libdir)/libpython${SLOT}.dylib - install_name_tool \ - -id "${EPREFIX}"/usr/$(get_libdir)/libpython${SLOT}.dylib \ - "${ED}"/usr/$(get_libdir)/libpython${SLOT}.dylib - chmod u-w "${ED}"/usr/$(get_libdir)/libpython${SLOT}.dylib - cp libpython${SLOT}.a "${ED}"/usr/$(get_libdir)/ || die - - # rebuild python executable to be the non-pythonw (python wrapper) - # version so we don't get framework crap - rm "${ED}"/usr/bin/python${SLOT} # drop existing symlink, bug #390861 - $(tc-getCC) "${ED}"/usr/$(get_libdir)/libpython${SLOT}.dylib \ - -o "${ED}"/usr/bin/python${SLOT} \ - Modules/python.o || die - - # don't install the "Current" symlink, will always conflict - rm "${D}${fwdir}"/Versions/Current || die - # update whatever points to it, eselect-python sets them - rm "${D}${fwdir}"/{Headers,Python,Resources} || die - - # remove unversioned files (that are not made versioned below) - pushd "${ED}"/usr/bin > /dev/null - rm -f python python-config python${SLOT}-config - # python${SLOT} was created above - for f in pythonw smtpd${SLOT}.py pydoc idle ; do - rm -f ${f} ${f}${SLOT} - done - # pythonw needs to remain in the framework (that's the whole - # reason we go through this framework hassle) - ln -s ../lib/Python.framework/Versions/${SLOT}/bin/pythonw${SLOT} || die - # copy the scripts to we can fix their shebangs - for f in 2to3 pydoc${SLOT} idle${SLOT} python${SLOT}-config ; do - # for some reason sometimes they already exist, bug #347321 - rm -f ${f} - cp "${D}${fwdir}"/Versions/${SLOT}/bin/${f} . || die - sed -i -e '1c\#!'"${EPREFIX}"'/usr/bin/python'"${SLOT}" \ - ${f} || die - done - # "fix" to have below collision fix not to bail - mv pydoc${SLOT} pydoc || die - mv idle${SLOT} idle || die - popd > /dev/null - - # basically we don't like the framework stuff at all, so just move - # stuff around or add some symlinks to make our life easier - mkdir -p "${ED}"/usr - mv "${D}${fwdir}"/Versions/${SLOT}/share \ - "${ED}"/usr/ || die "can't move share" - # get includes just UNIX style - mkdir -p "${ED}"/usr/include - mv "${D}${fwdir}"/Versions/${SLOT}/include/python${SLOT} \ - "${ED}"/usr/include/ || die "can't move include" - pushd "${D}${fwdir}"/Versions/${SLOT}/include > /dev/null - ln -s ../../../../../include/python${SLOT} || die - popd > /dev/null - rm -f "${ED}"/usr/share/man/man1/python{,2}.1 - - # same for libs - # NOTE: can't symlink the entire dir, because a real dir already exists - # on upgrade (site-packages), however since we h4x0rzed python to - # actually look into the UNIX-style dir, we just switch them around. - mkdir -p "${ED}"/usr/$(get_libdir)/python${SLOT} - mv "${D}${fwdir}"/Versions/${SLOT}/lib/python${SLOT}/* \ - "${ED}"/usr/$(get_libdir)/python${SLOT}/ \ - || die "can't move python${SLOT}" - rmdir "${D}${fwdir}"/Versions/${SLOT}/lib/python${SLOT} || die - pushd "${D}${fwdir}"/Versions/${SLOT}/lib > /dev/null - ln -s ../../../../python${SLOT} || die - popd > /dev/null - - # fix up Makefile - sed -i \ - -e '/^LINKFORSHARED=/s/-u _PyMac_Error.*$//' \ - -e '/^LDFLAGS=/s/=.*$/=/' \ - -e '/^prefix=/s:=.*$:= '"${EPREFIX}"'/usr:' \ - -e '/^PYTHONFRAMEWORK=/s/=.*$/=/' \ - -e '/^PYTHONFRAMEWORKDIR=/s/=.*$/= no-framework/' \ - -e '/^PYTHONFRAMEWORKPREFIX=/s/=.*$/=/' \ - -e '/^PYTHONFRAMEWORKINSTALLDIR=/s/=.*$/=/' \ - -e '/^LDLIBRARY=/s:=.*$:libpython$(VERSION).dylib:' \ - "${libdir}"/config/Makefile || die - # and sysconfigdata likewise - sed -i \ - -e "/'LINKFORSHARED'/s/-u _PyMac_Error[^']*'/'/" \ - -e "/'LDFLAGS'/s/:.*$/:'',/" \ - -e "/'prefix'/s|:.*$|:'${EPREFIX}/usr',|" \ - -e "/'PYTHONFRAMEWORK'/s/:.*$/:'',/" \ - -e "/'PYTHONFRAMEWORKDIR'/s/:.*$/:'no-framework',/" \ - -e "/'PYTHONFRAMEWORKPREFIX'/s/:.*$/:'',/" \ - -e "/'PYTHONFRAMEWORKINSTALLDIR'/s/:.*$/:'',/" \ - -e "/'LDLIBRARY'/s|:.*$|:'libpython${SLOT}.dylib',|" \ - "${libdir}"/_sysconfigdata.py || die - - # add missing version.plist file - mkdir -p "${D}${fwdir}"/Versions/${SLOT}/Resources - cat > "${D}${fwdir}"/Versions/${SLOT}/Resources/version.plist << EOF -<?xml version="1.0" encoding="UTF-8"?> -<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" -"http://www.apple.com/DTDs/PropertyList-1.0.dtd"> -<plist version="1.0"> -<dict> - <key>BuildVersion</key> - <string>1</string> - <key>CFBundleShortVersionString</key> - <string>${PV}</string> - <key>CFBundleVersion</key> - <string>${PV}</string> - <key>ProjectName</key> - <string>Python</string> - <key>SourceVersion</key> - <string>${PV}</string> -</dict> -</plist> -EOF - else - emake DESTDIR="${D}" altinstall - fi - - sed -e "s/\(LDFLAGS=\).*/\1/" -i "${libdir}/config/Makefile" || die "sed failed" - if [[ ${CHOST} == *-aix* ]]; then - # fix upstream bugs with quite large proposed diffs still to be sorted out: - # http://bugs.python.org/issue13493 - # http://bugs.python.org/issue14150 - # http://bugs.python.org/issue15590 - # http://bugs.python.org/issue16189 - sed -e "/Libs:/s|\$| -Wl,-bE:${EPREFIX}/${libdir#$ED}/config/python.exp -lld|" \ - -i "${ED}"usr/$(get_libdir)/pkgconfig/python-${SLOT}.pc || die "sed failed" - sed -e "s|:Modules/python.exp|:${EPREFIX}/${libdir#$ED}/config/python.exp|" \ - -e 's| -bI:| -Wl,-bI:|g' \ - -e '/LINKFORSHARED/s|-bE:|-bI:|g' \ - -e '/LINKFORSHARED/s| -lld||g' \ - -i "${libdir}"/{_sysconfigdata.py,config/Makefile} || die "sed failed" - fi - - # Fix collisions between different slots of Python. - mv "${ED}usr/bin/2to3" "${ED}usr/bin/2to3-${SLOT}" - mv "${ED}usr/bin/pydoc" "${ED}usr/bin/pydoc${SLOT}" - mv "${ED}usr/bin/idle" "${ED}usr/bin/idle${SLOT}" - rm -f "${ED}usr/bin/smtpd.py" - - # http://src.opensolaris.org/source/xref/jds/spec-files/trunk/SUNWPython.spec - # These #defines cause problems when building c99 compliant python modules - # http://bugs.python.org/issue1759169 - [[ ${CHOST} == *-solaris* ]] && sed -i -e \ - 's:^\(^#define \(_POSIX_C_SOURCE\|_XOPEN_SOURCE\|_XOPEN_SOURCE_EXTENDED\).*$\):/* \1 */:' \ - "${ED}"/usr/include/python${SLOT}/pyconfig.h - - use berkdb || rm -r "${libdir}/"{bsddb,dbhash.py,test/test_bsddb*} || die - use sqlite || rm -r "${libdir}/"{sqlite3,test/test_sqlite*} || die - use tk || rm -r "${ED}usr/bin/idle${SLOT}" "${libdir}/"{idlelib,lib-tk} || die - use elibc_uclibc && rm -fr "${libdir}/"{bsddb/test,test} - - use threads || rm -r "${libdir}/multiprocessing" || die - use wininst || rm -r "${libdir}/distutils/command/"wininst-*.exe || die - - dodoc "${S}"/Misc/{ACKS,HISTORY,NEWS} - - if use examples; then - insinto /usr/share/doc/${PF}/examples - doins -r "${S}"/Tools - fi - insinto /usr/share/gdb/auto-load/usr/$(get_libdir) #443510 - local libname - if use aqua ; then - # we do framework, so the emake trick below returns a pathname - # since that won't work here, use a (cheap) trick instead - libname=libpython${SLOT} - else - libname=$(printf 'e:\n\t@echo $(INSTSONAME)\ninclude Makefile\n' | \ - emake --no-print-directory -s -f - 2>/dev/null) - fi - newins "${S}"/Tools/gdb/libpython.py "${libname}"-gdb.py - - newconfd "${FILESDIR}/pydoc.conf" pydoc-${SLOT} - newinitd "${FILESDIR}/pydoc.init" pydoc-${SLOT} - sed \ - -e "s:@PYDOC_PORT_VARIABLE@:PYDOC${SLOT/./_}_PORT:" \ - -e "s:@PYDOC@:pydoc${SLOT}:" \ - -i "${ED}etc/conf.d/pydoc-${SLOT}" "${ED}etc/init.d/pydoc-${SLOT}" || die "sed failed" - - # for python-exec - local vars=( EPYTHON PYTHON_SITEDIR PYTHON_SCRIPTDIR ) - - # if not using a cross-compiler, use the fresh binary - if ! tc-is-cross-compiler; then - local -x PYTHON=./python$(sed -n '/BUILDEXE=/s/^.*=\s\+//p' Makefile) - local -x LD_LIBRARY_PATH=${LD_LIBRARY_PATH+${LD_LIBRARY_PATH}:}. - local -x DYLD_LIBRARY_PATH=${DYLD_LIBRARY_PATH+${DYLD_LIBRARY_PATH}:}. - else - vars=( PYTHON "${vars[@]}" ) - fi - - python_export "python${SLOT}" "${vars[@]}" - echo "EPYTHON='${EPYTHON}'" > epython.py || die - python_domodule epython.py - - # python-exec wrapping support - local pymajor=${SLOT%.*} - mkdir -p "${D}${PYTHON_SCRIPTDIR}" || die - # python and pythonX - ln -s "../../../bin/python${SLOT}" \ - "${D}${PYTHON_SCRIPTDIR}/python${pymajor}" || die - ln -s "python${pymajor}" \ - "${D}${PYTHON_SCRIPTDIR}/python" || die - # python-config and pythonX-config - ln -s "../../../bin/python${SLOT}-config" \ - "${D}${PYTHON_SCRIPTDIR}/python${pymajor}-config" || die - ln -s "python${pymajor}-config" \ - "${D}${PYTHON_SCRIPTDIR}/python-config" || die - # 2to3, pydoc, pyvenv - ln -s "../../../bin/2to3-${SLOT}" \ - "${D}${PYTHON_SCRIPTDIR}/2to3" || die - ln -s "../../../bin/pydoc${SLOT}" \ - "${D}${PYTHON_SCRIPTDIR}/pydoc" || die - # idle - if use tk; then - ln -s "../../../bin/idle${SLOT}" \ - "${D}${PYTHON_SCRIPTDIR}/idle" || die - fi -} - -pkg_preinst() { - if has_version "<${CATEGORY}/${PN}-${SLOT}" && ! has_version "${CATEGORY}/${PN}:2.7"; then - python_updater_warning="1" - fi -} - -eselect_python_update() { - if [[ -z "$(eselect python show)" || ! -f "${EROOT}usr/bin/$(eselect python show)" ]]; then - eselect python update - fi -} - -pkg_postinst() { - eselect_python_update - - if [[ "${python_updater_warning}" == "1" ]]; then - ewarn "You have just upgraded from an older version of Python." - ewarn "You should switch active version of Python ${PV%%.*} and run" - ewarn "'python-updater [options]' to rebuild Python modules." - fi -} - -pkg_postrm() { - eselect_python_update -} diff --git a/dev-lang/python/python-3.4.3-r5.ebuild b/dev-lang/python/python-3.4.3-r5.ebuild deleted file mode 100644 index c304055219..0000000000 --- a/dev-lang/python/python-3.4.3-r5.ebuild +++ /dev/null @@ -1,436 +0,0 @@ -# Copyright 1999-2017 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -EAPI="5" -WANT_LIBTOOL="none" - -inherit autotools eutils flag-o-matic multilib pax-utils python-utils-r1 toolchain-funcs multiprocessing - -MY_P="Python-${PV/_/}" -PATCHSET_VERSION="3.4.3-0" -PREFIX_PATCHREV="r1" -CYGWINPORTS_GITREV="8ee84829be03c2a1aa74f0f095c994c1f43f4688" - -DESCRIPTION="An interpreted, interactive, object-oriented programming language" -HOMEPAGE="http://www.python.org/" -SRC_URI="http://www.python.org/ftp/python/${PV%_rc*}/${MY_P}.tar.xz - https://dev.gentoo.org/~floppym/python/python-gentoo-patches-${PATCHSET_VERSION}.tar.xz - https://dev.gentoo.org/~grobian/distfiles/python-prefix-${PV}-gentoo-patches-${PREFIX_PATCHREV}.tar.xz" - -[[ -n ${CYGWINPORTS_GITREV} ]] && -SRC_URI+=" elibc_Cygwin? ( https://github.com/cygwinports/python3/archive/${CYGWINPORTS_GITREV}.zip )" - -LICENSE="PSF-2" -SLOT="3.4/3.4m" -KEYWORDS="~ppc-aix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" -IUSE="aqua build elibc_uclibc examples gdbm hardened ipv6 libressl +ncurses +readline sqlite +ssl +threads tk wininst +xml" - -# Do not add a dependency on dev-lang/python to this ebuild. -# If you need to apply a patch which requires python for bootstrapping, please -# run the bootstrap code on your dev box and include the results in the -# patchset. See bug 447752. - -RDEPEND="app-arch/bzip2:0= - app-arch/xz-utils:0= - >=sys-libs/zlib-1.1.3:0= - virtual/libffi - virtual/libintl - gdbm? ( sys-libs/gdbm:0=[berkdb] ) - ncurses? ( - >=sys-libs/ncurses-5.2:0= - readline? ( >=sys-libs/readline-4.1:0= ) - ) - sqlite? ( >=dev-db/sqlite-3.3.8:3= ) - ssl? ( - !libressl? ( dev-libs/openssl:0= ) - libressl? ( dev-libs/libressl:= ) - ) - tk? ( - >=dev-lang/tcl-8.0:0= - >=dev-lang/tk-8.0:0=[-aqua] - dev-tcltk/blt:0= - dev-tcltk/tix - ) - xml? ( >=dev-libs/expat-2.1:0= ) - !!<sys-apps/sandbox-2.6-r1" -DEPEND="${RDEPEND} - virtual/pkgconfig - >=sys-devel/autoconf-2.65 - !sys-devel/gcc[libffi]" -RDEPEND+=" !build? ( app-misc/mime-types )" -PDEPEND=">=app-eselect/eselect-python-20151117-r1 - app-admin/python-updater" - -S="${WORKDIR}/${MY_P}" - -PYVER=${SLOT%/*} - -src_prepare() { - # Ensure that internal copies of expat, libffi and zlib are not used. - rm -fr Modules/expat - rm -fr Modules/_ctypes/libffi* - rm -fr Modules/zlib - - if tc-is-cross-compiler; then - # Invokes BUILDPYTHON, which is built for the host arch - local EPATCH_EXCLUDE="*_regenerate_platform-specific_modules.patch" - fi - - EPATCH_SUFFIX="patch" epatch "${WORKDIR}/patches" - epatch "${FILESDIR}/${PN}-3.4.3-ncurses-pkg-config.patch" - epatch "${FILESDIR}/${PN}-3.4-gcc-5.patch" #547626 - epatch "${FILESDIR}/${PN}-3.4-pyfpe-dll.patch" # Cygwin: --with-fpectl - - # Prefix' round of patches - # http://prefix.gentooexperimental.org:8000/python-patches-3_3 - EPATCH_EXCLUDE="${excluded_patches}" EPATCH_SUFFIX="patch" \ - epatch "${WORKDIR}"/python-prefix-${PV}-gentoo-patches-${PREFIX_PATCHREV} - - # https://forums.developer.apple.com/thread/9233, bug #572726 - sed -i -e '/$(RUNSHARED) .\/regen/s/^/export RUNSHARED=$(RUNSHARED); /' \ - Makefile.pre.in || die - sed -i -e '/python$EXE/s/^/env ${RUNSHARED} /' \ - Lib/plat-darwin/regen || die - - # we provide a fully working readline also on Darwin, so don't force - # usage of less functional libedit - sed -i -e 's/__APPLE__/__NO_MUCKING_AROUND__/g' Modules/readline.c || die - - # We may have wrapped /usr/ccs/bin/nm on AIX for long TMPDIR. - sed -i -e "/^NM=.*nm$/s,^.*$,NM=$(tc-getNM)," Modules/makexp_aix || die - - # Make sure python doesn't use the host libffi. - use prefix && epatch "${FILESDIR}/python-3.2-libffi-pkgconfig.patch" - - if [[ -n ${CYGWINPORTS_GITREV} ]] && use elibc_Cygwin; then - local p d="${WORKDIR}/python3-${CYGWINPORTS_GITREV}" - for p in $( - eval "$(sed -ne '/PATCH_URI="/,/"/p' < "${d}"/python3.cygport)" - echo ${PATCH_URI} - ); do - # dropped by 01_all_prefix-no-patch-invention.patch - [[ ${p} == *-tkinter-* ]] && continue - epatch "${d}/${p}" - done - fi - - sed -i -e "s:@@GENTOO_LIBDIR@@:$(get_libdir):g" \ - Lib/distutils/command/install.py \ - Lib/distutils/sysconfig.py \ - Lib/site.py \ - Lib/sysconfig.py \ - Lib/test/test_site.py \ - Makefile.pre.in \ - Modules/Setup.dist \ - Modules/getpath.c \ - setup.py || die "sed failed to replace @@GENTOO_LIBDIR@@" - - # workaround a development build env problem and muck around - # framework install to get the best of both worlds (non-standard) - sed -i \ - -e "s:FRAMEWORKINSTALLAPPSPREFIX=\":FRAMEWORKINSTALLAPPSPREFIX=\"${EPREFIX}:" \ - -e '/RUNSHARED=DYLD_FRAMEWORK_PATH/s/FRAMEWORK/LIBRARY/g' \ - configure.ac configure || die - sed -i -e '/find/s/$/ || true/' Mac/PythonLauncher/Makefile.in || die - - # Disable ABI flags. - sed -e "s/ABIFLAGS=\"\${ABIFLAGS}.*\"/:/" -i configure.ac || die "sed failed" - - epatch_user - - eautoreconf -} - -src_configure() { - local disable - use gdbm || disable+=" gdbm" - use ncurses || disable+=" _curses _curses_panel" - use readline || disable+=" readline" - use sqlite || disable+=" _sqlite3" - use ssl || export PYTHON_DISABLE_SSL="1" - use tk || disable+=" _tkinter" - use xml || disable+=" _elementtree pyexpat" # _elementtree uses pyexpat. - export PYTHON_DISABLE_MODULES="${disable}" - - if ! use xml; then - ewarn "You have configured Python without XML support." - ewarn "This is NOT a recommended configuration as you" - ewarn "may face problems parsing any XML documents." - fi - - if [[ -n "${PYTHON_DISABLE_MODULES}" ]]; then - einfo "Disabled modules: ${PYTHON_DISABLE_MODULES}" - fi - - if [[ "$(gcc-major-version)" -ge 4 ]]; then - append-flags -fwrapv - fi - - filter-flags -malign-double - - [[ "${ARCH}" == "alpha" ]] && append-flags -fPIC - - # https://bugs.gentoo.org/show_bug.cgi?id=50309 - if is-flagq -O3; then - is-flagq -fstack-protector-all && replace-flags -O3 -O2 - use hardened && replace-flags -O3 -O2 - fi - - # Export CC so even AIX will use gcc instead of xlc_r. - # Export CXX so it ends up in /usr/lib/python3.X/config/Makefile. - tc-export CC CXX - - # The configure script fails to use pkg-config correctly. - # http://bugs.python.org/issue15506 - export ac_cv_path_PKG_CONFIG=$(tc-getPKG_CONFIG) - - # Set LDFLAGS so we link modules with -lpython3.2 correctly. - # Needed on FreeBSD unless Python 3.2 is already installed. - # Please query BSD team before removing this! - append-ldflags "-L." - - # make sure setup.py considers Prefix' paths before system ones - use prefix && append-cppflags -I"${EPREFIX}"/usr/include - use prefix && append-ldflags -L"${EPREFIX}"/lib -L"${EPREFIX}"/usr/lib - - local dbmliborder - if use gdbm; then - dbmliborder+="${dbmliborder:+:}gdbm" - fi - - BUILD_DIR="${WORKDIR}/${CHOST}" - mkdir -p "${BUILD_DIR}" || die - cd "${BUILD_DIR}" || die - - if use aqua ; then - ECONF_SOURCE="${S}" OPT="" \ - econf \ - --enable-framework="${EPREFIX}"/usr/lib \ - --config-cache - fi - - # pymalloc #452720 - ECONF_SOURCE="${S}" OPT="" \ - econf \ - $(use aqua && echo --config-cache) \ - --with-fpectl \ - --enable-shared \ - $(use_enable ipv6) \ - $(use_with threads) \ - --infodir='${prefix}/share/info' \ - --mandir='${prefix}/share/man' \ - --with-computed-gotos \ - --with-dbmliborder="${dbmliborder}" \ - --with-libc="" \ - --enable-loadable-sqlite-extensions \ - --with-system-expat \ - --with-system-ffi \ - --without-ensurepip \ - --without-pymalloc - - if use threads && grep -q "#define POSIX_SEMAPHORES_NOT_ENABLED 1" pyconfig.h; then - eerror "configure has detected that the sem_open function is broken." - eerror "Please ensure that /dev/shm is mounted as a tmpfs with mode 1777." - die "Broken sem_open function (bug 496328)" - fi -} - -src_compile() { - # Avoid invoking pgen for cross-compiles. - touch Include/graminit.h Python/graminit.c || die - - cd "${BUILD_DIR}" || die - - emake CPPFLAGS= CFLAGS= LDFLAGS= - - # Work around bug 329499. See also bug 413751 and 457194. - if has_version dev-libs/libffi[pax_kernel]; then - pax-mark E python - else - pax-mark m python - fi -} - -src_test() { - # Tests will not work when cross compiling. - if tc-is-cross-compiler; then - elog "Disabling tests due to crosscompiling." - return - fi - - cd "${BUILD_DIR}" || die - - # Skip failing tests. - local skipped_tests="gdb" - - for test in ${skipped_tests}; do - mv "${S}"/Lib/test/test_${test}.py "${T}" - done - - local -x PYTHONDONTWRITEBYTECODE= - emake test EXTRATESTOPTS="-u-network" CPPFLAGS= CFLAGS= LDFLAGS= < /dev/tty - local result=$? - - for test in ${skipped_tests}; do - mv "${T}/test_${test}.py" "${S}"/Lib/test - done - - elog "The following tests have been skipped:" - for test in ${skipped_tests}; do - elog "test_${test}.py" - done - - elog "If you would like to run them, you may:" - elog "cd '${EPREFIX}/usr/$(get_libdir)/python${PYVER}/test'" - elog "and run the tests separately." - - if [[ ${result} -ne 0 ]]; then - die "emake test failed" - fi -} - -src_install() { - local libdir=${ED}/usr/$(get_libdir)/python${PYVER} - - cd "${BUILD_DIR}" || die - - emake DESTDIR="${D}" altinstall - - if use aqua ; then - # avoid config.status to be triggered - find Mac -name "Makefile" -exec touch \{\} + || die - - # Python_Launcher is kind of a wrapper, and we should fix it for - # Prefix (it uses /usr/bin/pythonw) so useless - # IDLE doesn't run, no idea, but definitely not used - emake DESTDIR="${D}" -C Mac install_Python || die - rmdir "${ED}"/Applications/Python* || die - rmdir "${ED}"/Applications || die - - local fwdir=/usr/$(get_libdir)/Python.framework/Versions/${PYVER} - ln -s "${EPREFIX}"/usr/include/python${PYVER} \ - "${ED}${fwdir}"/Headers || die - ln -s "${EPREFIX}"/usr/lib/libpython${PYVER}.dylib \ - "${ED}${fwdir}"/Python || die - fi - - sed \ - -e "s/\(CONFIGURE_LDFLAGS=\).*/\1/" \ - -e "s/\(PY_LDFLAGS=\).*/\1/" \ - -i "${libdir}/config-${PYVER}"*/Makefile || die "sed failed" - - # Fix collisions between different slots of Python. - rm -f "${ED}usr/$(get_libdir)/libpython3.so" - - # Cheap hack to get version with ABIFLAGS - local abiver=$(cd "${ED}usr/include"; echo python*) - # Replace python3.X with a symlink if appropriate - if [[ ${abiver} != python${PYVER} ]]; then - rm "${ED}usr/bin/python${PYVER}" || die - dosym "${abiver}" "/usr/bin/python${PYVER}" - fi - - use elibc_uclibc && rm -fr "${libdir}/test" - use sqlite || rm -fr "${libdir}/"{sqlite3,test/test_sqlite*} - use tk || rm -fr "${ED}usr/bin/idle${PYVER}" "${libdir}/"{idlelib,tkinter,test/test_tk*} - - use threads || rm -fr "${libdir}/multiprocessing" - use wininst || rm -f "${libdir}/distutils/command/"wininst-*.exe - - dodoc "${S}"/Misc/{ACKS,HISTORY,NEWS} - - if use examples; then - insinto /usr/share/doc/${PF}/examples - find "${S}"/Tools -name __pycache__ -print0 | xargs -0 rm -fr - doins -r "${S}"/Tools - fi - insinto /usr/share/gdb/auto-load/usr/$(get_libdir) #443510 - if use aqua ; then - # we do framework, so the emake trick below returns a pathname - # since that won't work here, use a (cheap) trick instead - local libname=libpython${PYVER} - else - local libname=$(printf 'e:\n\t@echo $(INSTSONAME)\ninclude Makefile\n' | \ - emake --no-print-directory -s -f - 2>/dev/null) - fi - newins "${S}"/Tools/gdb/libpython.py "${libname}"-gdb.py - - newconfd "${FILESDIR}/pydoc.conf" pydoc-${PYVER} - newinitd "${FILESDIR}/pydoc.init" pydoc-${PYVER} - sed \ - -e "s:@PYDOC_PORT_VARIABLE@:PYDOC${PYVER/./_}_PORT:" \ - -e "s:@PYDOC@:pydoc${PYVER}:" \ - -i "${ED}etc/conf.d/pydoc-${PYVER}" "${ED}etc/init.d/pydoc-${PYVER}" || die "sed failed" - - # for python-exec - local vars=( EPYTHON PYTHON_SITEDIR PYTHON_SCRIPTDIR ) - - # if not using a cross-compiler, use the fresh binary - if ! tc-is-cross-compiler; then - local -x PYTHON=./python$(sed -n '/BUILDEXE=/s/^.*=\s\+//p' Makefile) - local -x LD_LIBRARY_PATH=${LD_LIBRARY_PATH+${LD_LIBRARY_PATH}:}. - local -x DYLD_LIBRARY_PATH=${DYLD_LIBRARY_PATH+${DYLD_LIBRARY_PATH}:}. - else - vars=( PYTHON "${vars[@]}" ) - fi - - python_export "python${PYVER}" "${vars[@]}" - echo "EPYTHON='${EPYTHON}'" > epython.py || die - python_domodule epython.py - - # python-exec wrapping support - local pymajor=${PYVER%.*} - mkdir -p "${D}${PYTHON_SCRIPTDIR}" || die - # python and pythonX - ln -s "../../../bin/${abiver}" \ - "${D}${PYTHON_SCRIPTDIR}/python${pymajor}" || die - ln -s "python${pymajor}" \ - "${D}${PYTHON_SCRIPTDIR}/python" || die - # python-config and pythonX-config - ln -s "../../../bin/${abiver}-config" \ - "${D}${PYTHON_SCRIPTDIR}/python${pymajor}-config" || die - ln -s "python${pymajor}-config" \ - "${D}${PYTHON_SCRIPTDIR}/python-config" || die - # 2to3, pydoc, pyvenv - ln -s "../../../bin/2to3-${PYVER}" \ - "${D}${PYTHON_SCRIPTDIR}/2to3" || die - ln -s "../../../bin/pydoc${PYVER}" \ - "${D}${PYTHON_SCRIPTDIR}/pydoc" || die - ln -s "../../../bin/pyvenv-${PYVER}" \ - "${D}${PYTHON_SCRIPTDIR}/pyvenv" || die - - # Compatibility link for stuff that calls ${PYTHON}-config - # Remove this when all revdeps have been fixed to not do that. - dosym "${abiver}-config" "/usr/bin/python${PYVER}-config" -} - -pkg_preinst() { - if has_version "<${CATEGORY}/${PN}-${PYVER}" && ! has_version ">=${CATEGORY}/${PN}-${PYVER}_alpha"; then - python_updater_warning="1" - fi -} - -eselect_python_update() { - if [[ -z "$(eselect python show)" || ! -f "${EROOT}usr/bin/$(eselect python show)" ]]; then - eselect python update - fi - - if [[ -z "$(eselect python show --python${PV%%.*})" || ! -f "${EROOT}usr/bin/$(eselect python show --python${PV%%.*})" ]]; then - eselect python update --python${PV%%.*} - fi -} - -pkg_postinst() { - eselect_python_update - - if [[ "${python_updater_warning}" == "1" ]]; then - ewarn "You have just upgraded from an older version of Python." - ewarn - ewarn "Please adjust PYTHON_TARGETS (if so desired), and run emerge with the --newuse or --changed-use option to rebuild packages installing python modules." - fi -} - -pkg_postrm() { - eselect_python_update -} diff --git a/dev-lang/python/python-3.5.1-r3.ebuild b/dev-lang/python/python-3.5.1-r3.ebuild deleted file mode 100644 index 6072313117..0000000000 --- a/dev-lang/python/python-3.5.1-r3.ebuild +++ /dev/null @@ -1,434 +0,0 @@ -# Copyright 1999-2017 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -EAPI="5" -WANT_LIBTOOL="none" - -inherit autotools eutils flag-o-matic multilib pax-utils python-utils-r1 toolchain-funcs - -MY_P="Python-${PV/_/}" -PATCHSET_VERSION="3.5.1-0" -PREFIX_PATCHREV="r2" - -DESCRIPTION="An interpreted, interactive, object-oriented programming language" -HOMEPAGE="http://www.python.org/" -SRC_URI="http://www.python.org/ftp/python/${PV%_rc*}/${MY_P}.tar.xz - https://dev.gentoo.org/~floppym/python/python-gentoo-patches-${PATCHSET_VERSION}.tar.xz - https://dev.gentoo.org/~grobian/distfiles/python-prefix-${PV}-gentoo-patches-${PREFIX_PATCHREV}.tar.xz" - -LICENSE="PSF-2" -SLOT="3.5/3.5m" -KEYWORDS="~ppc-aix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" -IUSE="aqua build elibc_uclibc examples gdbm hardened ipv6 libressl +ncurses +readline sqlite +ssl +threads tk wininst +xml" - -# Do not add a dependency on dev-lang/python to this ebuild. -# If you need to apply a patch which requires python for bootstrapping, please -# run the bootstrap code on your dev box and include the results in the -# patchset. See bug 447752. - -RDEPEND="app-arch/bzip2:0= - app-arch/xz-utils:0= - >=sys-libs/zlib-1.1.3:0= - virtual/libffi - virtual/libintl - gdbm? ( sys-libs/gdbm:0=[berkdb] ) - ncurses? ( - >=sys-libs/ncurses-5.2:0= - readline? ( >=sys-libs/readline-4.1:0= ) - ) - sqlite? ( >=dev-db/sqlite-3.3.8:3= ) - ssl? ( - !libressl? ( dev-libs/openssl:0= ) - libressl? ( dev-libs/libressl:= ) - ) - tk? ( - >=dev-lang/tcl-8.0:0= - >=dev-lang/tk-8.0:0=[-aqua] - dev-tcltk/blt:0= - dev-tcltk/tix - ) - xml? ( >=dev-libs/expat-2.1:0= ) - !!<sys-apps/sandbox-2.6-r1" -DEPEND="${RDEPEND} - virtual/pkgconfig - !sys-devel/gcc[libffi(-)]" -RDEPEND+=" !build? ( app-misc/mime-types )" -PDEPEND=">=app-eselect/eselect-python-20140125-r1" - -S="${WORKDIR}/${MY_P}" - -PYVER=${SLOT%/*} - -src_prepare() { - # Ensure that internal copies of expat, libffi and zlib are not used. - rm -fr Modules/expat - rm -fr Modules/_ctypes/libffi* - rm -fr Modules/zlib - - if tc-is-cross-compiler; then - # Invokes BUILDPYTHON, which is built for the host arch - local EPATCH_EXCLUDE="*_regenerate_platform-specific_modules.patch" - fi - - EPATCH_SUFFIX="patch" epatch "${WORKDIR}/patches" - epatch "${FILESDIR}/${PN}-3.4.3-ncurses-pkg-config.patch" - epatch "${FILESDIR}/3.5.1-cross-compile.patch" - epatch "${FILESDIR}/${PN}-3.5-distutils-OO-build.patch" - - epatch_user - - # Prefix' round of patches - # http://prefix.gentooexperimental.org:8000/python-patches-3_3 - EPATCH_EXCLUDE="${excluded_patches}" EPATCH_SUFFIX="patch" \ - epatch "${WORKDIR}"/python-prefix-${PV}-gentoo-patches-${PREFIX_PATCHREV} - - # https://forums.developer.apple.com/thread/9233, bug #572726 - sed -i -e '/$(RUNSHARED) .\/regen/s/^/export RUNSHARED=$(RUNSHARED); /' \ - Makefile.pre.in || die - sed -i -e '/python$EXE/s/^/env ${RUNSHARED} /' \ - Lib/plat-darwin/regen || die - - # we provide a fully working readline also on Darwin, so don't force - # usage of less functional libedit - sed -i -e 's/__APPLE__/__NO_MUCKING_AROUND__/g' Modules/readline.c || die - - # We may have wrapped /usr/ccs/bin/nm on AIX for long TMPDIR. - sed -i -e "/^NM=.*nm$/s,^.*$,NM=$(tc-getNM)," Modules/makexp_aix || die - - # Make sure python doesn't use the host libffi. - use prefix && epatch "${FILESDIR}/python-3.2-libffi-pkgconfig.patch" - - sed -i -e "s:@@GENTOO_LIBDIR@@:$(get_libdir):g" \ - configure.ac \ - Lib/distutils/command/install.py \ - Lib/distutils/sysconfig.py \ - Lib/site.py \ - Lib/sysconfig.py \ - Lib/test/test_site.py \ - Makefile.pre.in \ - Modules/getpath.c \ - Modules/Setup.dist \ - setup.py || die "sed failed to replace @@GENTOO_LIBDIR@@" - - # workaround a development build env problem and muck around - # framework install to get the best of both worlds (non-standard) - sed -i \ - -e "s:FRAMEWORKINSTALLAPPSPREFIX=\":FRAMEWORKINSTALLAPPSPREFIX=\"${EPREFIX}:" \ - -e '/RUNSHARED=DYLD_FRAMEWORK_PATH/s/FRAMEWORK/LIBRARY/g' \ - configure.ac configure || die - sed -i -e '/find/s/$/ || true/' Mac/PythonLauncher/Makefile.in || die - - # Disable ABI flags. - sed -e "s/ABIFLAGS=\"\${ABIFLAGS}.*\"/:/" -i configure.ac || die "sed failed" - - eautoreconf -} - -src_configure() { - local disable - use gdbm || disable+=" gdbm" - use ncurses || disable+=" _curses _curses_panel" - use readline || disable+=" readline" - use sqlite || disable+=" _sqlite3" - use ssl || export PYTHON_DISABLE_SSL="1" - use tk || disable+=" _tkinter" - use xml || disable+=" _elementtree pyexpat" # _elementtree uses pyexpat. - export PYTHON_DISABLE_MODULES="${disable}" - - if ! use xml; then - ewarn "You have configured Python without XML support." - ewarn "This is NOT a recommended configuration as you" - ewarn "may face problems parsing any XML documents." - fi - - if [[ -n "${PYTHON_DISABLE_MODULES}" ]]; then - einfo "Disabled modules: ${PYTHON_DISABLE_MODULES}" - fi - - if [[ "$(gcc-major-version)" -ge 4 ]]; then - append-flags -fwrapv - fi - - filter-flags -malign-double - - # https://bugs.gentoo.org/show_bug.cgi?id=50309 - if is-flagq -O3; then - is-flagq -fstack-protector-all && replace-flags -O3 -O2 - use hardened && replace-flags -O3 -O2 - fi - - # Export CC so even AIX will use gcc instead of xlc_r. - # Export CXX so it ends up in /usr/lib/python3.X/config/Makefile. - tc-export CC CXX - - # The configure script fails to use pkg-config correctly. - # http://bugs.python.org/issue15506 - export ac_cv_path_PKG_CONFIG=$(tc-getPKG_CONFIG) - - # Set LDFLAGS so we link modules with -lpython3.2 correctly. - # Needed on FreeBSD unless Python 3.2 is already installed. - # Please query BSD team before removing this! - append-ldflags "-L." - - # make sure setup.py considers Prefix' paths before system ones - use prefix && append-cppflags -I"${EPREFIX}"/usr/include - use prefix && append-ldflags -L"${EPREFIX}"/lib -L"${EPREFIX}"/usr/lib - - local dbmliborder - if use gdbm; then - dbmliborder+="${dbmliborder:+:}gdbm" - fi - - BUILD_DIR="${WORKDIR}/${CHOST}" - mkdir -p "${BUILD_DIR}" || die - cd "${BUILD_DIR}" || die - - if use aqua ; then - ECONF_SOURCE="${S}" OPT="" \ - econf \ - --enable-framework="${EPREFIX}"/usr/lib \ - --config-cache - fi - - # pymalloc #452720 - local myeconfargs=( - $(use aqua && echo --config-cache) \ - --with-fpectl - --enable-shared - $(use_enable ipv6) - $(use_with threads) - --infodir='${prefix}/share/info' - --mandir='${prefix}/share/man' - --with-computed-gotos - --with-dbmliborder="${dbmliborder}" - --with-libc= - --enable-loadable-sqlite-extensions - --without-ensurepip - --with-system-expat - --with-system-ffi - --without-pymalloc - ) - - ECONF_SOURCE="${S}" OPT="" econf "${myeconfargs[@]}" - - if use threads && grep -q "#define POSIX_SEMAPHORES_NOT_ENABLED 1" pyconfig.h; then - eerror "configure has detected that the sem_open function is broken." - eerror "Please ensure that /dev/shm is mounted as a tmpfs with mode 1777." - die "Broken sem_open function (bug 496328)" - fi -} - -src_compile() { - cd "${BUILD_DIR}" || die - - emake CPPFLAGS= CFLAGS= LDFLAGS= - - # Work around bug 329499. See also bug 413751 and 457194. - if has_version dev-libs/libffi[pax_kernel]; then - pax-mark E python - else - pax-mark m python - fi -} - -src_test() { - # Tests will not work when cross compiling. - if tc-is-cross-compiler; then - elog "Disabling tests due to crosscompiling." - return - fi - - cd "${BUILD_DIR}" || die - - # Skip failing tests. - local skipped_tests="gdb" - - for test in ${skipped_tests}; do - mv "${S}"/Lib/test/test_${test}.py "${T}" - done - - local -x PYTHONDONTWRITEBYTECODE= - emake test EXTRATESTOPTS="-u-network" CPPFLAGS= CFLAGS= LDFLAGS= < /dev/tty - local result=$? - - for test in ${skipped_tests}; do - mv "${T}/test_${test}.py" "${S}"/Lib/test - done - - elog "The following tests have been skipped:" - for test in ${skipped_tests}; do - elog "test_${test}.py" - done - - elog "If you would like to run them, you may:" - elog "cd '${EPREFIX}/usr/$(get_libdir)/python${PYVER}/test'" - elog "and run the tests separately." - - if [[ ${result} -ne 0 ]]; then - die "emake test failed" - fi -} - -src_install() { - local libdir=${ED}/usr/$(get_libdir)/python${PYVER} - - cd "${BUILD_DIR}" || die - - emake DESTDIR="${D}" altinstall - - if use aqua ; then - # avoid config.status to be triggered - find Mac -name "Makefile" -exec touch \{\} + || die - - # Python_Launcher is kind of a wrapper, and we should fix it for - # Prefix (it uses /usr/bin/pythonw) so useless - # IDLE doesn't run, no idea, but definitely not used - emake DESTDIR="${D}" -C Mac install_Python || die - rmdir "${ED}"/Applications/Python* || die - rmdir "${ED}"/Applications || die - - local fwdir=/usr/$(get_libdir)/Python.framework/Versions/${PYVER} - ln -s "${EPREFIX}"/usr/include/python${PYVER} \ - "${ED}${fwdir}"/Headers || die - ln -s "${EPREFIX}"/usr/lib/libpython${PYVER}.dylib \ - "${ED}${fwdir}"/Python || die - fi - - sed \ - -e "s/\(CONFIGURE_LDFLAGS=\).*/\1/" \ - -e "s/\(PY_LDFLAGS=\).*/\1/" \ - -i "${libdir}/config-${PYVER}"*/Makefile || die "sed failed" - - # Fix collisions between different slots of Python. - rm -f "${ED}usr/$(get_libdir)/libpython3.so" - - # Cheap hack to get version with ABIFLAGS - local abiver=$(cd "${ED}usr/include"; echo python*) - if [[ ${abiver} != python${PYVER} ]]; then - # Replace python3.X with a symlink to python3.Xm - rm "${ED}usr/bin/python${PYVER}" || die - dosym "${abiver}" "/usr/bin/python${PYVER}" - # Create python3.X-config symlink - dosym "${abiver}-config" "/usr/bin/python${PYVER}-config" - # Create python-3.5m.pc symlink - dosym "python-${PYVER}.pc" "/usr/$(get_libdir)/pkgconfig/${abiver/${PYVER}/-${PYVER}}.pc" - fi - - # python seems to get rebuilt in src_install (bug 569908) - # Work around it for now. - if has_version dev-libs/libffi[pax_kernel]; then - pax-mark E "${ED}usr/bin/${abiver}" - else - pax-mark m "${ED}usr/bin/${abiver}" - fi - - use elibc_uclibc && rm -fr "${libdir}/test" - use sqlite || rm -fr "${libdir}/"{sqlite3,test/test_sqlite*} - use tk || rm -fr "${ED}usr/bin/idle${PYVER}" "${libdir}/"{idlelib,tkinter,test/test_tk*} - - use threads || rm -fr "${libdir}/multiprocessing" - use wininst || rm -f "${libdir}/distutils/command/"wininst-*.exe - - dodoc "${S}"/Misc/{ACKS,HISTORY,NEWS} - - if use examples; then - insinto /usr/share/doc/${PF}/examples - find "${S}"/Tools -name __pycache__ -print0 | xargs -0 rm -fr - doins -r "${S}"/Tools - fi - insinto /usr/share/gdb/auto-load/usr/$(get_libdir) #443510 - if use aqua ; then - # we do framework, so the emake trick below returns a pathname - # since that won't work here, use a (cheap) trick instead - local libname=libpython${PYVER} - else - local libname=$(printf 'e:\n\t@echo $(INSTSONAME)\ninclude Makefile\n' | \ - emake --no-print-directory -s -f - 2>/dev/null) - fi - newins "${S}"/Tools/gdb/libpython.py "${libname}"-gdb.py - - newconfd "${FILESDIR}/pydoc.conf" pydoc-${PYVER} - newinitd "${FILESDIR}/pydoc.init" pydoc-${PYVER} - sed \ - -e "s:@PYDOC_PORT_VARIABLE@:PYDOC${PYVER/./_}_PORT:" \ - -e "s:@PYDOC@:pydoc${PYVER}:" \ - -i "${ED}etc/conf.d/pydoc-${PYVER}" "${ED}etc/init.d/pydoc-${PYVER}" || die "sed failed" - - # for python-exec - local vars=( EPYTHON PYTHON_SITEDIR PYTHON_SCRIPTDIR ) - - # if not using a cross-compiler, use the fresh binary - if ! tc-is-cross-compiler; then - local -x PYTHON=./python$(sed -n '/BUILDEXE=/s/^.*=\s\+//p' Makefile) - local -x LD_LIBRARY_PATH=${LD_LIBRARY_PATH+${LD_LIBRARY_PATH}:}. - local -x DYLD_LIBRARY_PATH=${DYLD_LIBRARY_PATH+${DYLD_LIBRARY_PATH}:}. - else - vars=( PYTHON "${vars[@]}" ) - fi - - python_export "python${PYVER}" "${vars[@]}" - echo "EPYTHON='${EPYTHON}'" > epython.py || die - python_domodule epython.py - - # python-exec wrapping support - local pymajor=${PYVER%.*} - mkdir -p "${D}${PYTHON_SCRIPTDIR}" || die - # python and pythonX - ln -s "../../../bin/${abiver}" \ - "${D}${PYTHON_SCRIPTDIR}/python${pymajor}" || die - ln -s "python${pymajor}" \ - "${D}${PYTHON_SCRIPTDIR}/python" || die - # python-config and pythonX-config - # note: we need to create a wrapper rather than symlinking it due - # to some random dirname(argv[0]) magic performed by python-config - cat > "${D}${PYTHON_SCRIPTDIR}/python${pymajor}-config" <<-EOF || die - #!/bin/sh - exec "${abiver}-config" "\${@}" - EOF - chmod +x "${D}${PYTHON_SCRIPTDIR}/python${pymajor}-config" || die - ln -s "python${pymajor}-config" \ - "${D}${PYTHON_SCRIPTDIR}/python-config" || die - # 2to3, pydoc, pyvenv - ln -s "../../../bin/2to3-${PYVER}" \ - "${D}${PYTHON_SCRIPTDIR}/2to3" || die - ln -s "../../../bin/pydoc${PYVER}" \ - "${D}${PYTHON_SCRIPTDIR}/pydoc" || die - ln -s "../../../bin/pyvenv-${PYVER}" \ - "${D}${PYTHON_SCRIPTDIR}/pyvenv" || die - # idle - if use tk; then - ln -s "../../../bin/idle${PYVER}" \ - "${D}${PYTHON_SCRIPTDIR}/idle" || die - fi -} - -pkg_preinst() { - if has_version "<${CATEGORY}/${PN}-${PYVER}" && ! has_version ">=${CATEGORY}/${PN}-${PYVER}_alpha"; then - python_updater_warning="1" - fi -} - -eselect_python_update() { - if [[ -z "$(eselect python show)" || ! -f "${EROOT}usr/bin/$(eselect python show)" ]]; then - eselect python update - fi - - if [[ -z "$(eselect python show --python${PV%%.*})" || ! -f "${EROOT}usr/bin/$(eselect python show --python${PV%%.*})" ]]; then - eselect python update --python${PV%%.*} - fi -} - -pkg_postinst() { - eselect_python_update - - if [[ "${python_updater_warning}" == "1" ]]; then - ewarn "You have just upgraded from an older version of Python." - ewarn - ewarn "Please adjust PYTHON_TARGETS (if so desired), and run emerge with the --newuse or --changed-use option to rebuild packages installing python modules." - fi -} - -pkg_postrm() { - eselect_python_update -} diff --git a/dev-lang/python/python-3.5.2.ebuild b/dev-lang/python/python-3.5.2.ebuild deleted file mode 100644 index 8177eedee6..0000000000 --- a/dev-lang/python/python-3.5.2.ebuild +++ /dev/null @@ -1,437 +0,0 @@ -# Copyright 1999-2017 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -EAPI="5" -WANT_LIBTOOL="none" - -inherit autotools eutils flag-o-matic multilib pax-utils python-utils-r1 toolchain-funcs - -MY_P="Python-${PV/_/}" -PATCHSET_VERSION="3.5.2-0" -PREFIX_PATCHREV="r0" - -DESCRIPTION="An interpreted, interactive, object-oriented programming language" -HOMEPAGE="http://www.python.org/" -SRC_URI="http://www.python.org/ftp/python/${PV%_rc*}/${MY_P}.tar.xz - https://dev.gentoo.org/~floppym/python/python-gentoo-patches-${PATCHSET_VERSION}.tar.xz - https://dev.gentoo.org/~grobian/distfiles/python-prefix-${PV}-gentoo-patches-${PREFIX_PATCHREV}.tar.xz" - -LICENSE="PSF-2" -SLOT="3.5/3.5m" -KEYWORDS="~ppc-aix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" -IUSE="aqua build elibc_uclibc examples gdbm hardened ipv6 libressl +ncurses +readline sqlite +ssl +threads tk wininst +xml" - -# Do not add a dependency on dev-lang/python to this ebuild. -# If you need to apply a patch which requires python for bootstrapping, please -# run the bootstrap code on your dev box and include the results in the -# patchset. See bug 447752. - -RDEPEND="app-arch/bzip2:0= - app-arch/xz-utils:0= - >=sys-libs/zlib-1.1.3:0= - virtual/libffi - virtual/libintl - gdbm? ( sys-libs/gdbm:0=[berkdb] ) - ncurses? ( - >=sys-libs/ncurses-5.2:0= - readline? ( >=sys-libs/readline-4.1:0= ) - ) - sqlite? ( >=dev-db/sqlite-3.3.8:3= ) - ssl? ( - !libressl? ( dev-libs/openssl:0= ) - libressl? ( dev-libs/libressl:= ) - ) - tk? ( - >=dev-lang/tcl-8.0:0= - >=dev-lang/tk-8.0:0=[-aqua] - dev-tcltk/blt:0= - dev-tcltk/tix - ) - xml? ( >=dev-libs/expat-2.1:0= ) - !!<sys-apps/sandbox-2.6-r1" -DEPEND="${RDEPEND} - virtual/pkgconfig - !sys-devel/gcc[libffi(-)]" -RDEPEND+=" !build? ( app-misc/mime-types )" -PDEPEND=">=app-eselect/eselect-python-20140125-r1" - -S="${WORKDIR}/${MY_P}" - -PYVER=${SLOT%/*} - -src_prepare() { - # Ensure that internal copies of expat, libffi and zlib are not used. - rm -fr Modules/expat - rm -fr Modules/_ctypes/libffi* - rm -fr Modules/zlib - - if tc-is-cross-compiler; then - # Invokes BUILDPYTHON, which is built for the host arch - local EPATCH_EXCLUDE="*_regenerate_platform-specific_modules.patch" - fi - - EPATCH_SUFFIX="patch" epatch "${WORKDIR}/patches" - epatch "${FILESDIR}/${PN}-3.4.3-ncurses-pkg-config.patch" - epatch "${FILESDIR}/${PN}-3.5-distutils-OO-build.patch" - - epatch_user - - # Prefix' round of patches - # http://prefix.gentooexperimental.org:8000/python-patches-3_3 - EPATCH_EXCLUDE="${excluded_patches}" EPATCH_SUFFIX="patch" \ - epatch "${WORKDIR}"/python-prefix-${PV}-gentoo-patches-${PREFIX_PATCHREV} - - # https://forums.developer.apple.com/thread/9233, bug #572726 - sed -i -e '/$(RUNSHARED) .\/regen/s/^/export RUNSHARED=$(RUNSHARED); /' \ - Makefile.pre.in || die - sed -i -e '/python$EXE/s/^/env ${RUNSHARED} /' \ - Lib/plat-darwin/regen || die - - # we provide a fully working readline also on Darwin, so don't force - # usage of less functional libedit - sed -i -e 's/__APPLE__/__NO_MUCKING_AROUND__/g' Modules/readline.c || die - - # We may have wrapped /usr/ccs/bin/nm on AIX for long TMPDIR. - sed -i -e "/^NM=.*nm$/s,^.*$,NM=$(tc-getNM)," Modules/makexp_aix || die - - # Make sure python doesn't use the host libffi. - use prefix && epatch "${FILESDIR}/python-3.2-libffi-pkgconfig.patch" - - sed -i -e "s:@@GENTOO_LIBDIR@@:$(get_libdir):g" \ - configure.ac \ - Lib/distutils/command/install.py \ - Lib/distutils/sysconfig.py \ - Lib/site.py \ - Lib/sysconfig.py \ - Lib/test/test_site.py \ - Makefile.pre.in \ - Modules/getpath.c \ - Modules/Setup.dist \ - setup.py || die "sed failed to replace @@GENTOO_LIBDIR@@" - - # workaround a development build env problem and muck around - # framework install to get the best of both worlds (non-standard) - sed -i \ - -e "s:FRAMEWORKINSTALLAPPSPREFIX=\":FRAMEWORKINSTALLAPPSPREFIX=\"${EPREFIX}:" \ - -e '/RUNSHARED=DYLD_FRAMEWORK_PATH/s/FRAMEWORK/LIBRARY/g' \ - configure.ac configure || die - sed -i -e '/find/s/$/ || true/' Mac/PythonLauncher/Makefile.in || die - - # Disable ABI flags. - sed -e "s/ABIFLAGS=\"\${ABIFLAGS}.*\"/:/" -i configure.ac || die "sed failed" - - eautoreconf -} - -src_configure() { - local disable - use gdbm || disable+=" gdbm" - use ncurses || disable+=" _curses _curses_panel" - use readline || disable+=" readline" - use sqlite || disable+=" _sqlite3" - use ssl || export PYTHON_DISABLE_SSL="1" - use tk || disable+=" _tkinter" - use xml || disable+=" _elementtree pyexpat" # _elementtree uses pyexpat. - export PYTHON_DISABLE_MODULES="${disable}" - - if ! use xml; then - ewarn "You have configured Python without XML support." - ewarn "This is NOT a recommended configuration as you" - ewarn "may face problems parsing any XML documents." - fi - - if [[ -n "${PYTHON_DISABLE_MODULES}" ]]; then - einfo "Disabled modules: ${PYTHON_DISABLE_MODULES}" - fi - - if [[ "$(gcc-major-version)" -ge 4 ]]; then - append-flags -fwrapv - fi - - filter-flags -malign-double - - # https://bugs.gentoo.org/show_bug.cgi?id=50309 - if is-flagq -O3; then - is-flagq -fstack-protector-all && replace-flags -O3 -O2 - use hardened && replace-flags -O3 -O2 - fi - - # Export CC so even AIX will use gcc instead of xlc_r. - # Export CXX so it ends up in /usr/lib/python3.X/config/Makefile. - tc-export CC CXX - - # The configure script fails to use pkg-config correctly. - # http://bugs.python.org/issue15506 - export ac_cv_path_PKG_CONFIG=$(tc-getPKG_CONFIG) - - # Set LDFLAGS so we link modules with -lpython3.2 correctly. - # Needed on FreeBSD unless Python 3.2 is already installed. - # Please query BSD team before removing this! - append-ldflags "-L." - - # make sure setup.py considers Prefix' paths before system ones - use prefix && append-cppflags -I"${EPREFIX}"/usr/include - use prefix && append-ldflags -L"${EPREFIX}"/lib -L"${EPREFIX}"/usr/lib - - local dbmliborder - if use gdbm; then - dbmliborder+="${dbmliborder:+:}gdbm" - fi - - BUILD_DIR="${WORKDIR}/${CHOST}" - mkdir -p "${BUILD_DIR}" || die - cd "${BUILD_DIR}" || die - - if use aqua ; then - ECONF_SOURCE="${S}" OPT="" \ - econf \ - --enable-framework="${EPREFIX}"/usr/lib \ - --config-cache - fi - - # pymalloc #452720 - local myeconfargs=( - $(use aqua && echo --config-cache) \ - --with-fpectl - --enable-shared - $(use_enable ipv6) - $(use_with threads) - --infodir='${prefix}/share/info' - --mandir='${prefix}/share/man' - --with-computed-gotos - --with-dbmliborder="${dbmliborder}" - --with-libc= - --enable-loadable-sqlite-extensions - --without-ensurepip - --with-system-expat - --with-system-ffi - --without-pymalloc - ) - - ECONF_SOURCE="${S}" OPT="" econf "${myeconfargs[@]}" - - if use threads && grep -q "#define POSIX_SEMAPHORES_NOT_ENABLED 1" pyconfig.h; then - eerror "configure has detected that the sem_open function is broken." - eerror "Please ensure that /dev/shm is mounted as a tmpfs with mode 1777." - die "Broken sem_open function (bug 496328)" - fi -} - -src_compile() { - # Ensure sed works as expected - # https://bugs.gentoo.org/594768 - local -x LC_ALL=C - - cd "${BUILD_DIR}" || die - - emake CPPFLAGS= CFLAGS= LDFLAGS= - - # Work around bug 329499. See also bug 413751 and 457194. - if has_version dev-libs/libffi[pax_kernel]; then - pax-mark E python - else - pax-mark m python - fi -} - -src_test() { - # Tests will not work when cross compiling. - if tc-is-cross-compiler; then - elog "Disabling tests due to crosscompiling." - return - fi - - cd "${BUILD_DIR}" || die - - # Skip failing tests. - local skipped_tests="gdb" - - for test in ${skipped_tests}; do - mv "${S}"/Lib/test/test_${test}.py "${T}" - done - - local -x PYTHONDONTWRITEBYTECODE= - emake test EXTRATESTOPTS="-u-network" CPPFLAGS= CFLAGS= LDFLAGS= < /dev/tty - local result=$? - - for test in ${skipped_tests}; do - mv "${T}/test_${test}.py" "${S}"/Lib/test - done - - elog "The following tests have been skipped:" - for test in ${skipped_tests}; do - elog "test_${test}.py" - done - - elog "If you would like to run them, you may:" - elog "cd '${EPREFIX}/usr/$(get_libdir)/python${PYVER}/test'" - elog "and run the tests separately." - - if [[ ${result} -ne 0 ]]; then - die "emake test failed" - fi -} - -src_install() { - local libdir=${ED}/usr/$(get_libdir)/python${PYVER} - - cd "${BUILD_DIR}" || die - - emake DESTDIR="${D}" altinstall - - if use aqua ; then - # avoid config.status to be triggered - find Mac -name "Makefile" -exec touch \{\} + || die - - # Python_Launcher is kind of a wrapper, and we should fix it for - # Prefix (it uses /usr/bin/pythonw) so useless - # IDLE doesn't run, no idea, but definitely not used - emake DESTDIR="${D}" -C Mac install_Python || die - rmdir "${ED}"/Applications/Python* || die - rmdir "${ED}"/Applications || die - - local fwdir=/usr/$(get_libdir)/Python.framework/Versions/${PYVER} - ln -s "${EPREFIX}"/usr/include/python${PYVER} \ - "${ED}${fwdir}"/Headers || die - ln -s "${EPREFIX}"/usr/lib/libpython${PYVER}.dylib \ - "${ED}${fwdir}"/Python || die - fi - - sed \ - -e "s/\(CONFIGURE_LDFLAGS=\).*/\1/" \ - -e "s/\(PY_LDFLAGS=\).*/\1/" \ - -i "${libdir}/config-${PYVER}"*/Makefile || die "sed failed" - - # Fix collisions between different slots of Python. - rm -f "${ED}usr/$(get_libdir)/libpython3.so" - - # Cheap hack to get version with ABIFLAGS - local abiver=$(cd "${ED}usr/include"; echo python*) - if [[ ${abiver} != python${PYVER} ]]; then - # Replace python3.X with a symlink to python3.Xm - rm "${ED}usr/bin/python${PYVER}" || die - dosym "${abiver}" "/usr/bin/python${PYVER}" - # Create python3.X-config symlink - dosym "${abiver}-config" "/usr/bin/python${PYVER}-config" - # Create python-3.5m.pc symlink - dosym "python-${PYVER}.pc" "/usr/$(get_libdir)/pkgconfig/${abiver/${PYVER}/-${PYVER}}.pc" - fi - - # python seems to get rebuilt in src_install (bug 569908) - # Work around it for now. - if has_version dev-libs/libffi[pax_kernel]; then - pax-mark E "${ED}usr/bin/${abiver}" - else - pax-mark m "${ED}usr/bin/${abiver}" - fi - - use elibc_uclibc && rm -fr "${libdir}/test" - use sqlite || rm -fr "${libdir}/"{sqlite3,test/test_sqlite*} - use tk || rm -fr "${ED}usr/bin/idle${PYVER}" "${libdir}/"{idlelib,tkinter,test/test_tk*} - - use threads || rm -fr "${libdir}/multiprocessing" - use wininst || rm -f "${libdir}/distutils/command/"wininst-*.exe - - dodoc "${S}"/Misc/{ACKS,HISTORY,NEWS} - - if use examples; then - insinto /usr/share/doc/${PF}/examples - find "${S}"/Tools -name __pycache__ -print0 | xargs -0 rm -fr - doins -r "${S}"/Tools - fi - insinto /usr/share/gdb/auto-load/usr/$(get_libdir) #443510 - if use aqua ; then - # we do framework, so the emake trick below returns a pathname - # since that won't work here, use a (cheap) trick instead - local libname=libpython${PYVER} - else - local libname=$(printf 'e:\n\t@echo $(INSTSONAME)\ninclude Makefile\n' | \ - emake --no-print-directory -s -f - 2>/dev/null) - fi - newins "${S}"/Tools/gdb/libpython.py "${libname}"-gdb.py - - newconfd "${FILESDIR}/pydoc.conf" pydoc-${PYVER} - newinitd "${FILESDIR}/pydoc.init" pydoc-${PYVER} - sed \ - -e "s:@PYDOC_PORT_VARIABLE@:PYDOC${PYVER/./_}_PORT:" \ - -e "s:@PYDOC@:pydoc${PYVER}:" \ - -i "${ED}etc/conf.d/pydoc-${PYVER}" "${ED}etc/init.d/pydoc-${PYVER}" || die "sed failed" - - # for python-exec - local vars=( EPYTHON PYTHON_SITEDIR PYTHON_SCRIPTDIR ) - - # if not using a cross-compiler, use the fresh binary - if ! tc-is-cross-compiler; then - local -x PYTHON=./python$(sed -n '/BUILDEXE=/s/^.*=\s\+//p' Makefile) - local -x LD_LIBRARY_PATH=${LD_LIBRARY_PATH+${LD_LIBRARY_PATH}:}. - local -x DYLD_LIBRARY_PATH=${DYLD_LIBRARY_PATH+${DYLD_LIBRARY_PATH}:}. - else - vars=( PYTHON "${vars[@]}" ) - fi - - python_export "python${PYVER}" "${vars[@]}" - echo "EPYTHON='${EPYTHON}'" > epython.py || die - python_domodule epython.py - - # python-exec wrapping support - local pymajor=${PYVER%.*} - mkdir -p "${D}${PYTHON_SCRIPTDIR}" || die - # python and pythonX - ln -s "../../../bin/${abiver}" \ - "${D}${PYTHON_SCRIPTDIR}/python${pymajor}" || die - ln -s "python${pymajor}" \ - "${D}${PYTHON_SCRIPTDIR}/python" || die - # python-config and pythonX-config - # note: we need to create a wrapper rather than symlinking it due - # to some random dirname(argv[0]) magic performed by python-config - cat > "${D}${PYTHON_SCRIPTDIR}/python${pymajor}-config" <<-EOF || die - #!/bin/sh - exec "${abiver}-config" "\${@}" - EOF - chmod +x "${D}${PYTHON_SCRIPTDIR}/python${pymajor}-config" || die - ln -s "python${pymajor}-config" \ - "${D}${PYTHON_SCRIPTDIR}/python-config" || die - # 2to3, pydoc, pyvenv - ln -s "../../../bin/2to3-${PYVER}" \ - "${D}${PYTHON_SCRIPTDIR}/2to3" || die - ln -s "../../../bin/pydoc${PYVER}" \ - "${D}${PYTHON_SCRIPTDIR}/pydoc" || die - ln -s "../../../bin/pyvenv-${PYVER}" \ - "${D}${PYTHON_SCRIPTDIR}/pyvenv" || die - # idle - if use tk; then - ln -s "../../../bin/idle${PYVER}" \ - "${D}${PYTHON_SCRIPTDIR}/idle" || die - fi -} - -pkg_preinst() { - if has_version "<${CATEGORY}/${PN}-${PYVER}" && ! has_version ">=${CATEGORY}/${PN}-${PYVER}_alpha"; then - python_updater_warning="1" - fi -} - -eselect_python_update() { - if [[ -z "$(eselect python show)" || ! -f "${EROOT}usr/bin/$(eselect python show)" ]]; then - eselect python update - fi - - if [[ -z "$(eselect python show --python${PV%%.*})" || ! -f "${EROOT}usr/bin/$(eselect python show --python${PV%%.*})" ]]; then - eselect python update --python${PV%%.*} - fi -} - -pkg_postinst() { - eselect_python_update - - if [[ "${python_updater_warning}" == "1" ]]; then - ewarn "You have just upgraded from an older version of Python." - ewarn - ewarn "Please adjust PYTHON_TARGETS (if so desired), and run emerge with the --newuse or --changed-use option to rebuild packages installing python modules." - fi -} - -pkg_postrm() { - eselect_python_update -}