]> git.pld-linux.org Git - packages/python3-werkzeug.git/blame - python-werkzeug.spec
- updated to 0.11.15
[packages/python3-werkzeug.git] / python-werkzeug.spec
CommitLineData
2f8691a4 1#
7c90b45b
JB
2# Conditional build:
3%bcond_without doc # Sphinx documentation
4%bcond_with tests # test action
5%bcond_without python2 # CPython 2.x module
6%bcond_without python3 # CPython 3.x module
c6a9fbf4 7
b1dbdc2a 8%define module werkzeug
c6a9fbf4 9Summary: The Swiss Army knife of Python web development
7c90b45b 10Summary(pl.UTF-8): Scyzoryk szwajcarski programisty aplikacji WWW
c6a9fbf4 11Name: python-%{module}
7c90b45b
JB
12Version: 0.11.15
13Release: 1
c6a9fbf4 14License: BSD
15Group: Development/Languages/Python
7c90b45b
JB
16# pypi release misses docs/_themes directory
17##Source0Download: https://pypi.python.org/simple/Werkzeug
18#Source0: https://files.pythonhosted.org/packages/source/W/Werkzeug/Werkzeug-%{version}.tar.gz
19#Source0Download: https://github.com/pallets/werkzeug/releases
20Source0: https://github.com/pallets/werkzeug/archive/%{version}/werkzeug-%{version}.tar.gz
21# Source0-md5: 9cb2ba56c694dbd5863ed1b13ce478c2
22Patch0: %{name}-py3.patch
c6a9fbf4 23URL: http://werkzeug.pocoo.org/
9fb4e136 24%if %{with python2}
7c90b45b
JB
25BuildRequires: python-devel >= 1:2.6
26BuildRequires: python-modules >= 1:2.6
27BuildRequires: python-setuptools
9fb4e136
MK
28%endif
29%if %{with python3}
7c90b45b
JB
30BuildRequires: python3-devel >= 1:3.3
31BuildRequires: python3-modules >= 1:3.3
32BuildRequires: python3-setuptools
33%endif
34BuildRequires: rpm-pythonprov
35BuildRequires: rpmbuild(macros) >= 1.714
36%if %{with doc}
37BuildRequires: sphinx-pdg
9fb4e136 38%endif
7c90b45b 39Requires: python-modules >= 1:2.6
c6a9fbf4 40BuildArch: noarch
41BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
42
43%description
44Werkzeug started as simple collection of various utilities for WSGI
45applications and has become one of the most advanced WSGI utility
46modules. It includes a powerful debugger, full featured request and
47response objects, HTTP utilities to handle entity tags, cache control
48headers, HTTP dates, cookie handling, file uploads, a powerful URL
49routing system and a bunch of community contributed addon modules.
50
7c90b45b
JB
51%description -l pl.UTF-8
52Werkzeug początkowo był prostym zbiorem różnych narzędzi dla aplikacji
53WSGI, a stał się jednym z najbardziej zaawansowanych modułów
54narzędziowych WSGI. Zawiera potężny debugger, obiekty żądania i
55odpowiedzi z pełną funkcjonalnością, narzędzia HTTP do obsługi
56znaczników encji, nagłówki sterujące buforowaniem, daty HTTP, obsługę
57ciasteczek, przesyłanie plików, potężny system trasowania URL oraz
58wiele dodatkowych modułów udostępnionych przez społeczność.
59
9fb4e136
MK
60%package -n python3-%{module}
61Summary: The Swiss Army knife of Python web development
7c90b45b 62Summary(pl.UTF-8): Scyzoryk szwajcarski programisty aplikacji WWW
9fb4e136 63Group: Libraries/Python
7c90b45b 64Requires: python3-modules >= 1:3.3
9fb4e136
MK
65
66%description -n python3-%{module}
67Werkzeug started as simple collection of various utilities for WSGI
68applications and has become one of the most advanced WSGI utility
69modules. It includes a powerful debugger, full featured request and
70response objects, HTTP utilities to handle entity tags, cache control
71headers, HTTP dates, cookie handling, file uploads, a powerful URL
72routing system and a bunch of community contributed addon modules.
73
7c90b45b
JB
74%description -n python3-%{module} -l pl.UTF-8
75Werkzeug początkowo był prostym zbiorem różnych narzędzi dla aplikacji
76WSGI, a stał się jednym z najbardziej zaawansowanych modułów
77narzędziowych WSGI. Zawiera potężny debugger, obiekty żądania i
78odpowiedzi z pełną funkcjonalnością, narzędzia HTTP do obsługi
79znaczników encji, nagłówki sterujące buforowaniem, daty HTTP, obsługę
80ciasteczek, przesyłanie plików, potężny system trasowania URL oraz
81wiele dodatkowych modułów udostępnionych przez społeczność.
82
83%package apidocs
84Summary: Documentation for Python Werkzeug package
85Summary(pl.UTF-8): Dokumentacja do pakietu Pythona Werkzeug
86Group: Documentation
87
88%description apidocs
89Documentation for Python Werkzeug package.
90
91%description apidocs -l pl.UTF-8
92Dokumentacja do pakietu Pythona Werkzeug.
93
c6a9fbf4 94%prep
fdb1d6ee 95%setup -q -n werkzeug-%{version}
7c90b45b 96%patch0 -p1
c6a9fbf4 97
98%build
9fb4e136 99%if %{with python2}
5db35e26 100%py_build %{?with_tests:test}
9fb4e136
MK
101%endif
102
103%if %{with python3}
5db35e26 104%py3_build %{?with_tests:test}
9fb4e136 105%endif
c6a9fbf4 106
7c90b45b
JB
107%if %{with doc}
108PYTHONPATH=$(pwd) \
109%{__make} -C docs html
110%endif
111
c6a9fbf4 112%install
113rm -rf $RPM_BUILD_ROOT
9fb4e136 114%if %{with python2}
5db35e26 115%py_install
9fb4e136 116%py_postclean
2f8691a4
ER
117
118install -d $RPM_BUILD_ROOT%{_examplesdir}/python-%{module}-%{version}
119cp -a examples/* $RPM_BUILD_ROOT%{_examplesdir}/python-%{module}-%{version}
120find $RPM_BUILD_ROOT%{_examplesdir}/python-%{module}-%{version} -name '*.py' \
121 | xargs sed -i '1s|^#!.*python\b|#!%{__python}|'
9fb4e136
MK
122%endif
123
124%if %{with python3}
5db35e26 125%py3_install
9fb4e136 126
9fb4e136
MK
127install -d $RPM_BUILD_ROOT%{_examplesdir}/python3-%{module}-%{version}
128cp -a examples/* $RPM_BUILD_ROOT%{_examplesdir}/python3-%{module}-%{version}
129find $RPM_BUILD_ROOT%{_examplesdir}/python3-%{module}-%{version} -name '*.py' \
2f8691a4 130 | xargs sed -i '1s|^#!.*python\b|#!%{__python3}|'
9fb4e136 131%endif
c6a9fbf4 132
133%clean
134rm -rf $RPM_BUILD_ROOT
135
9fb4e136 136%if %{with python2}
c6a9fbf4 137%files
138%defattr(644,root,root,755)
7c90b45b 139%doc AUTHORS CHANGES LICENSE README.rst
c6a9fbf4 140%{py_sitescriptdir}/werkzeug
b1dbdc2a 141%{py_sitescriptdir}/Werkzeug-%{version}-py*.egg-info
2f8691a4 142%{_examplesdir}/python-%{module}-%{version}
9fb4e136
MK
143%endif
144
145%if %{with python3}
146%files -n python3-%{module}
147%defattr(644,root,root,755)
7c90b45b
JB
148%doc AUTHORS CHANGES LICENSE README.rst
149%{py3_sitescriptdir}/werkzeug
b1dbdc2a 150%{py3_sitescriptdir}/Werkzeug-%{version}-py*.egg-info
9fb4e136
MK
151%{_examplesdir}/python3-%{module}-%{version}
152%endif
7c90b45b
JB
153
154%if %{with doc}
155%files apidocs
156%defattr(644,root,root,755)
157%doc docs/_build/html/{_images,_static,contrib,deployment,*.html,*.js}
158%endif
This page took 0.041715 seconds and 4 git commands to generate.