1 |
commit: cca0337ca265cb460030a1fcf2e338da9230fe90 |
2 |
Author: Michał Górny <mgorny <AT> gentoo <DOT> org> |
3 |
AuthorDate: Thu Feb 24 16:21:56 2022 +0000 |
4 |
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu Feb 24 18:08:46 2022 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=cca0337c |
7 |
|
8 |
dev-python/oslo-utils: Enable py3.10 (w/o eventlet part) |
9 |
|
10 |
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org> |
11 |
|
12 |
dev-python/oslo-utils/oslo-utils-4.12.2.ebuild | 18 ++++++++++++++++-- |
13 |
1 file changed, 16 insertions(+), 2 deletions(-) |
14 |
|
15 |
diff --git a/dev-python/oslo-utils/oslo-utils-4.12.2.ebuild b/dev-python/oslo-utils/oslo-utils-4.12.2.ebuild |
16 |
index 90d9c1b9be66..b991aafb859e 100644 |
17 |
--- a/dev-python/oslo-utils/oslo-utils-4.12.2.ebuild |
18 |
+++ b/dev-python/oslo-utils/oslo-utils-4.12.2.ebuild |
19 |
@@ -4,7 +4,7 @@ |
20 |
EAPI=8 |
21 |
|
22 |
DISTUTILS_USE_PEP517=setuptools |
23 |
-PYTHON_COMPAT=( python3_{8..9} ) |
24 |
+PYTHON_COMPAT=( python3_{8..10} ) |
25 |
|
26 |
inherit distutils-r1 |
27 |
|
28 |
@@ -30,8 +30,10 @@ RDEPEND=" |
29 |
" |
30 |
BDEPEND=" |
31 |
>=dev-python/pbr-2.2.0[${PYTHON_USEDEP}] |
32 |
- >dev-python/eventlet-0.23.0[${PYTHON_USEDEP}] |
33 |
test? ( |
34 |
+ $(python_gen_cond_dep ' |
35 |
+ >=dev-python/eventlet-0.23.0[${PYTHON_USEDEP}] |
36 |
+ ' python3_{8..9}) |
37 |
>=dev-python/fixtures-3.0.0[${PYTHON_USEDEP}] |
38 |
>=dev-python/testscenarios-0.4[${PYTHON_USEDEP}] |
39 |
>=dev-python/testtools-2.2.0[${PYTHON_USEDEP}] |
40 |
@@ -47,3 +49,15 @@ src_prepare() { |
41 |
sed -i -e '/pbr/d' requirements.txt || die |
42 |
distutils-r1_src_prepare |
43 |
} |
44 |
+ |
45 |
+python_compile() { |
46 |
+ distutils-r1_python_compile |
47 |
+ if ! has "${EPYTHON}" python3.{8..9}; then |
48 |
+ find "${BUILD_DIR}"/install -name '*eventletutils*.py' -delete || die |
49 |
+ fi |
50 |
+} |
51 |
+ |
52 |
+python_test() { |
53 |
+ cd "${BUILD_DIR}/install$(python_get_sitedir)" || die |
54 |
+ eunittest |
55 |
+} |