]> git.pld-linux.org Git - packages/python-flask-debugtoolbar-lineprofilerpanel.git/blame - python-flask-debugtoolbar-lineprofilerpanel.spec
- drop python3-distribute deps
[packages/python-flask-debugtoolbar-lineprofilerpanel.git] / python-flask-debugtoolbar-lineprofilerpanel.spec
CommitLineData
3b3eae2e
MK
1#
2# Conditional build:
3%bcond_with doc # don't build doc (not povided 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## TODO: consider rename to flask_debugtoolbar_lineprofilerpanel ?
8%define module flask-debugtoolbar-lineprofilerpanel
9Summary: Panel for the Flask Debug toolbar to capture and view line-by-line profiling stats
10Summary(pl.UTF-8): Pandel do Flask Debug toolbar do analizy statystyk wykonania kodu linia po linii
11Name: python-%{module}
12Version: 1.0.2
c8f8ec26 13Release: 8
3b3eae2e
MK
14License: MIT
15Group: Libraries/Python
16Source0: https://pypi.python.org/packages/source/F/Flask-DebugToolbar-LineProfilerPanel/Flask-DebugToolbar-LineProfilerPanel-%{version}.tar.gz
17# Source0-md5: 005d47cb98cff464ce9042b9bf66c230
18URL: https://github.com/phleet/flask_debugtoolbar_lineprofilerpanel
5bb99452 19BuildRequires: rpmbuild(macros) >= 1.710
3b3eae2e
MK
20BuildRequires: rpm-pythonprov
21%if %{with python2}
22BuildRequires: python-distribute
23BuildRequires: python-flask-debugtoolbar
24BuildRequires: python-line_profiler
25
26%endif
27%if %{with python3}
3b3eae2e
MK
28BuildRequires: python3-flask-debugtoolbar
29BuildRequires: python3-line_profiler
30BuildRequires: python3-modules
31
32%endif
33# Below Rs only work for main package (python2)
34#Requires: python-libs
35Requires: python-modules
36BuildArch: noarch
37BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
38
39%description
40Panel for flask_debugtoolbar which enables the ability to view line
41profiling information from selected functions. The line profile
42information comes from the line_profiler module.
43
44%description -l pl.UTF-8
45Panel dla flask_debugtoolbar który pozwala zobaczyć i zanalizować
46czasy wykonania linii wybranych funkcji. Informacje są pobierane z
47modułu line_profiler.
48
49%package -n python3-%{module}
50Summary: Panel for the Flask Debug toolbar to capture and view line-by-line profiling stats
51Summary(pl.UTF-8): Pandel do Flask Debug toolbar do analizy statystyk wykonania kodu linia po linii
52Group: Libraries/Python
53Requires: python3-modules
54
55%description -n python3-%{module}
56Panel for flask_debugtoolbar which enables the ability to view line
57profiling information from selected functions. The line profile
58information comes from the line_profiler module.
59
60%description -n python3-%{module} -l pl.UTF-8
61Panel dla flask_debugtoolbar który pozwala zobaczyć i zanalizować
62czasy wykonania linii wybranych funkcji. Informacje są pobierane z
63modułu line_profiler.
64
65%package apidocs
66Summary: %{module} API documentation
67Summary(pl.UTF-8): Dokumentacja API %{module}
68Group: Documentation
69
70%description apidocs
71API documentation for %{module}.
72
73%description apidocs -l pl.UTF-8
74Dokumentacja API %{module}.
75
76%prep
77%setup -q -n Flask-DebugToolbar-LineProfilerPanel-%{version}
35b83c75
MK
78# Until fixed upstream:
79sed -i 's/line-profiler>=1.0b3/line_profiler>=1.0/g' setup.py
3b3eae2e
MK
80
81%build
82%if %{with python2}
fdb515e7 83%py_build %{?with_tests:test}
3b3eae2e
MK
84%endif
85
86%if %{with python3}
fdb515e7 87%py3_build %{?with_tests:test}
3b3eae2e
MK
88%endif
89
90%if %{with doc}
91cd docs
92%{__make} -j1 html
93rm -rf _build/html/_sources
94%endif
95
96%install
97rm -rf $RPM_BUILD_ROOT
98
99%if %{with python2}
fdb515e7 100%py_install
3b3eae2e
MK
101
102%py_postclean
103%endif
104
105%if %{with python3}
fdb515e7 106%py3_install
3b3eae2e
MK
107%endif
108
109%clean
110rm -rf $RPM_BUILD_ROOT
111
112%if %{with python2}
113%files
114%defattr(644,root,root,755)
115%{py_sitescriptdir}/flask_debugtoolbar_lineprofilerpanel
116%if "%{py_ver}" > "2.4"
117%{py_sitescriptdir}/Flask_DebugToolbar_LineProfilerPanel-%{version}-py*.egg-info
118%endif
119%endif
120
121%if %{with python3}
122%files -n python3-%{module}
123%defattr(644,root,root,755)
124%{py3_sitescriptdir}/flask_debugtoolbar_lineprofilerpanel
125%{py3_sitescriptdir}/Flask_DebugToolbar_LineProfilerPanel-%{version}-py*.egg-info
126%endif
127
128%if %{with doc}
129%files apidocs
130%defattr(644,root,root,755)
131%doc docs/_build/html/*
132%endif
This page took 0.060855 seconds and 4 git commands to generate.