]> git.pld-linux.org Git - packages/python-progress.git/blob - python-progress.spec
rebuild with tests and docs
[packages/python-progress.git] / python-progress.spec
1 # Conditional build:
2 %bcond_without  tests   # do not perform "make test"
3 %bcond_without  python2 # CPython 2.x module
4 %bcond_without  python3 # CPython 3.x module
5
6 %define         module          progress
7 %define         egg_name        progress
8 %define         pypi_name       progress
9 Summary:        Easy to use progress bars
10 Name:           python-%{pypi_name}
11 Version:        1.3
12 Release:        7
13 License:        ISC
14 Group:          Libraries/Python
15 Source0:        https://github.com/verigak/progress/archive/%{version}.tar.gz
16 # Source0-md5:  236c376f2c125428633ebf3fd3321471
17 URL:            https://pypi.python.org/pypi/progress
18 BuildRequires:  rpm-pythonprov
19 BuildRequires:  rpmbuild(macros) >= 1.714
20 %if %{with python2}
21 BuildRequires:  python-modules
22 BuildRequires:  python-setuptools
23 %endif
24 %if %{with python3}
25 BuildRequires:  python3-modules
26 BuildRequires:  python3-setuptools
27 %endif
28 Requires:       python-modules
29 BuildArch:      noarch
30 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
31
32 %description
33 Easy progress reporting for Python.
34
35 %package -n python3-%{pypi_name}
36 Summary:        Easy to use progress bars
37 Group:          Libraries/Python
38 Requires:       python3-modules
39
40 %description -n python3-%{pypi_name}
41 Easy progress reporting for Python.
42
43 %prep
44 %setup -q -n %{pypi_name}-%{version}
45
46 %build
47 %if %{with python2}
48 %py_build %{?with_tests:test}
49 %endif
50
51 %if %{with python3}
52 %py3_build %{?with_tests:test}
53 %endif
54
55 %install
56 rm -rf $RPM_BUILD_ROOT
57
58 %if %{with python2}
59 %py_install
60 %py_postclean
61 %endif
62
63 %if %{with python3}
64 %py3_install
65 %endif
66
67 %clean
68 rm -rf $RPM_BUILD_ROOT
69
70 %if %{with python2}
71 %files
72 %defattr(644,root,root,755)
73 %doc README.rst
74 %{py_sitescriptdir}/%{module}
75 %{py_sitescriptdir}/%{egg_name}-%{version}-py*.egg-info
76 %endif
77
78 %if %{with python3}
79 %files -n python3-%{pypi_name}
80 %defattr(644,root,root,755)
81 %doc README.rst
82 %{py3_sitescriptdir}/%{module}
83 %{py3_sitescriptdir}/%{egg_name}-%{version}-py*.egg-info
84 %endif
This page took 0.108287 seconds and 3 git commands to generate.