python-utils-r1.eclass: Add python3.14 targets

Signed-off-by: Michał Górny <mgorny@gentoo.org>
This commit is contained in:
Michał Górny
2025-05-07 19:59:13 +02:00
parent caf9d42951
commit 4225e61a43
2 changed files with 14 additions and 6 deletions

View File

@@ -40,8 +40,8 @@ inherit multiprocessing toolchain-funcs
# All supported Python implementations, most preferred last.
_PYTHON_ALL_IMPLS=(
pypy3_11
python3_13t
python3_{11..13}
python3_{13..14}t
python3_{11..14}
)
readonly _PYTHON_ALL_IMPLS
@@ -81,7 +81,7 @@ _python_verify_patterns() {
local impl pattern
for pattern; do
case ${pattern} in
-[23]|3.[89]|3.1[0-3])
-[23]|3.[89]|3.1[0-4])
continue
;;
esac
@@ -137,7 +137,7 @@ _python_set_impls() {
# please keep them in sync with _PYTHON_ALL_IMPLS
# and _PYTHON_HISTORICAL_IMPLS
case ${i} in
pypy3_11|python3_9|python3_1[1-3]|python3_13t)
pypy3_11|python3_9|python3_1[1-4]|python3_1[3-4]t)
;;
jython2_7|pypy|pypy1_[89]|pypy2_0|pypy3|python2_[5-7]|python3_[1-9]|python3_10)
obsolete+=( "${i}" )
@@ -230,7 +230,7 @@ _python_impl_matches() {
fi
return 0
;;
3.[89]|3.1[0-3])
3.[89]|3.1[0-4])
[[ ${impl%t} == python${pattern/./_} || ${impl} == pypy${pattern/./_} ]] &&
return 0
;;

View File

@@ -64,7 +64,7 @@ tmpfile=$(mktemp)
inherit multilib python-utils-r1
for minor in {11..13} 13t; do
for minor in {11..14} {13..14}t; do
ebegin "Testing python3.${minor}"
eindent
test_var EPYTHON "python3_${minor}" "python3.${minor}"
@@ -209,6 +209,14 @@ test_is "_python_impl_matches python3_11 3.12" 1
test_is "_python_impl_matches python3_12 3.10" 1
test_is "_python_impl_matches python3_12 3.11" 1
test_is "_python_impl_matches python3_12 3.12" 0
test_is "_python_impl_matches python3_13 3.13" 0
test_is "_python_impl_matches python3_13t 3.13" 0
test_is "_python_impl_matches python3_13 3.14" 1
test_is "_python_impl_matches python3_13t 3.14" 1
test_is "_python_impl_matches python3_14 3.13" 1
test_is "_python_impl_matches python3_14t 3.13" 1
test_is "_python_impl_matches python3_14 3.14" 0
test_is "_python_impl_matches python3_14t 3.14" 0
test_is "_python_impl_matches pypy3_11 3.10" 1
test_is "_python_impl_matches pypy3_11 3.11" 0
test_is "_python_impl_matches pypy3_11 3.12" 1