Add Python 3.10 to the hadcoded lists of Python versions

This commit is contained in:
Miro Hrončok 2020-11-09 17:44:30 +01:00
parent 946181a294
commit 1ab5d69fab
3 changed files with 74 additions and 1 deletions

25
5383.patch Normal file
View File

@ -0,0 +1,25 @@
From 23cd98a66a3eca1cc8e89a77f4fdf406c4f4c113 Mon Sep 17 00:00:00 2001
From: Marc Chevrier <marc.chevrier@gmail.com>
Date: Fri, 16 Oct 2020 11:36:53 +0200
Subject: [PATCH] FindPython: Add support of version 3.10
---
Modules/FindPython/Support.cmake | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Modules/FindPython/Support.cmake b/Modules/FindPython/Support.cmake
index 7de2d29946..2b911ae7e3 100644
--- a/Modules/FindPython/Support.cmake
+++ b/Modules/FindPython/Support.cmake
@@ -22,7 +22,7 @@ if (NOT DEFINED _${_PYTHON_PREFIX}_REQUIRED_VERSION_MAJOR)
message (FATAL_ERROR "FindPython: INTERNAL ERROR")
endif()
if (_${_PYTHON_PREFIX}_REQUIRED_VERSION_MAJOR EQUAL "3")
- set(_${_PYTHON_PREFIX}_VERSIONS 3.9 3.8 3.7 3.6 3.5 3.4 3.3 3.2 3.1 3.0)
+ set(_${_PYTHON_PREFIX}_VERSIONS 3.10 3.9 3.8 3.7 3.6 3.5 3.4 3.3 3.2 3.1 3.0)
elseif (_${_PYTHON_PREFIX}_REQUIRED_VERSION_MAJOR EQUAL "2")
set(_${_PYTHON_PREFIX}_VERSIONS 2.7 2.6 2.5 2.4 2.3 2.2 2.1 2.0)
else()
--
GitLab

42
5482.patch Normal file
View File

@ -0,0 +1,42 @@
From bb2ebbf2412ef9343f50a45868459ffb95fa9081 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Miro=20Hron=C4=8Dok?= <miro@hroncok.cz>
Date: Mon, 9 Nov 2020 17:35:13 +0100
Subject: [PATCH] FindPython{Interp,Libs}: Add support for version 3.10
Extend the change from commit 23cd98a66a (FindPython: Add support of
version 3.10, 2020-10-16, v3.19.0-rc2~25^2) to cover the legacy
`FindPython{Interp,Libs}` modules too.
---
Modules/FindPythonInterp.cmake | 2 +-
Modules/FindPythonLibs.cmake | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/Modules/FindPythonInterp.cmake b/Modules/FindPythonInterp.cmake
index 1e01a99cbe..efe0f11901 100644
--- a/Modules/FindPythonInterp.cmake
+++ b/Modules/FindPythonInterp.cmake
@@ -54,7 +54,7 @@ unset(_Python_NAMES)
set(_PYTHON1_VERSIONS 1.6 1.5)
set(_PYTHON2_VERSIONS 2.7 2.6 2.5 2.4 2.3 2.2 2.1 2.0)
-set(_PYTHON3_VERSIONS 3.9 3.8 3.7 3.6 3.5 3.4 3.3 3.2 3.1 3.0)
+set(_PYTHON3_VERSIONS 3.10 3.9 3.8 3.7 3.6 3.5 3.4 3.3 3.2 3.1 3.0)
if(PythonInterp_FIND_VERSION)
if(PythonInterp_FIND_VERSION_COUNT GREATER 1)
diff --git a/Modules/FindPythonLibs.cmake b/Modules/FindPythonLibs.cmake
index d3ec7beec6..396f0d2ed4 100644
--- a/Modules/FindPythonLibs.cmake
+++ b/Modules/FindPythonLibs.cmake
@@ -79,7 +79,7 @@ set(CMAKE_FIND_FRAMEWORK LAST)
set(_PYTHON1_VERSIONS 1.6 1.5)
set(_PYTHON2_VERSIONS 2.7 2.6 2.5 2.4 2.3 2.2 2.1 2.0)
-set(_PYTHON3_VERSIONS 3.9 3.8 3.7 3.6 3.5 3.4 3.3 3.2 3.1 3.0)
+set(_PYTHON3_VERSIONS 3.10 3.9 3.8 3.7 3.6 3.5 3.4 3.3 3.2 3.1 3.0)
if(PythonLibs_FIND_VERSION)
if(PythonLibs_FIND_VERSION_COUNT GREATER 1)
--
GitLab

View File

@ -62,7 +62,7 @@
%{?rcsuf:%global versuf -%{rcsuf}}
# For handling bump release by rpmdev-bumpspec and mass rebuild
%global baserelease 1
%global baserelease 2
# Uncomment if building for EPEL
#global name_suffix %%{major_version}
@ -103,6 +103,9 @@ Patch101: %{name}-fedora-flag_release.patch
Patch102: %{name}-mingw-dl.patch
# rhbz#1871346
Patch103: %{name}-3.18.3-findblas.patch
# Add Python 3.10 to the hadcoded lists of Python versions
Patch104: https://gitlab.kitware.com/cmake/cmake/-/merge_requests/5383.patch
Patch105: https://gitlab.kitware.com/cmake/cmake/-/merge_requests/5482.patch
# Patch for renaming on EPEL
%if 0%{?name_suffix:1}
@ -509,6 +512,9 @@ mv -f Modules/FindLibArchive.disabled Modules/FindLibArchive.cmake
%changelog
* Mon Nov 09 2020 Miro Hrončok <mhroncok@redhat.com> - 3.18.4-2
- Add support for Python 3.10
* Tue Oct 13 10:03:16 CEST 2020 Björn Esser <besser82@fedoraproject.org> - 3.18.4-1
- Update to 3.18.4