]> git.pld-linux.org Git - packages/python3-werkzeug.git/blob - python-werkzeug.spec
Version 0.11.10.
[packages/python3-werkzeug.git] / python-werkzeug.spec
1 # TODO: rename to  python-werkzeug
2 #
3 # Conditional build:
4 # %bcond_without  doc             # don't build doc
5 %bcond_with  tests   # do not perform "make test"
6 %bcond_without  python2 # CPython 2.x module
7 %bcond_without  python3 # CPython 3.x module
8
9 %define         module  werkzeug
10 Summary:        The Swiss Army knife of Python web development
11 Name:           python-%{module}
12 Version:        0.11.10
13 Release:        1
14 License:        BSD
15 Group:          Development/Languages/Python
16 # Source0:      http://pypi.python.org/packages/source/W/Werkzeug/Werkzeug-%{version}.tar.gz
17 Source0:        https://github.com/pallets/werkzeug/archive/%{version}.tar.gz
18 # Source0-md5:  5010591f97c36722027bd23ade0029e3
19 URL:            http://werkzeug.pocoo.org/
20 %if %{with python2}
21 BuildRequires:  python-distribute
22 BuildRequires:  rpm-pythonprov
23 BuildRequires:  rpmbuild(macros) >= 1.710
24 Requires:       python-modules
25 %endif
26 %if %{with python3}
27 BuildRequires:  python3-devel
28 BuildRequires:  python3-distribute
29 BuildRequires:  python3-modules
30 Requires:       python3-modules
31 %endif
32
33
34 BuildArch:      noarch
35 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
36
37 %description
38 Werkzeug started as simple collection of various utilities for WSGI
39 applications and has become one of the most advanced WSGI utility
40 modules. It includes a powerful debugger, full featured request and
41 response objects, HTTP utilities to handle entity tags, cache control
42 headers, HTTP dates, cookie handling, file uploads, a powerful URL
43 routing system and a bunch of community contributed addon modules.
44
45 %package -n python3-%{module}
46 Summary:        The Swiss Army knife of Python web development
47 Summary(pl.UTF-8):      Zbiór narzędzi dla rozwouju aplikacji sieciowych dla Pythona
48 Group:          Libraries/Python
49
50 %description -n python3-%{module}
51 Werkzeug started as simple collection of various utilities for WSGI
52 applications and has become one of the most advanced WSGI utility
53 modules. It includes a powerful debugger, full featured request and
54 response objects, HTTP utilities to handle entity tags, cache control
55 headers, HTTP dates, cookie handling, file uploads, a powerful URL
56 routing system and a bunch of community contributed addon modules.
57
58 # %description -n python3-%{module} -l pl.UTF-8
59
60 %prep
61 %setup -q -n werkzeug-%{version}
62
63 %build
64 %if %{with python2}
65 %py_build %{?with_tests:test}
66 %endif
67
68 %if %{with python3}
69 %py3_build %{?with_tests:test}
70 %endif
71
72
73 %install
74 rm -rf $RPM_BUILD_ROOT
75
76 %if %{with python2}
77 %py_install
78
79 %py_postclean
80 %endif
81
82 %if %{with python3}
83 %py3_install
84 %endif
85
86 %if %{with python2}
87 install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
88 cp -a examples/* $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
89 %endif
90 %if %{with python3}
91 install -d $RPM_BUILD_ROOT%{_examplesdir}/python3-%{module}-%{version}
92 cp -a examples/* $RPM_BUILD_ROOT%{_examplesdir}/python3-%{module}-%{version}
93 find $RPM_BUILD_ROOT%{_examplesdir}/python3-%{module}-%{version} -name '*.py' \
94         | xargs sed -i '1s|^#!.*python\b|#!%{__python3}|'
95 %endif
96 %py_postclean
97
98 %clean
99 rm -rf $RPM_BUILD_ROOT
100
101 %if %{with python2}
102 %files
103 %defattr(644,root,root,755)
104 %doc AUTHORS CHANGES
105 %{py_sitescriptdir}/werkzeug
106 %if "%{py_ver}" > "2.4"
107 %{py_sitescriptdir}/Werkzeug-%{version}-py*.egg-info
108 %endif
109 %{_examplesdir}/%{name}-%{version}
110 %endif
111
112 %if %{with python3}
113 %files -n python3-%{module}
114 %defattr(644,root,root,755)
115 %doc AUTHORS CHANGES LICENSE
116 %{py3_sitescriptdir}/%{module}
117 %{py3_sitescriptdir}/Werkzeug-%{version}-py*.egg-info
118 %{_examplesdir}/python3-%{module}-%{version}
119 %endif
This page took 0.06025 seconds and 3 git commands to generate.