[packages/python-WebOb] - updated to 1.8.2

qboosh qboosh at pld-linux.org
Fri Jul 20 19:39:27 CEST 2018


commit 8fa0503048fcd0d38898106ebb45a0af2f6411ed
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Fri Jul 20 19:41:22 2018 +0200

    - updated to 1.8.2

 python-WebOb.spec | 105 +++++++++++++++++++++++++++++++++++++++++++++---------
 1 file changed, 89 insertions(+), 16 deletions(-)
---
diff --git a/python-WebOb.spec b/python-WebOb.spec
index 54bc67a..da0250a 100644
--- a/python-WebOb.spec
+++ b/python-WebOb.spec
@@ -1,22 +1,42 @@
 #
 # Conditional build:
+%bcond_without	python2	# CPython 2.x module
 %bcond_without	python3	# CPython 3.x module
+%bcond_without	doc	# Sphinx documentation
+%bcond_without	tests	# unit tests
 
 %define 	module	WebOb
 Summary:	WSGI request and response object
+Summary(pl.UTF-8):	Obiekty żądań i odpowiedzi WSGI
 Name:		python-%{module}
-Version:	1.2.3
-Release:	7
+Version:	1.8.2
+Release:	1
 License:	MIT
-Group:		Development/Languages/Python
-Source0:	http://pypi.python.org/packages/source/W/WebOb/%{module}-%{version}.tar.gz
-# Source0-md5:	11825b7074ba7043e157805e4e6e0f55
-URL:		http://webob.org/
-BuildRequires:	python-devel
+Group:		Libraries/Python
+#Source0Download: https://pypi.org/simple/WebOb/
+Source0:	https://files.pythonhosted.org/packages/source/W/WebOb/%{module}-%{version}.tar.gz
+# Source0-md5:	d04756e6683fedddba52eafbe9adf404
+URL:		https://webob.org/
+%if %{with python2}
+BuildRequires:	python-devel >= 1:2.7
 BuildRequires:	python-setuptools
+%if %{with tests}
+BuildRequires:	python-pytest >= 3.1.0
+%endif
+%endif
+%if %{with python3}
+BuildRequires:	python3-devel >= 1:3.4
+BuildRequires:	python3-setuptools
+%if %{with tests}
+BuildRequires:	python3-pytest >= 3.1.0
+%endif
+%endif
 BuildRequires:	rpm-pythonprov
-BuildRequires:	rpmbuild(macros) >= 1.710
-Requires:	python-modules
+BuildRequires:	rpmbuild(macros) >= 1.714
+%if %{with doc}
+BuildRequires:	sphinx-pdg >= 1.3.1
+%endif
+Requires:	python-modules >= 1:2.7
 BuildArch:	noarch
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
@@ -28,8 +48,17 @@ The objects map much of the specified behavior of HTTP, including
 header parsing and accessors for other standard parts of the
 environment.
 
+%description -l pl.UTF-8
+Moduł WebOb udostępnia opakowanie środowiska żądań WSGI oraz
+obiekty pomagające przy tworzeniu odpowiedzi WSGI.
+
+Obiekty odwzorowują większość określonego zachowania HTTP, w tym
+analizę nagłówków oraz dostęp do innych standardowych elementów
+środowiska.
+
 %package -n python3-%{module}
-Summary:	Add options to doctest examples while they are running
+Summary:	WSGI request and response object
+Summary(pl.UTF-8):	Obiekty żądań i odpowiedzi WSGI
 Group:		Libraries/Python
 
 %description -n python3-%{module}
@@ -40,21 +69,60 @@ The objects map much of the specified behavior of HTTP, including
 header parsing and accessors for other standard parts of the
 environment.
 
+%description -n python3-%{module} -l pl.UTF-8
+Moduł WebOb udostępnia opakowanie środowiska żądań WSGI oraz
+obiekty pomagające przy tworzeniu odpowiedzi WSGI.
+
+Obiekty odwzorowują większość określonego zachowania HTTP, w tym
+analizę nagłówków oraz dostęp do innych standardowych elementów
+środowiska.
+
+%package apidocs
+Summary:	API documentation for Python WebOb module
+Summary(pl.UTF-8):	Dokumentacja API modułu Pythona WebOb
+Group:		Documentation
+
+%description apidocs
+API documentation for Python WebOb module.
+
+%description apidocs -l pl.UTF-8
+Dokumentacja API modułu Pythona WebOb.
+
 %prep
 %setup -q -n %{module}-%{version}
 
 %build
+%if %{with python2}
 %py_build
 
+%if %{with tests}
+PYTHONPATH=$(pwd)/src \
+%{__python} -m unittest discover -s tests
+%endif
+%endif
+
 %if %{with python3}
 %py3_build
+
+%if %{with tests}
+PYTHONPATH=$(pwd)/src \
+%{__python3} -m unittest discover -s tests
+%endif
+%endif
+
+%if %{with doc}
+PYTHONPATH=$(pwd)/src \
+%{__make} -C docs html  SPHINXBUILD=sphinx-build-2
 %endif
 
 %install
 rm -rf $RPM_BUILD_ROOT
+
+%if %{with python2}
 %py_install
 
 %py_postclean
+%endif
 
 %if %{with python3}
 %py3_install
@@ -63,19 +131,24 @@ rm -rf $RPM_BUILD_ROOT
 %clean
 rm -rf $RPM_BUILD_ROOT
 
+%if %{with python2}
 %files
 %defattr(644,root,root,755)
-%dir %{py_sitescriptdir}/webob
-%{py_sitescriptdir}/webob/*.py[co]
-%if "%{py_ver}" > "2.4"
+%doc CHANGES.txt HISTORY.txt README.rst docs/license.txt
+%{py_sitescriptdir}/webob
 %{py_sitescriptdir}/WebOb-%{version}-py*.egg-info
 %endif
 
 %if %{with python3}
 %files -n python3-%{module}
 %defattr(644,root,root,755)
-%dir %{py3_sitescriptdir}/webob
-%{py3_sitescriptdir}/webob/*.py
-%{py3_sitescriptdir}/webob/__pycache__
+%doc CHANGES.txt HISTORY.txt README.rst docs/license.txt
+%{py3_sitescriptdir}/webob
 %{py3_sitescriptdir}/WebOb-%{version}-py*.egg-info
 %endif
+
+%if %{with doc}
+%files apidocs
+%defattr(644,root,root,755)
+%doc docs/_build/html/{_static,api,experimental,*.html,*.js}
+%endif
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/python-WebOb.git/commitdiff/8fa0503048fcd0d38898106ebb45a0af2f6411ed



More information about the pld-cvs-commit mailing list