commit: cca0337ca265cb460030a1fcf2e338da9230fe90
Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Thu Feb 24 16:21:56 2022 +0000
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Thu Feb 24 18:08:46 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=cca0337c
dev-python/oslo-utils: Enable py3.10 (w/o eventlet part)
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>
dev-python/oslo-utils/oslo-utils-4.12.2.ebuild | 18 ++++++++++++++++--
1 file changed, 16 insertions(+), 2 deletions(-)
diff --git a/dev-python/oslo-utils/oslo-utils-4.12.2.ebuild
b/dev-python/oslo-utils/oslo-utils-4.12.2.ebuild
index 90d9c1b9be66..b991aafb859e 100644
--- a/dev-python/oslo-utils/oslo-utils-4.12.2.ebuild
+++ b/dev-python/oslo-utils/oslo-utils-4.12.2.ebuild
@@ -4,7 +4,7 @@
EAPI=8
DISTUTILS_USE_PEP517=setuptools
-PYTHON_COMPAT=( python3_{8..9} )
+PYTHON_COMPAT=( python3_{8..10} )
inherit distutils-r1
@@ -30,8 +30,10 @@ RDEPEND="
"
BDEPEND="
>=dev-python/pbr-2.2.0[${PYTHON_USEDEP}]
- >dev-python/eventlet-0.23.0[${PYTHON_USEDEP}]
test? (
+ $(python_gen_cond_dep '
+ >=dev-python/eventlet-0.23.0[${PYTHON_USEDEP}]
+ ' python3_{8..9})
>=dev-python/fixtures-3.0.0[${PYTHON_USEDEP}]
>=dev-python/testscenarios-0.4[${PYTHON_USEDEP}]
>=dev-python/testtools-2.2.0[${PYTHON_USEDEP}]
@@ -47,3 +49,15 @@ src_prepare() {
sed -i -e '/pbr/d' requirements.txt || die
distutils-r1_src_prepare
}
+
+python_compile() {
+ distutils-r1_python_compile
+ if ! has "${EPYTHON}" python3.{8..9}; then
+ find "${BUILD_DIR}"/install -name '*eventletutils*.py' -delete
|| die
+ fi
+}
+
+python_test() {
+ cd "${BUILD_DIR}/install$(python_get_sitedir)" || die
+ eunittest
+}