[packages/python-BTrees] - updated to 4.7.2, finished package
qboosh
qboosh at pld-linux.org
Tue Apr 26 22:52:40 CEST 2022
commit b97d8a497f0eda9370873ae58918d19c053241a9
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date: Tue Apr 26 22:52:58 2022 +0200
- updated to 4.7.2, finished package
python-BTrees.spec | 112 +++++++++++++++++++++++++++++++++--------------------
1 file changed, 71 insertions(+), 41 deletions(-)
---
diff --git a/python-BTrees.spec b/python-BTrees.spec
index 8b59aeb..1adb398 100644
--- a/python-BTrees.spec
+++ b/python-BTrees.spec
@@ -1,78 +1,103 @@
-# TODO:
-# - fix tests: ... skipped 'ZODB not available' , ZODB though depends on BTrees
-# - fix docs build
+# TODO: optional ZODB for tests (circular dependency)
# Conditional build:
-%bcond_with doc # don't build doc
-%bcond_without tests # do not perform "make test"
+%bcond_without doc # Sphinx documentation
+%bcond_without tests # unit tests
%bcond_without python2 # CPython 2.x module
%bcond_without python3 # CPython 3.x module
%define module BTrees
-%define pypi_name %{module}
Summary: Scalable persistent object containers
Summary(pl.UTF-8): Skalowalne trwałe kontenery dla obiektów
Name: python-%{module}
-Version: 4.4.1
-Release: 12
-License: ZPL 2.1
+# >= 4.8.0 requires zope.interface >= 5.0.0
+Version: 4.7.2
+Release: 1
+License: ZPL v2.1
Group: Libraries/Python
-#Source0: https://files.pythonhosted.org/packages/source/B/%{pypi_name}/%{pypi_name}-%{version}.tar.gz
-#Source0: https://pypi.python.org/packages/source/B/%{pypi_name}/%{pypi_name}-%{version}.tar.gz
-Source0: https://pypi.python.org/packages/6a/e2/d8c2a5b4cbc493b1ccb440d61bf0f62b8a0cb1c7b5aa403d5e18847545b3/BTrees-%{version}.tar.gz
-# Source0-md5: 6a0178e30b94cf0cc44ae62e93187ecc
-URL: http://packages.python.org/BTrees
+#Source0Download: https://pypi.org/simple/BTrees/
+Source0: https://files.pythonhosted.org/packages/source/B/BTrees/%{module}-%{version}.tar.gz
+# Source0-md5: 392ef0942c648fb66f2ee86da8479345
+URL: https://pypi.org/project/BTrees/
BuildRequires: rpm-pythonprov
-# for the py_build, py_install macros
BuildRequires: rpmbuild(macros) >= 1.714
%if %{with python2}
-BuildRequires: python-devel
-BuildRequires: python-persistent >= 4.0.4
-#BuildRequires: python-setuptools
+BuildRequires: python-devel >= 1:2.7
+BuildRequires: python-persistent-devel >= 4.1.0
+BuildRequires: python-setuptools
+%if %{with tests}
+#BuildRequires: python-ZODB
+BuildRequires: python-persistent >= 4.4.3
BuildRequires: python-transaction
+BuildRequires: python-zope.interface
+BuildRequires: python-zope.testrunner
+%endif
%endif
%if %{with python3}
-BuildRequires: python3-devel
-BuildRequires: python3-persistent >= 4.0.4
-#BuildRequires: python3-setuptools
+BuildRequires: python3-devel >= 1:3.5
+BuildRequires: python3-persistent-devel >= 4.1.0
+BuildRequires: python3-setuptools
+%if %{with tests}
+#BuildRequires: python3-ZODB
+BuildRequires: python3-persistent >= 4.4.3
BuildRequires: python3-transaction
+BuildRequires: python3-zope.interface
+BuildRequires: python3-zope.testrunner
%endif
-
-# when using /usr/bin/env or other in-place substitutions
-#BuildRequires: sed >= 4.0
-# replace with other requires if defined in setup.py
-Requires: python-modules
+%endif
+%if %{with doc}
+BuildRequires: python3-repoze.sphinx.autointerface
+BuildRequires: python3-sphinx_rtd_theme
+BuildRequires: sphinx-pdg-3 >= 1.8
+%endif
+Requires: python-modules >= 1:2.7
%requires_eq python-persistent
-Requires: python-transaction
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
%description
+This package contains a set of persistent object containers built
+around a modified BTree data structure. The trees are optimized for
+use inside ZODB's "optimistic concurrency" paradigm, and include
+explicit resolution of conflicts detected by that mechanism.
%description -l pl.UTF-8
+Ten pakiet zawiera zbiór trwałych kontenerów dla obiektów, zbudowanych
+w oparciu o zmodyfikowane struktury danych B-drzewa. Drzewa są
+zoptymalizowane pod kątem użycia wewnątrz paradygmatu "optymistycznej
+współbieżności" ZODB i zawierają jawne rozwiązywanie konfliktów
+wykrytych przez ten mechanizm.
%package -n python3-%{module}
-Summary: -
-Summary(pl.UTF-8): -
+Summary: Scalable persistent object containers
+Summary(pl.UTF-8): Skalowalne trwałe kontenery dla obiektów
Group: Libraries/Python
-Requires: python3-modules
+Requires: python3-modules >= 1:3.5
%requires_eq python3-persistent
-Requires: python3-transaction
%description -n python3-%{module}
+This package contains a set of persistent object containers built
+around a modified BTree data structure. The trees are optimized for
+use inside ZODB's "optimistic concurrency" paradigm, and include
+explicit resolution of conflicts detected by that mechanism.
%description -n python3-%{module} -l pl.UTF-8
+Ten pakiet zawiera zbiór trwałych kontenerów dla obiektów, zbudowanych
+w oparciu o zmodyfikowane struktury danych B-drzewa. Drzewa są
+zoptymalizowane pod kątem użycia wewnątrz paradygmatu "optymistycznej
+współbieżności" ZODB i zawierają jawne rozwiązywanie konfliktów
+wykrytych przez ten mechanizm.
%package apidocs
-Summary: %{module} API documentation
-Summary(pl.UTF-8): Dokumentacja API %{module}
+Summary: API documentation for Python BTrees module
+Summary(pl.UTF-8): Dokumentacja API modułu Pythona BTrees
Group: Documentation
%description apidocs
-API documentation for %{module}.
+API documentation for Python BTrees module.
%description apidocs -l pl.UTF-8
-Dokumentacja API %{module}.
+Dokumentacja API modułu Pythona BTrees.
%prep
%setup -q -n %{module}-%{version}
@@ -87,20 +112,27 @@ Dokumentacja API %{module}.
%endif
%if %{with doc}
-cd docs
-%{__make} -j1 html
-rm -rf _build/html/_sources
+PYTHONPATH=$(pwd):$(echo $(pwd)/build-3/lib.*) \
+%{__make} -C docs html \
+ SPHINXBUILD=sphinx-build-3
%endif
%install
rm -rf $RPM_BUILD_ROOT
+
%if %{with python2}
%py_install
+
+%{__rm} -r $RPM_BUILD_ROOT%{py_sitedir}/%{module}/*.[ch]
+%{__rm} -r $RPM_BUILD_ROOT%{py_sitedir}/%{module}/tests
%py_postclean
%endif
%if %{with python3}
%py3_install
+
+%{__rm} -r $RPM_BUILD_ROOT%{py3_sitedir}/%{module}/*.[ch]
+%{__rm} -r $RPM_BUILD_ROOT%{py3_sitedir}/%{module}/tests
%endif
%clean
@@ -112,7 +144,6 @@ rm -rf $RPM_BUILD_ROOT
%doc CHANGES.rst README.rst
%dir %{py_sitedir}/%{module}
%{py_sitedir}/%{module}/*.py[co]
-%{py_sitedir}/%{module}/*.[ch]
%attr(755,root,root) %{py_sitedir}/%{module}/*.so
%{py_sitedir}/%{module}-%{version}-py*.egg-info
%endif
@@ -123,7 +154,6 @@ rm -rf $RPM_BUILD_ROOT
%doc CHANGES.rst README.rst
%dir %{py3_sitedir}/%{module}
%{py3_sitedir}/%{module}/*.py
-%{py3_sitedir}/%{module}/*.[ch]
%attr(755,root,root) %{py3_sitedir}/%{module}/*.so
%{py3_sitedir}/%{module}/__pycache__
%{py3_sitedir}/%{module}-%{version}-py*.egg-info
@@ -132,5 +162,5 @@ rm -rf $RPM_BUILD_ROOT
%if %{with doc}
%files apidocs
%defattr(644,root,root,755)
-%doc docs/_build/html/*
+%doc docs/_build/html/{_modules,_static,*.html,*.js}
%endif
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/python-BTrees.git/commitdiff/b97d8a497f0eda9370873ae58918d19c053241a9
More information about the pld-cvs-commit
mailing list