wxPython: rebuild for Python 3.12
This commit is contained in:
parent
168f7617c6
commit
66afbe5dd1
3 changed files with 70 additions and 2 deletions
30
srcpkgs/wxPython/patches/00.python3.12.patch
Normal file
30
srcpkgs/wxPython/patches/00.python3.12.patch
Normal file
|
@ -0,0 +1,30 @@
|
||||||
|
https://src.fedoraproject.org/rpms/python-wxpython4/raw/46eb04f8ac5674968bfa3def439a67a39301024e
|
||||||
|
From 162cb57b94ba441febe6e1733117aca645a909a4 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Phil Thompson <phil@riverbankcomputing.com>
|
||||||
|
Date: Tue, 27 Jun 2023 11:36:18 +0200
|
||||||
|
Subject: [PATCH] For Python v3.12 implement sipPyTypeDict() using
|
||||||
|
PyType_GetDict().
|
||||||
|
|
||||||
|
---
|
||||||
|
sip/siplib/siplib.c | 4 ++++
|
||||||
|
1 file changed, 4 insertions(+)
|
||||||
|
|
||||||
|
diff --git a/sip/siplib/siplib.c b/sip/siplib/siplib.c
|
||||||
|
index d4003e9f..a52da595 100644
|
||||||
|
--- a/sip/siplib/siplib.c
|
||||||
|
+++ b/sip/siplib/siplib.c
|
||||||
|
@@ -12597,7 +12597,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
|
||||||
|
|
38
srcpkgs/wxPython/patches/01.python3.12.patch
Normal file
38
srcpkgs/wxPython/patches/01.python3.12.patch
Normal file
|
@ -0,0 +1,38 @@
|
||||||
|
https://src.fedoraproject.org/rpms/python-wxpython4/c/46eb04f8ac5674968bfa3def439a67a39301024e
|
||||||
|
|
||||||
|
From 9540ec1682a0f12e9634a0f087af8b85af45e547 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Phil Thompson <phil@riverbankcomputing.com>
|
||||||
|
Date: Mon, 26 Jun 2023 15:04:53 +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/siplib/siplib.c | 4 ++--
|
||||||
|
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/sip/siplib/siplib.c b/sip/siplib/siplib.c
|
||||||
|
index 95563e5c..d4003e9f 100644
|
||||||
|
--- a/sip/siplib/siplib.c
|
||||||
|
+++ b/sip/siplib/siplib.c
|
||||||
|
@@ -2147,7 +2147,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;
|
||||||
|
@@ -2159,7 +2159,7 @@ void *sip_api_malloc(size_t nbytes)
|
||||||
|
*/
|
||||||
|
void sip_api_free(void *mem)
|
||||||
|
{
|
||||||
|
- PyMem_Free(mem);
|
||||||
|
+ PyMem_RawFree(mem);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
--
|
||||||
|
2.40.1
|
||||||
|
|
|
@ -1,11 +1,11 @@
|
||||||
# Template file for 'wxPython'
|
# Template file for 'wxPython'
|
||||||
pkgname=wxPython
|
pkgname=wxPython
|
||||||
version=4.2.1
|
version=4.2.1
|
||||||
revision=2
|
revision=3
|
||||||
build_style=python3-module
|
build_style=python3-module
|
||||||
make_build_args="--skip-build"
|
make_build_args="--skip-build"
|
||||||
make_install_args="--skip-build"
|
make_install_args="--skip-build"
|
||||||
hostmakedepends="pkg-config python3-setuptools python3-pathlib2"
|
hostmakedepends="pkg-config python3-setuptools python3-pathlib2 python3-Cython0.29"
|
||||||
makedepends="python3-devel wxWidgets-gtk3-devel SDL2-devel webkit2gtk-devel
|
makedepends="python3-devel wxWidgets-gtk3-devel SDL2-devel webkit2gtk-devel
|
||||||
gst-plugins-base1-devel"
|
gst-plugins-base1-devel"
|
||||||
depends="python3 python3-six python3-numpy python3-Pillow"
|
depends="python3 python3-six python3-numpy python3-Pillow"
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue