From 3d0fcd5134bd6bad98b200997cea72315dfd5dc2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= Date: Tue, 2 Aug 2022 13:53:19 +0200 Subject: [PATCH] dev-lang/python: Support disabling ensurepip in 3.11.0_beta5 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Michał Górny --- dev-lang/python/metadata.xml | 5 +++++ dev-lang/python/python-3.11.0_beta5.ebuild | 12 +++++++++++- 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/dev-lang/python/metadata.xml b/dev-lang/python/metadata.xml index 38626e26f8a91..d3ddcf0b38205 100644 --- a/dev-lang/python/metadata.xml +++ b/dev-lang/python/metadata.xml @@ -9,6 +9,11 @@ Build Bluetooth protocol support in socket module + + Install the ensurepip module that uses bundled wheels + to bootstrap pip and setuptools (if disabled, it will + be only possible to use venv `--without-pip`) + Link readline extension against dev-libs/libedit instead of sys-libs/readline diff --git a/dev-lang/python/python-3.11.0_beta5.ebuild b/dev-lang/python/python-3.11.0_beta5.ebuild index aab4bbbdc169f..6cd158622a3fb 100644 --- a/dev-lang/python/python-3.11.0_beta5.ebuild +++ b/dev-lang/python/python-3.11.0_beta5.ebuild @@ -27,9 +27,16 @@ SRC_URI=" S="${WORKDIR}/${MY_P}" LICENSE="PSF-2" +# ensurepip bundles pip and setuptools, and pip bundles a lot +LICENSE+=" + ensurepip? ( Apache-2.0 BSD BSD-2 ISC LGPL-2.1+ MIT MPL-2.0 PSF-2 ) +" SLOT="${PYVER}" KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86" -IUSE="bluetooth build examples gdbm hardened libedit lto +ncurses pgo +readline +sqlite +ssl test tk wininst" +IUSE=" + bluetooth build +ensurepip examples gdbm hardened libedit lto + +ncurses pgo +readline +sqlite +ssl test tk wininst +" RESTRICT="!test? ( test )" # Do not add a dependency on dev-lang/python to this ebuild. @@ -404,6 +411,9 @@ src_install() { pax-mark m "${ED}/usr/bin/${abiver}" fi + if ! use ensurepip; then + rm -r "${libdir}"/ensurepip || die + fi use sqlite || rm -r "${libdir}/"sqlite3 || die use tk || rm -r "${ED}/usr/bin/idle${PYVER}" "${libdir}/"{idlelib,tkinter,test/test_tk*} || die