Gentoo Archives: gentoo-commits

From: "Michał Górny" <mgorny@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: eclass/tests/, eclass/
Date: Mon, 25 May 2020 06:12:42
Message-Id: 1590386838.e563ed3af0dad1d3eaa165f5eb89b6f7ed0a1c9c.mgorny@gentoo
1 commit: e563ed3af0dad1d3eaa165f5eb89b6f7ed0a1c9c
2 Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
3 AuthorDate: Mon May 25 06:04:34 2020 +0000
4 Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
5 CommitDate: Mon May 25 06:07:18 2020 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e563ed3a
7
8 python-utils-r1.eclass: Enable python3_9
9
10 Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>
11
12 eclass/python-utils-r1.eclass | 4 ++--
13 eclass/tests/python-utils-r1.sh | 16 +++++++++++++++-
14 2 files changed, 17 insertions(+), 3 deletions(-)
15
16 diff --git a/eclass/python-utils-r1.eclass b/eclass/python-utils-r1.eclass
17 index 4af710da363..1067d2367ab 100644
18 --- a/eclass/python-utils-r1.eclass
19 +++ b/eclass/python-utils-r1.eclass
20 @@ -41,7 +41,7 @@ inherit toolchain-funcs
21 _PYTHON_ALL_IMPLS=(
22 pypy3
23 python2_7
24 - python3_6 python3_7 python3_8
25 + python3_6 python3_7 python3_8 python3_9
26 )
27 readonly _PYTHON_ALL_IMPLS
28
29 @@ -77,7 +77,7 @@ _python_impl_supported() {
30 # keep in sync with _PYTHON_ALL_IMPLS!
31 # (not using that list because inline patterns shall be faster)
32 case "${impl}" in
33 - python2_7|python3_[678]|pypy3)
34 + python2_7|python3_[6789]|pypy3)
35 return 0
36 ;;
37 jython2_7|pypy|pypy1_[89]|pypy2_0|python2_[56]|python3_[12345])
38
39 diff --git a/eclass/tests/python-utils-r1.sh b/eclass/tests/python-utils-r1.sh
40 index 192c1183e80..86b87ec173d 100755
41 --- a/eclass/tests/python-utils-r1.sh
42 +++ b/eclass/tests/python-utils-r1.sh
43 @@ -1,5 +1,5 @@
44 #!/bin/bash
45 -# Copyright 1999-2019 Gentoo Authors
46 +# Copyright 1999-2020 Gentoo Authors
47 # Distributed under the terms of the GNU General Public License v2
48
49 EAPI=7
50 @@ -115,6 +115,20 @@ fi
51 test_var PYTHON_PKG_DEP python3_8 '*dev-lang/python*:3.8'
52 test_var PYTHON_SCRIPTDIR python3_8 /usr/lib/python-exec/python3.8
53
54 +test_var EPYTHON python3_9 python3.9
55 +test_var PYTHON python3_9 /usr/bin/python3.9
56 +if [[ -x /usr/bin/python3.9 ]]; then
57 + abiflags=$(/usr/bin/python3.9 -c 'import sysconfig; print(sysconfig.get_config_var("ABIFLAGS"))')
58 + test_var PYTHON_SITEDIR python3_9 "/usr/lib/python3.9/site-packages"
59 + test_var PYTHON_INCLUDEDIR python3_9 "/usr/include/python3.9${abiflags}"
60 + test_var PYTHON_LIBPATH python3_9 "/usr/lib*/libpython3.9${abiflags}$(get_libname)"
61 + test_var PYTHON_CONFIG python3_9 "/usr/bin/python3.9${abiflags}-config"
62 + test_var PYTHON_CFLAGS python3_9 "*-I/usr/include/python3.9*"
63 + test_var PYTHON_LIBS python3_9 "*-lpython3.9*"
64 +fi
65 +test_var PYTHON_PKG_DEP python3_9 '*dev-lang/python*:3.9'
66 +test_var PYTHON_SCRIPTDIR python3_9 /usr/lib/python-exec/python3.9
67 +
68 test_var EPYTHON pypy3 pypy3
69 test_var PYTHON pypy3 /usr/bin/pypy3
70 if [[ -x /usr/bin/pypy3 ]]; then