From 50826e1f07e65b7f2a68ce8a1509464d20606445 Mon Sep 17 00:00:00 2001 From: Gwyn Ciesla Date: Tue, 24 Oct 2023 11:33:30 -0500 Subject: [PATCH] 2.11, patch for python 3.13 --- .gitignore | 1 + py312.patch | 36 ------------------------------------ py313.patch | 10 ++++++++++ pyicu.spec | 11 +++++++---- sources | 2 +- 5 files changed, 19 insertions(+), 41 deletions(-) delete mode 100644 py312.patch create mode 100644 py313.patch diff --git a/.gitignore b/.gitignore index f424415..98e6197 100644 --- a/.gitignore +++ b/.gitignore @@ -10,3 +10,4 @@ /PyICU-2.7.3.tar.gz /PyICU-2.9.tar.gz /PyICU-2.10.2.tar.gz +/PyICU-2.11.tar.gz diff --git a/py312.patch b/py312.patch deleted file mode 100644 index e7d240b..0000000 --- a/py312.patch +++ /dev/null @@ -1,36 +0,0 @@ ---- common.cpp~ 2022-10-24 23:27:33.000000000 -0500 -+++ common.cpp 2023-03-09 09:44:13.652450597 -0600 -@@ -361,33 +361,6 @@ - PyUnicode_READY(object); - - switch (PyUnicode_KIND(object)) { -- case PyUnicode_WCHAR_KIND: { // this code path should be deprecated -- if (SIZEOF_WCHAR_T == sizeof(UChar)) -- { -- Py_ssize_t len; -- wchar_t *wchars = PyUnicode_AsWideCharString(object, &len); -- -- if (wchars != NULL) -- { -- string.setTo((const UChar *) wchars, len); -- PyMem_Free(wchars); -- } -- } -- else if (SIZEOF_WCHAR_T == sizeof(UChar32)) -- { -- Py_ssize_t len; -- wchar_t *wchars = PyUnicode_AsWideCharString(object, &len); -- -- if (wchars != NULL) -- { -- string = UnicodeString::fromUTF32( -- (const UChar32 *) wchars, len); -- PyMem_Free(wchars); -- } -- } -- break; -- } -- - case PyUnicode_1BYTE_KIND: { - Py_ssize_t len = PyUnicode_GET_LENGTH(object); - Py_UCS1 *pchars = PyUnicode_1BYTE_DATA(object); diff --git a/py313.patch b/py313.patch new file mode 100644 index 0000000..6408726 --- /dev/null +++ b/py313.patch @@ -0,0 +1,10 @@ +--- locale.cpp~ 2023-04-14 13:45:50.000000000 -0500 ++++ locale.cpp 2023-10-24 11:28:55.596502687 -0500 +@@ -23,6 +23,7 @@ + + #include + #include ++#include + + #if defined(_MSC_VER) || defined(__WIN32) + #include diff --git a/pyicu.spec b/pyicu.spec index c564d17..59effa4 100644 --- a/pyicu.spec +++ b/pyicu.spec @@ -1,13 +1,13 @@ %define realname PyICU Name: pyicu -Version: 2.10.2 -Release: 7%{?dist} +Version: 2.11 +Release: 1%{?dist} Summary: Python extension wrapping the ICU C++ libraries License: MIT URL: https://pypi.org/project/PyICU/ Source0: https://files.pythonhosted.org/packages/source/P/%{realname}/%{realname}-%{version}.tar.gz -Patch0: py312.patch +Patch0: py313.patch BuildRequires: gcc-c++ BuildRequires: libicu-devel @@ -32,7 +32,7 @@ Summary: Python 3 extension wrapping the ICU C++ libraries %prep %setup -q -n %{realname}-%{version} -%patch0 -p0 +%patch -P 0 -p0 %build %py3_build @@ -60,6 +60,9 @@ rm -rf %{buildroot}%{python3_sitearch}/tests %{python3_sitearch}/icu/ %changelog +* Tue Oct 24 2023 Gwyn Ciesla - 2.11-1 +- 2.11 + * Fri Jul 21 2023 Fedora Release Engineering - 2.10.2-7 - Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild diff --git a/sources b/sources index 57369a1..4e52fdf 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (PyICU-2.10.2.tar.gz) = 1ccb43496e1719314c2f1f81f6535cb57688917b19fdbc56b2773f9372f70160d69660a67f63fde3cee0384d7df649aad8539375be5c9be3ede8e1335a126bd7 +SHA512 (PyICU-2.11.tar.gz) = d57ca2b29eafe336efca5285e10c9bfe1a6a1b575b3e52accd86a114ccf289bea0c004a5b26bd4e800211cca61df5aa1a11348a3f1dc73672b7b76dd971d6a25