[packages/python3-cattrs] - python-cattrs.spec updated to 1.9.0 for python 3.7+

qboosh qboosh at pld-linux.org
Mon Dec 13 22:24:19 CET 2021


commit 9a6ffd3f5832c9e374b6cd6c199745bdc86e4abd
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Mon Dec 13 22:24:55 2021 +0100

    - python-cattrs.spec updated to 1.9.0 for python 3.7+

 python-cattrs.spec  | 151 ----------------------------------------------------
 python3-cattrs.spec |  65 ++++++++++++++++++++++
 2 files changed, 65 insertions(+), 151 deletions(-)
---
diff --git a/python-cattrs.spec b/python-cattrs.spec
deleted file mode 100644
index 4620355..0000000
--- a/python-cattrs.spec
+++ /dev/null
@@ -1,151 +0,0 @@
-#
-# Conditional build:
-%bcond_without	doc	# Sphinx documentation
-%bcond_with	tests	# unit tests (not included in sdist)
-%bcond_without	python2 # CPython 2.x module
-%bcond_with	python3 # CPython 3.x module (built from python3-cattrs.spec)
-
-Summary:	Composable complex class support for attrs
-Summary(pl.UTF-8):	Obsługa składanych klas złożonych dla attrs
-Name:		python-cattrs
-# keep 1.0.x here for python2 support
-Version:	1.0.0
-Release:	1
-License:	MIT
-Group:		Libraries/Python
-#Source0Download: https://pypi.org/simple/cattrs/
-Source0:	https://files.pythonhosted.org/packages/source/c/cattrs/cattrs-%{version}.tar.gz
-# Source0-md5:	c57222f5475f0158d2bffb87ac1411f9
-URL:		https://pypi.org/project/cattrs/
-%if %{with python2}
-BuildRequires:	python-modules >= 1:2.7
-BuildRequires:	python-setuptools
-%if %{with tests}
-BuildRequires:	python-attrs >= 17.3
-BuildRequires:	python-enum34 >= 1.1.6
-BuildRequires:	python-functools32 >= 3.2.3
-BuildRequires:	python-pytest
-BuildRequires:	python-singledispatch >= 3.4.0.3
-BuildRequires:	python-typing >= 3.5.3
-%endif
-%endif
-%if %{with python3}
-BuildRequires:	python3-modules >= 1:3.5
-BuildRequires:	python3-setuptools
-%if %{with tests}
-BuildRequires:	python3-attrs >= 17.3
-BuildRequires:	python3-pytest
-%endif
-%endif
-BuildRequires:	rpm-pythonprov
-BuildRequires:	rpmbuild(macros) >= 1.714
-%if %{with doc}
-BuildRequires:	sphinx-pdg
-%endif
-Requires:	python-modules >= 1:2.7
-BuildArch:	noarch
-BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
-
-%description
-cattrs is an open source Python library for structuring and
-unstructuring data. cattrs works best with attrs classes and the usual
-Python collections, but other kinds of classes are supported by
-manually registering converters.
-
-%description -l pl.UTF-8
-cattrs to mająca otwarte źródła biblioteka Pythona do strukturyzacji i
-destrukturyzacji danych. Najlepiej działa z klasami attrs oraz
-zwykłymi kolekcjami Pythona, ale inne rodzaje klas są obsługiwane
-poprzez ręcznie rejestrowane konwertery.
-
-%package -n python3-cattrs
-Summary:	Composable complex class support for attrs
-Summary(pl.UTF-8):	Obsługa składanych klas złożonych dla attrs
-Group:		Libraries/Python
-Requires:	python3-modules >= 1:3.5
-
-%description -n python3-cattrs
-cattrs is an open source Python library for structuring and
-unstructuring data. cattrs works best with attrs classes and the usual
-Python collections, but other kinds of classes are supported by
-manually registering converters.
-
-%description -n python3-cattrs -l pl.UTF-8
-cattrs to mająca otwarte źródła biblioteka Pythona do strukturyzacji i
-destrukturyzacji danych. Najlepiej działa z klasami attrs oraz
-zwykłymi kolekcjami Pythona, ale inne rodzaje klas są obsługiwane
-poprzez ręcznie rejestrowane konwertery.
-
-%package apidocs
-Summary:	API documentation for Python cattrs module
-Summary(pl.UTF-8):	Dokumentacja API modułu Pythona cattrs
-Group:		Documentation
-
-%description apidocs
-API documentation for Python cattrs module.
-
-%description apidocs -l pl.UTF-8
-Dokumentacja API modułu Pythona cattrs.
-
-%prep
-%setup -q -n cattrs-%{version}
-
-%build
-%if %{with python2}
-%py_build
-
-%if %{with tests}
-%{__python} -m pytest tests
-%endif
-%endif
-
-%if %{with python3}
-%py3_build
-
-%if %{with tests}
-%{__python3} -m pytest tests
-%endif
-%endif
-
-%if %{with doc}
-PYTHONPATH=$(pwd)/src \
-%{__make} -C docs html
-%endif
-
-%install
-rm -rf $RPM_BUILD_ROOT
-
-%if %{with python2}
-%py_install
-
-%py_postclean
-%endif
-
-%if %{with python3}
-%py3_install
-%endif
-
-%clean
-rm -rf $RPM_BUILD_ROOT
-
-%if %{with python2}
-%files
-%defattr(644,root,root,755)
-%doc HISTORY.rst LICENSE README.rst
-%{py_sitescriptdir}/cattr
-%{py_sitescriptdir}/cattrs-%{version}-py*.egg-info
-%endif
-
-%if %{with python3}
-%files -n python3-cattrs
-%defattr(644,root,root,755)
-%doc HISTORY.rst LICENSE README.rst
-%{py3_sitescriptdir}/cattr
-%{py3_sitescriptdir}/cattrs-%{version}-py*.egg-info
-%endif
-
-%if %{with doc}
-%files apidocs
-%defattr(644,root,root,755)
-%doc docs/_build/html/{_static,*.html,*.js}
-%endif
diff --git a/python3-cattrs.spec b/python3-cattrs.spec
new file mode 100644
index 0000000..23a57c7
--- /dev/null
+++ b/python3-cattrs.spec
@@ -0,0 +1,65 @@
+#
+# Conditional build:
+%bcond_with	tests	# unit tests (not included in sdist)
+
+Summary:	Composable complex class support for attrs
+Summary(pl.UTF-8):	Obsługa składanych klas złożonych dla attrs
+Name:		python3-cattrs
+Version:	1.9.0
+Release:	1
+License:	MIT
+Group:		Libraries/Python
+#Source0Download: https://pypi.org/simple/cattrs/
+Source0:	https://files.pythonhosted.org/packages/source/c/cattrs/cattrs-%{version}.tar.gz
+# Source0-md5:	85d792526f4a684b642e0d30a22dcf58
+URL:		https://pypi.org/project/cattrs/
+BuildRequires:	python3-modules >= 1:3.7
+BuildRequires:	python3-setuptools
+%if %{with tests}
+BuildRequires:	python3-attrs >= 20
+BuildRequires:	python3-pytest
+%if "%{py3_ver}" == "3.7"
+BuildRequires:	python3-typing_extensions
+%endif
+%endif
+BuildRequires:	rpm-pythonprov
+BuildRequires:	rpmbuild(macros) >= 1.714
+Requires:	python3-modules >= 1:3.7
+BuildArch:	noarch
+BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%description
+cattrs is an open source Python library for structuring and
+unstructuring data. cattrs works best with attrs classes and the usual
+Python collections, but other kinds of classes are supported by
+manually registering converters.
+
+%description -l pl.UTF-8
+cattrs to mająca otwarte źródła biblioteka Pythona do strukturyzacji i
+destrukturyzacji danych. Najlepiej działa z klasami attrs oraz
+zwykłymi kolekcjami Pythona, ale inne rodzaje klas są obsługiwane
+poprzez ręcznie rejestrowane konwertery.
+
+%prep
+%setup -q -n cattrs-%{version}
+
+%build
+%py3_build
+
+%if %{with tests}
+%{__python3} -m pytest tests
+%endif
+
+%install
+rm -rf $RPM_BUILD_ROOT
+
+%py3_install
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%files
+%defattr(644,root,root,755)
+%doc LICENSE README.rst
+%{py3_sitescriptdir}/cattr
+%{py3_sitescriptdir}/cattrs-%{version}-py*.egg-info
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/python3-cattrs.git/commitdiff/9a6ffd3f5832c9e374b6cd6c199745bdc86e4abd



More information about the pld-cvs-commit mailing list