| 1 |
Description: Adapt python.m4 to detect new Python3.10 and 3.11 |
| 2 |
Author: Gianfranco Costamagna <[email protected]> |
| 3 |
Last-Update: 2022-01-17 |
| 4 |
|
| 5 |
--- python-demgengeo-1.4.orig/m4/python.m4 |
| 6 |
+++ python-demgengeo-1.4/m4/python.m4 |
| 7 |
@@ -49,7 +49,7 @@ AC_DEFUN([AM_PATH_PYTHON], |
| 8 |
m4_define_default([_AM_PYTHON_INTERPRETER_LIST], |
| 9 |
[python python2 python3 python2.0 python2.1 python2.2 dnl |
| 10 |
python2.3 python2.4 python2.5 python2.6 python2.7 python3.0 python3.1 python3.2 dnl |
| 11 |
-python3.3 python3.4 python3.5 python3.6 python3.7 python3.8 python3.9]) |
| 12 |
+python3.3 python3.4 python3.5 python3.6 python3.7 python3.8 python3.9 python3.10 python3.11]) |
| 13 |
|
| 14 |
m4_if([$1],[],[ |
| 15 |
dnl No version check is needed. |
| 16 |
@@ -95,7 +95,7 @@ python3.3 python3.4 python3.5 python3.6 |
| 17 |
dnl the best way to do this; it's what "site.py" does in the standard |
| 18 |
dnl library. |
| 19 |
AC_CACHE_CHECK([for $am_display_PYTHON version], [am_cv_python_version], |
| 20 |
- [am_cv_python_version=`$PYTHON -c "import sys; sys.stdout.write(sys.version[[:3]])"`]) |
| 21 |
+ [am_cv_python_version=`$PYTHON -c "import sys; print(str(sys.version_info.major) + '.' + str(sys.version_info.minor))"`]) |
| 22 |
AC_SUBST([PYTHON_VERSION], [$am_cv_python_version]) |
| 23 |
|
| 24 |
dnl CHANGED FOR GENGEO: |