Skip to content

Commit

Permalink
testdata: Add pypy3 to PYTHON_COMPAT in test ebuilds
Browse files Browse the repository at this point in the history
Signed-off-by: Michał Górny <[email protected]>
  • Loading branch information
mgorny committed Oct 21, 2024
1 parent d2dbb52 commit ca7e233
Show file tree
Hide file tree
Showing 18 changed files with 50 additions and 23 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@ diff -Naur python/PythonCheck/DistutilsNonPEP517Build/DistutilsNonPEP517Build-0.
EAPI=7

+DISTUTILS_USE_PEP517=setuptools
PYTHON_COMPAT=( python3_10 )
PYTHON_COMPAT=( pypy3 python3_10 )

inherit distutils-r1
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
EAPI=7

PYTHON_COMPAT=( python3_10 )
PYTHON_COMPAT=( pypy3 python3_10 )

inherit distutils-r1

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

EAPI=8

PYTHON_COMPAT=( python3_10 )
PYTHON_COMPAT=( pypy3 python3_10 )

inherit python-any-r1

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

EAPI=6

PYTHON_COMPAT=( python3_10 )
PYTHON_COMPAT=( pypy3 python3_10 )

inherit python-any-r1

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

EAPI=8

PYTHON_COMPAT=( python3_10 )
PYTHON_COMPAT=( pypy3 python3_10 )

inherit python-any-r1

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

EAPI=8

PYTHON_COMPAT=( python3_10 )
PYTHON_COMPAT=( pypy3 python3_10 )

inherit python-any-r1

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

EAPI=8

PYTHON_COMPAT=( python3_10 )
PYTHON_COMPAT=( pypy3 python3_10 )

inherit python-any-r1

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

EAPI=8

PYTHON_COMPAT=( python3_10 )
PYTHON_COMPAT=( pypy3 python3_10 )

inherit python-any-r1

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

EAPI=8

PYTHON_COMPAT=( python3_10 )
PYTHON_COMPAT=( pypy3 python3_10 )

inherit python-any-r1

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

EAPI=8

PYTHON_COMPAT=( python3_10 )
PYTHON_COMPAT=( pypy3 python3_10 )

inherit python-any-r1

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
EAPI=7
PYTHON_COMPAT=( python3_9 )
PYTHON_COMPAT=( pypy3 python3_9 )

inherit python-r1

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ EAPI=8

DISTUTILS_OPTIONAL=1
DISTUTILS_USE_PEP517=setuptools
PYTHON_COMPAT=( python3_10 )
PYTHON_COMPAT=( pypy3 python3_10 )

inherit distutils-r1

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ EAPI=8

DISTUTILS_OPTIONAL=1
DISTUTILS_USE_PEP517=no
PYTHON_COMPAT=( python3_10 )
PYTHON_COMPAT=( pypy3 python3_10 )

inherit distutils-r1

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
EAPI=8

DISTUTILS_USE_PEP517=setuptools
PYTHON_COMPAT=( python3_10 )
PYTHON_COMPAT=( pypy3 python3_10 )

inherit distutils-r1

Expand Down
6 changes: 6 additions & 0 deletions testdata/repos/python/dev-python/pypy3/pypy-7.3.17.ebuild
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
EAPI=8

DESCRIPTION="Stub ebuild for pypy3 interpreter"
HOMEPAGE="https://github.com/pkgcore/pkgcheck"
LICENSE="BSD"
SLOT="0/pypy310"
13 changes: 10 additions & 3 deletions testdata/repos/python/eclass/python-any-r1.eclass
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,16 @@ _python_set_impls() {
local i slot
PYTHON_DEPS="|| ("
for i in "${PYTHON_COMPAT[@]}"; do
slot=${i#python}
slot=${slot/_/.}
PYTHON_DEPS+=" dev-lang/python:${slot}"
case ${i} in
python*)
slot=${i#python}
slot=${slot/_/.}
PYTHON_DEPS+=" dev-lang/python:${slot}"
;;
pypy3)
PYTHON_DEPS+=" dev-python/pypy3:="
;;
esac
done
PYTHON_DEPS+=" )"
PYTHON_REQUIRED_USE='I-DO-NOT-EXIST-IN-PYTHON-ANY-R1'
Expand Down
13 changes: 10 additions & 3 deletions testdata/repos/python/eclass/python-r1.eclass
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,17 @@ _python_set_impls() {
local i slot
local -a use
for i in "${PYTHON_COMPAT[@]}"; do
slot=${i#python}
slot=${slot/_/.}
use+=( "python_targets_${i}" )
PYTHON_DEPS+=" python_targets_${i}? ( dev-lang/python:${slot} )"
case ${i} in
python*)
slot=${i#python}
slot=${slot/_/.}
PYTHON_DEPS+=" python_targets_${i}? ( dev-lang/python:${slot} )"
;;
pypy3)
PYTHON_DEPS+=" python_targets_${i}? ( dev-python/pypy3:= )"
;;
esac
done
IUSE+=" ${use[@]}"
PYTHON_REQUIRED_USE="|| ( ${use[@]} )"
Expand Down
13 changes: 10 additions & 3 deletions testdata/repos/python/eclass/python-single-r1.eclass
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,17 @@ _python_set_impls() {
local i slot
local -a use use_deps
for i in "${PYTHON_COMPAT[@]}"; do
slot=${i#python}
slot=${slot/_/.}
use+=( "python_single_target_${i}" )
PYTHON_DEPS+=" python_single_target_${i}? ( dev-lang/python:${slot} )"
case ${i} in
python*)
slot=${i#python}
slot=${slot/_/.}
PYTHON_DEPS+=" python_single_target_${i}? ( dev-lang/python:${slot} )"
;;
pypy3)
PYTHON_DEPS+=" python_single_target_${i}? ( dev-python/pypy3:= )"
;;
esac
done
IUSE+=" ${use[@]}"
PYTHON_REQUIRED_USE="^^ ( ${use[@]} )"
Expand Down

0 comments on commit ca7e233

Please sign in to comment.