From cf657aa7057788b6ddfa4c47b8d82d39864166fd4faad1f383c462e6f583c842 Mon Sep 17 00:00:00 2001 From: Benjamin Greiner Date: Sat, 1 Jul 2023 12:20:27 +0000 Subject: [PATCH] Accepting request 1096220 from home:StefanBruens:branches:science - Enable python311, libArcus does not support SIP > 4. Add python311_frame.patch OBS-URL: https://build.opensuse.org/request/show/1096220 OBS-URL: https://build.opensuse.org/package/show/KDE:Qt:PyQt/python-sip4?expand=0&rev=7 --- python-sip4.changes | 6 ++++++ python-sip4.spec | 3 ++- python311_frame.patch | 15 +++++++++++++++ 3 files changed, 23 insertions(+), 1 deletion(-) create mode 100644 python311_frame.patch diff --git a/python-sip4.changes b/python-sip4.changes index 62b336b..5bc74dd 100644 --- a/python-sip4.changes +++ b/python-sip4.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Sat Jul 1 00:12:29 UTC 2023 - Stefan BrĂ¼ns + +- Enable python311, libArcus does not support SIP > 4. + Add python311_frame.patch + ------------------------------------------------------------------- Sun Feb 19 20:29:32 UTC 2023 - Ben Greiner diff --git a/python-sip4.spec b/python-sip4.spec index e2c5e83..4220e87 100644 --- a/python-sip4.spec +++ b/python-sip4.spec @@ -36,7 +36,6 @@ # where X is the python flavor # python-sip4-doc and python-sip4-common are flavorless %define oldpython python -%define skip_python311 1 Name: python-%{pname} Version: 4.19.25 @@ -50,6 +49,8 @@ Source0: https://www.riverbankcomputing.com/static/Downloads/sip/%{versio Patch0: disable-rpaths.diff # PATCH-FIX-OPENSUSE disable-strip.diff -- Disable stripping Patch1: disable-strip.diff +# PATCH-FIX-OPENSUSE -- Use accessor for python frame object +Patch2: python311_frame.patch BuildRequires: %{python_module devel} BuildRequires: %{python_module setuptools} BuildRequires: c++_compiler diff --git a/python311_frame.patch b/python311_frame.patch new file mode 100644 index 0000000..a4f4aa7 --- /dev/null +++ b/python311_frame.patch @@ -0,0 +1,15 @@ +Taken from https://bugzilla.redhat.com/show_bug.cgi?id=2062144 + +diff --git a/siplib/siplib.c b/siplib/siplib.c +index db52b68..8019e97 100644 +--- a/siplib/siplib.c ++++ b/siplib/siplib.c +@@ -13747,7 +13747,7 @@ static struct _frame *sip_api_get_frame(int depth) + + while (frame != NULL && depth > 0) + { +- frame = frame->f_back; ++ frame = PyFrame_GetBack(frame); + --depth; + } +