summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichał Górny <mgorny@gentoo.org>2023-11-04 16:20:24 +0100
committerMichał Górny <mgorny@gentoo.org>2023-11-04 19:03:06 +0100
commit2fd4b57417a4c577b26387789bca1ad866b48279 (patch)
treea0a82c37e33bc24aa4dd9c7c66a98a8b4cfdcfd1 /dev-python/yappi
parentdev-python/yapsy: Backport py3.12 fixes (diff)
downloadgentoo-2fd4b57417a4c577b26387789bca1ad866b48279.tar.gz
gentoo-2fd4b57417a4c577b26387789bca1ad866b48279.tar.bz2
gentoo-2fd4b57417a4c577b26387789bca1ad866b48279.zip
dev-python/yappi: Enable py3.12
Signed-off-by: Michał Górny <mgorny@gentoo.org>
Diffstat (limited to 'dev-python/yappi')
-rw-r--r--dev-python/yappi/yappi-1.4.0.ebuild9
1 files changed, 8 insertions, 1 deletions
diff --git a/dev-python/yappi/yappi-1.4.0.ebuild b/dev-python/yappi/yappi-1.4.0.ebuild
index 419c6f5dda73..552b6d3f1e05 100644
--- a/dev-python/yappi/yappi-1.4.0.ebuild
+++ b/dev-python/yappi/yappi-1.4.0.ebuild
@@ -5,7 +5,7 @@ EAPI=8
DISTUTILS_EXT=1
DISTUTILS_USE_PEP517=setuptools
-PYTHON_COMPAT=( python3_{9..11} )
+PYTHON_COMPAT=( python3_{10..12} )
inherit distutils-r1
@@ -29,6 +29,13 @@ PATCHES=(
"${FILESDIR}/yappi-1.2.5-warnings.patch"
)
+src_prepare() {
+ # using new API makes sense for versions newer than 3.11 too, sigh...
+ # https://github.com/sumerc/yappi/pull/148
+ sed -i -e 's:== 11:>= 11:' yappi/_yappi.c || die
+ distutils-r1_src_prepare
+}
+
python_test() {
local -x PYTHONPATH=tests
eunittest