[packages/python-tornado] - updated to 5.1, added -apidocs

qboosh qboosh at pld-linux.org
Sun Jul 22 17:21:16 CEST 2018


commit 6e17dca3e14720a580ac1ce2293381eff692e5de
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Sun Jul 22 17:23:12 2018 +0200

    - updated to 5.1, added -apidocs

 python-tornado.spec | 51 +++++++++++++++++++++++++++++++++++++++------------
 1 file changed, 39 insertions(+), 12 deletions(-)
---
diff --git a/python-tornado.spec b/python-tornado.spec
index 78a6dfa..28bd761 100644
--- a/python-tornado.spec
+++ b/python-tornado.spec
@@ -1,5 +1,6 @@
 #
 # Conditional build:
+%bcond_without	doc	# Sphinx documentation
 %bcond_with	tests	# tornado tests [use network]
 %bcond_without	python2 # CPython 2.x module
 %bcond_without	python3 # CPython 3.x module
@@ -8,21 +9,21 @@
 Summary:	Web framework and asynchronous networking library
 Summary(pl.UTF-8):	Szkielet WWW i asynchroniczna biblioteka sieciowa
 Name:		python-%{module}
-Version:	4.4.2
-Release:	2
+Version:	5.1
+Release:	1
 License:	Apache v2.0
 Group:		Libraries/Python
 #Source0Download: https://pypi.python.org/simple/tornado/
-#Source0:	https://files.pythonhosted.org/packages/source/t/tornado/%{module}-%{version}.tar.gz
-Source0:	https://github.com/tornadoweb/tornado/archive/v%{version}.tar.gz
-# Source0-md5:	cecd70dc9a8ad91dd4986bee01e00aa3
+Source0:	https://files.pythonhosted.org/packages/source/t/tornado/%{module}-%{version}.tar.gz
+# Source0-md5:	bd264851c409f926d1dae1ad5055d28d
+#Source0:	https://github.com/tornadoweb/tornado/archive/v%{version}.tar.gz
 URL:		http://www.tornadoweb.org/
 BuildRequires:	rpm-pythonprov
-BuildRequires:	rpmbuild(macros) >= 1.710
+BuildRequires:	rpmbuild(macros) >= 1.714
 BuildRequires:	sed >= 4.0
 %if %{with python2}
-BuildRequires:	python-devel >= 1:2.6
-BuildRequires:	python-modules >= 1:2.6
+BuildRequires:	python-devel >= 1:2.7
+BuildRequires:	python-modules >= 1:2.7
 BuildRequires:	python-setuptools
 %if %{with tests}
 BuildRequires:	python-backports-ssl_match_hostname
@@ -34,8 +35,8 @@ BuildRequires:	uname(release) >= 3.9
 %endif
 %endif
 %if %{with python3}
-BuildRequires:	python3-devel >= 1:3.2
-BuildRequires:	python3-modules >= 1:3.2
+BuildRequires:	python3-devel >= 1:3.4
+BuildRequires:	python3-modules >= 1:3.4
 BuildRequires:	python3-setuptools
 %if %{with tests}
 %if "%{py3_ver}" < "3.5"
@@ -48,7 +49,10 @@ BuildRequires:	python3-singledispatch
 BuildRequires:	uname(release) >= 3.9
 %endif
 %endif
-Requires:	python-modules >= 1:2.6
+%if %{with doc}
+BuildRequires:	sphinx-pdg
+%endif
+Requires:	python-modules >= 1:2.7
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %description
@@ -70,7 +74,7 @@ długotrwałego połączenia z każdym użytkownikiem.
 Summary:	Web framework and asynchronous networking library
 Summary(pl.UTF-8):	Szkielet WWW i asynchroniczna biblioteka sieciowa
 Group:		Libraries/Python
-Requires:	python3-modules >= 1:3.2
+Requires:	python3-modules >= 1:3.4
 
 %description -n python3-tornado
 Tornado is a Python web framework and asynchronous networking library,
@@ -87,6 +91,17 @@ dziesiątek tysięcy otwartych połączeń, co czyni go idealnym do
 zastosowań z długim pobieraniem, WebSockets i innych wymagających
 długotrwałego połączenia z każdym użytkownikiem.
 
+%package apidocs
+Summary:	API documentation for Python tornado module
+Summary(pl.UTF-8):	Dokumentacja API modułu Pythona tornado
+Group:		Documentation
+
+%description apidocs
+API documentation for Python tornado module.
+
+%description apidocs -l pl.UTF-8
+Dokumentacja API modułu Pythona tornado.
+
 %prep
 %setup -q -n %{module}-%{version}
 
@@ -116,6 +131,12 @@ cd ../..
 %endif
 %endif
 
+%if %{with doc}
+# drop -W from sphinx options to allow build without optional imports (e.g. twisted)
+%{__make} -C docs sphinx \
+	SPHINXOPTS="-n -d build/doctrees ."
+%endif
+
 %install
 rm -rf $RPM_BUILD_ROOT
 
@@ -160,3 +181,9 @@ rm -rf $RPM_BUILD_ROOT
 %{py3_sitedir}/tornado/__pycache__
 %{py3_sitedir}/tornado-%{version}-py*.egg-info
 %endif
+
+%if %{with doc}
+%files apidocs
+%defattr(644,root,root,755)
+%doc docs/build/html/*
+%endif
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/python-tornado.git/commitdiff/6e17dca3e14720a580ac1ce2293381eff692e5de



More information about the pld-cvs-commit mailing list