From 934f91cc45effb80952f6da9266a31b7137791bc Mon Sep 17 00:00:00 2001 From: Michel Lind Date: Tue, 9 Jan 2024 12:17:53 -0600 Subject: [PATCH] Update to 1.5.5.1 Signed-off-by: Michel Lind --- python-zstd-1.4.5.1-test-once.patch | 10 ---------- ...ch => python-zstd-1.5.5.1-test-external.patch | 2 +- python-zstd.spec | 16 +++++++++------- 3 files changed, 10 insertions(+), 18 deletions(-) delete mode 100644 python-zstd-1.4.5.1-test-once.patch rename python-zstd-1.4.5.1-test-external.patch => python-zstd-1.5.5.1-test-external.patch (90%) diff --git a/python-zstd-1.4.5.1-test-once.patch b/python-zstd-1.4.5.1-test-once.patch deleted file mode 100644 index 438523d..0000000 --- a/python-zstd-1.4.5.1-test-once.patch +++ /dev/null @@ -1,10 +0,0 @@ ---- a/setup.py -+++ b/setup.py -@@ -171,7 +173,6 @@ - Extension('zstd', zstdFiles, libraries=ext_libraries) - ], - cmdclass = {'build_ext': ZstdBuildExt }, -- test_suite='setup.my_test_suite', - classifiers=[ - 'License :: OSI Approved :: BSD License', - 'Intended Audience :: Developers', diff --git a/python-zstd-1.4.5.1-test-external.patch b/python-zstd-1.5.5.1-test-external.patch similarity index 90% rename from python-zstd-1.4.5.1-test-external.patch rename to python-zstd-1.5.5.1-test-external.patch index 548810f..1d34fa6 100644 --- a/python-zstd-1.4.5.1-test-external.patch +++ b/python-zstd-1.5.5.1-test-external.patch @@ -1,6 +1,6 @@ --- a/setup.py +++ b/setup.py -@@ -97,6 +97,8 @@ +@@ -119,6 +119,8 @@ else: class ZstdBuildExt( build_ext ): def build_extensions(self): diff --git a/python-zstd.spec b/python-zstd.spec index ec78faa..754cce5 100644 --- a/python-zstd.spec +++ b/python-zstd.spec @@ -1,5 +1,5 @@ %global pypi_name zstd -%global zstd_version 1.4.5 +%global zstd_version 1.5.5 Name: python-%{pypi_name} Version: 1.5.5.1 @@ -9,11 +9,10 @@ Summary: Zstd Bindings for Python # original zstd bits are GPL-2.0-or-later OR BSD-2-Clause License: BSD-2-Clause AND (GPL-2.0-or-later OR BSD-2-Clause) URL: https://github.com/sergey-dryabzhinsky/python-zstd -Source0: %{pypi_source} +Source: %{pypi_source} # Patches to fix test execution -Patch0: python-zstd-1.4.5.1-test-external.patch -Patch1: python-zstd-1.4.5.1-test-once.patch +Patch: python-zstd-1.5.5.1-test-external.patch BuildRequires: gcc BuildRequires: python3-devel @@ -36,16 +35,19 @@ Simple Python bindings for the Zstd compression library. %prep %autosetup -p1 -n %{pypi_name}-%{version} # Remove bundled egg-info -rm -rf %{pypi_name}.egg-info +rm -rf src/%{pypi_name}.egg-info +# Remove precompiled files +find . -name '*.pyc' -delete # Remove bundled zstd library rm -rf zstd/ # do not test the version matching, we don't really need exact version of # zstd here rm tests/test_version.py +sed -i -e '/tests\.test_version/d' setup.py sed -i -e '/test_version/d' tests/__init__.py %build -%py3_build -- --legacy --pyzstd-legacy --external +%py3_build -- --legacy --external %install %py3_install @@ -60,7 +62,7 @@ sed -i -e '/test_version/d' tests/__init__.py %{python3_sitearch}/%{pypi_name}*.so %changelog -* Mon Jan 08 2024 Michel Lind - 1.5.5.1-1 +* Tue Jan 09 2024 Michel Lind - 1.5.5.1-1 - Update to 1.5.5.1 * Fri Jul 21 2023 Fedora Release Engineering - 1.4.5.1-12