]> git.pld-linux.org Git - packages/python-flask-debugtoolbar.git/blame - python-flask-debugtoolbar.spec
rebuild with tests and docs
[packages/python-flask-debugtoolbar.git] / python-flask-debugtoolbar.spec
CommitLineData
b426a247
MK
1#
2# Conditional build:
3%bcond_with doc # don't build doc (not provided by package)
4%bcond_without tests # do not perform "make test"
5%bcond_without python2 # CPython 2.x module
6%bcond_without python3 # CPython 3.x module
7
8%define module flask-debugtoolbar
9Summary: A port of the Django debug toolbar to Flask
10Summary(pl.UTF-8): Odpowiednik Djangowego debuggera dla Flask
11Name: python-%{module}
12Version: 0.9.0
007d1f26 13Release: 9
b426a247
MK
14License: BSD
15Group: Libraries/Python
16Source0: https://pypi.python.org/packages/source/F/Flask-DebugToolbar/Flask-DebugToolbar-%{version}.tar.gz
17# Source0-md5: b471c8320d9a04ffea3abda020570563
18URL: http://flask-debugtoolbar.rtfd.org/
19BuildRequires: rpm-pythonprov
20# if py_postclean is used
e46516f5 21BuildRequires: rpmbuild(macros) >= 1.710
b426a247
MK
22%if %{with python2}
23BuildRequires: python-blinker
24BuildRequires: python-distribute
25%endif
26%if %{with python3}
27BuildRequires: python3-blinker
b426a247
MK
28BuildRequires: python3-modules
29%endif
30# Below Rs only work for main package (python2)
31#Requires: python-libs
32Requires: python-modules
220a8c3a 33Requires: python-devel-tools
b426a247
MK
34BuildArch: noarch
35BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
36
37%description
38A port of the Django debug toolbar to Flask
39
40## %description -l pl.UTF-8
41
42%package -n python3-%{module}
43Summary: -
44Summary(pl.UTF-8): -
45Group: Libraries/Python
46Requires: python3-modules
220a8c3a 47Requires: python3-devel-tools
b426a247
MK
48
49%description -n python3-%{module}
50A port of the Django debug toolbar to Flask
51
52## %description -n python3-%{module} -l pl.UTF-8
53
54%package apidocs
55Summary: %{module} API documentation
56Summary(pl.UTF-8): Dokumentacja API %{module}
57Group: Documentation
58
59%description apidocs
60API documentation for %{module}.
61
62%description apidocs -l pl.UTF-8
63Dokumentacja API %{module}.
64
65%prep
66%setup -q -n Flask-DebugToolbar-%{version}
67
68%build
69%if %{with python2}
355fef36 70%py_build %{?with_tests:test}
b426a247
MK
71%endif
72
73%if %{with python3}
355fef36 74%py3_build %{?with_tests:test}
b426a247
MK
75%endif
76
77%if %{with doc}
78cd docs
79%{__make} -j1 html
80rm -rf _build/html/_sources
81%endif
82
83%install
84rm -rf $RPM_BUILD_ROOT
85
86%if %{with python2}
355fef36 87%py_install
b426a247
MK
88
89%py_postclean
90%endif
91
92%if %{with python3}
355fef36 93%py3_install
b426a247
MK
94%endif
95
96%clean
97rm -rf $RPM_BUILD_ROOT
98
99%if %{with python2}
100%files
101%defattr(644,root,root,755)
102%{py_sitescriptdir}/flask_debugtoolbar
103%if "%{py_ver}" > "2.4"
104%{py_sitescriptdir}/Flask_DebugToolbar-%{version}-py*.egg-info
105%endif
106%endif
107
108%if %{with python3}
109%files -n python3-%{module}
110%defattr(644,root,root,755)
111%{py3_sitescriptdir}/flask_debugtoolbar
112%{py3_sitescriptdir}/Flask_DebugToolbar-%{version}-py*.egg-info
113%endif
114
115%if %{with doc}
116%files apidocs
117%defattr(644,root,root,755)
118%doc docs/_build/html/*
119%endif
This page took 0.112635 seconds and 4 git commands to generate.