[packages/python3-zlib-ng] - new
qboosh
qboosh at pld-linux.org
Tue Dec 16 19:15:25 CET 2025
commit 51ad96353b90d9571bfc31b2e50a479fda67d4af
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date: Tue Dec 16 19:15:39 2025 +0100
- new
python3-zlib-ng.spec | 75 ++++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 75 insertions(+)
---
diff --git a/python3-zlib-ng.spec b/python3-zlib-ng.spec
new file mode 100644
index 0000000..b2f3654
--- /dev/null
+++ b/python3-zlib-ng.spec
@@ -0,0 +1,75 @@
+#
+# Conditional build:
+%bcond_without tests # unit tests
+
+Summary: Drop-in replacement for zlib and gzip modules using zlib-ng
+Summary(pl.UTF-8): Zamiennik modułów zlib i gzip wykorzystujący zlib-ng
+Name: python3-zlib-ng
+Version: 1.0.0
+Release: 1
+License: PSF v2
+Group: Libraries/Python
+#Source0Download: https://pypi.org/simple/zlib-ng/
+Source0: https://files.pythonhosted.org/packages/source/z/zlib-ng/zlib_ng-%{version}.tar.gz
+# Source0-md5: 62afa0579667d1f9483aad8c5b458b1d
+URL: https://pypi.org/project/zlib-ng/
+BuildRequires: python3-devel >= 1:3.9
+BuildRequires: python3-setuptools >= 1:77
+BuildRequires: python3-setuptools_scm >= 8
+%if %{with tests}
+BuildRequires: python3-pytest
+BuildRequires: python3-pytest-timeout
+%endif
+BuildRequires: rpm-pythonprov
+BuildRequires: rpmbuild(macros) >= 1.714
+BuildRequires: zlib-ng-devel >= 2.2.5
+Requires: python3-modules >= 1:3.9
+Requires: zlib-ng >= 2.2.5
+BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%description
+Faster zlib and gzip compatible compression and decompression by
+providing Python bindings for the zlib-ng library.
+
+%description -l pl.UTF-8
+Szybsza kompresja i dekompresja zgodna ze zlib i gzip poprzez
+dostarczenie wiązań Pythona do biblioteki zlib-ng.
+
+%prep
+%setup -q -n zlib_ng-%{version}
+
+%build
+CFLAGS="%{rpmcflags} -I/usr/include/zlib-ng"
+export PYTHON_ZLIB_NG_LINK_DYNAMIC=1
+%py3_build
+
+%if %{with tests}
+PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 \
+PYTEST_PLUGINS=pytest_timeout \
+PYTHONPATH=$(readlink -f build-3/lib.*) \
+%{__python3} -m pytest tests
+%endif
+
+%install
+rm -rf $RPM_BUILD_ROOT
+
+export PYTHON_ZLIB_NG_LINK_DYNAMIC=1
+%py3_install
+
+# docs from internal zlib-ng library (packaged in zlib-ng.spec)
+%{__rm} $RPM_BUILD_ROOT%{py3_sitedir}/zlib_ng/zlib-ng/{LICENSE.md,README.md}
+rmdir $RPM_BUILD_ROOT%{py3_sitedir}/zlib_ng/zlib-ng
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%files
+%defattr(644,root,root,755)
+%doc CHANGELOG.rst README.rst
+%dir %{py3_sitedir}/zlib_ng
+%{py3_sitedir}/zlib_ng/*.py
+%{py3_sitedir}/zlib_ng/*.pyi
+%{py3_sitedir}/zlib_ng/*.so
+%{py3_sitedir}/zlib_ng/py.typed
+%{py3_sitedir}/zlib_ng/__pycache__
+%{py3_sitedir}/zlib_ng-%{version}-py*.egg-info
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/python3-zlib-ng.git/commitdiff/51ad96353b90d9571bfc31b2e50a479fda67d4af
More information about the pld-cvs-commit
mailing list