diff --git a/For-Python-v3.12-implement-sipPyTypeDict-using-PyTyp.patch b/For-Python-v3.12-implement-sipPyTypeDict-using-PyTyp.patch deleted file mode 100644 index 3bc67bb..0000000 --- a/For-Python-v3.12-implement-sipPyTypeDict-using-PyTyp.patch +++ /dev/null @@ -1,29 +0,0 @@ -From 8d7bede5ac43fad34383c7a507fdf7f8fb6a5c68 Mon Sep 17 00:00:00 2001 -From: Phil Thompson -Date: Wed, 21 Jun 2023 14:38:45 +0200 -Subject: [PATCH] For Python v3.12 implement sipPyTypeDict() using - PyType_GetDict(). - ---- - sip_core.c | 4 ++++ - 1 file changed, 4 insertions(+) - -diff --git a/sip_core.c b/sip_core.c -index a51513f..7203bce 100644 ---- a/sip_core.c -+++ b/sip_core.c -@@ -11112,7 +11112,11 @@ static void *sip_api_get_type_user_data(const sipWrapperType *wt) - */ - static PyObject *sip_api_py_type_dict(const PyTypeObject *py_type) - { -+#if PY_VERSION_HEX >= 0x030c0000 -+ return PyType_GetDict(py_type); -+#else - return py_type->tp_dict; -+#endif - } - - --- -2.40.1 - diff --git a/python-pyqt6-sip.spec b/python-pyqt6-sip.spec index ea1c810..6fb65e4 100644 --- a/python-pyqt6-sip.spec +++ b/python-pyqt6-sip.spec @@ -12,11 +12,6 @@ Summary: The sip module support for PyQt6 License: GPL-2.0-only OR GPL-3.0-only URL: https://www.riverbankcomputing.com/software/sip/ Source0: %{pypi_source} -# Patches needed for compatibility with Python 3.12 -# https://www.riverbankcomputing.com/hg/sip/rev/312476401030 -Patch: sipMalloc-and-sipFree-are-now-implemented-using-PyMe.patch -# https://www.riverbankcomputing.com/hg/sip/rev/d36867e54192 -Patch: For-Python-v3.12-implement-sipPyTypeDict-using-PyTyp.patch BuildRequires: gcc BuildRequires: python3-devel diff --git a/sipMalloc-and-sipFree-are-now-implemented-using-PyMe.patch b/sipMalloc-and-sipFree-are-now-implemented-using-PyMe.patch deleted file mode 100644 index ff3e63f..0000000 --- a/sipMalloc-and-sipFree-are-now-implemented-using-PyMe.patch +++ /dev/null @@ -1,36 +0,0 @@ -From 9c13eac1177f90a44f811f265ea8e4caa41879c9 Mon Sep 17 00:00:00 2001 -From: Phil Thompson -Date: Wed, 21 Jun 2023 14:30:26 +0200 -Subject: [PATCH] sipMalloc() and sipFree() are now implemented using - PyMem_RawMalloc() and PyMem_RawFree() so that they should be safe to call - from functions registered with Py_AtExit(). - ---- - sip_core.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/sip_core.c b/sip_core.c -index f763090..a51513f 100644 ---- a/sip_core.c -+++ b/sip_core.c -@@ -1886,7 +1886,7 @@ void *sip_api_malloc(size_t nbytes) - { - void *mem; - -- if ((mem = PyMem_Malloc(nbytes)) == NULL) -+ if ((mem = PyMem_RawMalloc(nbytes)) == NULL) - PyErr_NoMemory(); - - return mem; -@@ -1898,7 +1898,7 @@ void *sip_api_malloc(size_t nbytes) - */ - void sip_api_free(void *mem) - { -- PyMem_Free(mem); -+ PyMem_RawFree(mem); - } - - --- -2.40.1 -