Sync from SUSE:SLFO:Main python313 revision 3a4e5c994aa27bd66e968be481da9eb4

This commit is contained in:
2025-02-25 19:38:36 +01:00
parent 1faa76760c
commit d4d0782687
9 changed files with 768 additions and 59 deletions

View File

@@ -1,7 +1,7 @@
#
# spec file for package python313
#
# Copyright (c) 2024 SUSE LLC
# Copyright (c) 2025 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -73,6 +73,14 @@
%endif
%endif
# Only for Tumbleweed
# https://en.opensuse.org/openSUSE:Python:Externally_managed
%if 0%{?suse_version} > 1600
%bcond_without externally_managed
%else
%bcond_with externally_managed
%endif
%define python_pkg_name python313
%if %{without GIL}
%define python_pkg_name python313-nogil
@@ -149,7 +157,7 @@
# _md5.cpython-38m-x86_64-linux-gnu.so
%define dynlib() %{sitedir}/lib-dynload/%{1}.cpython-%{abi_tag}-%{archname}-%{_os}%{?_gnu}%{?armsuffix}.so
Name: %{python_pkg_name}%{psuffix}
Version: 3.13.1
Version: 3.13.2
%define tarversion %{version}
%define tarname Python-%{tarversion}
Release: 0
@@ -206,9 +214,9 @@ Patch09: skip-test_pyobject_freed_is_freed.patch
# PATCH-FIX-OPENSUSE fix-test-recursion-limit-15.6.patch gh#python/cpython#115083
# Skip some failing tests in test_compile for i586 arch in 15.6.
Patch40: fix-test-recursion-limit-15.6.patch
# PATCH-FIX-UPSTREAM CVE-2024-12254-unbound-mem-buffering-SelectorSocketTransport.writelines.patch bsc#1234290 mcepl@suse.com
# prevents exhaustion of memory
Patch41: CVE-2024-12254-unbound-mem-buffering-SelectorSocketTransport.writelines.patch
# PATCH-FIX-SLE doc-py38-to-py36.patch mcepl@suse.com
# Make documentation extensions working with Python 3.6
Patch41: doc-py38-to-py36.patch
BuildRequires: autoconf-archive
BuildRequires: automake
BuildRequires: fdupes
@@ -796,7 +804,7 @@ rm %{buildroot}%{_libdir}/libpython3.so
rm %{buildroot}%{_libdir}/pkgconfig/{python3,python3-embed}.pc
%endif
%if %{suse_version} > 1550
%if %{with externally_managed}
# PEP-0668 mark this as a distro maintained python
sed -e 's,__PYTHONPREFIX__,%{python_pkg_name},' -e 's,__PYTHON__,python%{python_version},' < %{SOURCE4} > %{buildroot}%{sitedir}/EXTERNALLY-MANAGED
%endif
@@ -998,7 +1006,7 @@ fi
%{_mandir}/man1/python%{python_version}.1%{?ext_man}
%endif
%if %{suse_version} > 1550
%if %{with externally_managed}
# PEP-0668
%{sitedir}/EXTERNALLY-MANAGED
%endif