commit:     c9c2e1e4cd1cc1306c3ab8f533cea6bbccf90f94
Author:     Fabian Groffen <grobian <AT> gentoo <DOT> org>
AuthorDate: Tue May 26 06:43:45 2020 +0000
Commit:     Fabian Groffen <grobian <AT> gentoo <DOT> org>
CommitDate: Tue May 26 06:43:45 2020 +0000
URL:        https://gitweb.gentoo.org/repo/proj/prefix.git/commit/?id=c9c2e1e4

eclass/python-utils-r1: sync with gx86

this is mostly for python3_9 support

Signed-off-by: Fabian Groffen <grobian <AT> gentoo.org>

 eclass/python-utils-r1.eclass | 20 ++++++++++----------
 1 file changed, 10 insertions(+), 10 deletions(-)

diff --git a/eclass/python-utils-r1.eclass b/eclass/python-utils-r1.eclass
index 87f0821b68..0caece1344 100644
--- a/eclass/python-utils-r1.eclass
+++ b/eclass/python-utils-r1.eclass
@@ -41,7 +41,7 @@ inherit toolchain-funcs
 _PYTHON_ALL_IMPLS=(
        pypy3
        python2_7
-       python3_6 python3_7 python3_8
+       python3_6 python3_7 python3_8 python3_9
 )
 readonly _PYTHON_ALL_IMPLS
 
@@ -77,7 +77,7 @@ _python_impl_supported() {
        # keep in sync with _PYTHON_ALL_IMPLS!
        # (not using that list because inline patterns shall be faster)
        case "${impl}" in
-               python2_7|python3_[678]|pypy3)
+               python2_7|python3_[6789]|pypy3)
                        return 0
                        ;;
                jython2_7|pypy|pypy1_[89]|pypy2_0|python2_[56]|python3_[12345])
@@ -361,10 +361,14 @@ _python_export() {
                                local val
 
                                case "${impl}" in
-                                       python*)
-                                               # python-2.7, python-3.2, etc.
+                                       python2*|python3.6|python3.7*)
+                                               # python* up to 3.7
                                                val=$($(tc-getPKG_CONFIG) 
--libs ${impl/n/n-}) || die
                                                ;;
+                                       python*)
+                                               # python3.8+
+                                               val=$($(tc-getPKG_CONFIG) 
--libs ${impl/n/n-}-embed) || die
+                                               ;;
                                        *)
                                                die "${impl}: obtaining ${var} 
not supported"
                                                ;;
@@ -395,16 +399,12 @@ _python_export() {
                                case ${impl} in
                                        python2.7)
                                                
PYTHON_PKG_DEP='>=dev-lang/python-2.7.5-r2:2.7';;
-                                       python3.3)
-                                               
PYTHON_PKG_DEP='>=dev-lang/python-3.3.2-r2:3.3';;
                                        python*)
                                                
PYTHON_PKG_DEP="dev-lang/python:${impl#python}";;
                                        pypy)
-                                               
PYTHON_PKG_DEP='>=dev-python/pypy-5:0=';;
+                                               
PYTHON_PKG_DEP='>=dev-python/pypy-7.3.0:0=';;
                                        pypy3)
-                                               
PYTHON_PKG_DEP='>=dev-python/pypy3-5:0=';;
-                                       jython2.7)
-                                               
PYTHON_PKG_DEP='dev-java/jython:2.7';;
+                                               
PYTHON_PKG_DEP='>=dev-python/pypy3-7.3.0:0=';;
                                        *)
                                                die "Invalid implementation: 
${impl}"
                                esac

Reply via email to