]>
Commit | Line | Data |
---|---|---|
e01687ac JK |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without tests # do not perform "make test" | |
4 | ||
5 | %define pypi_name backports.functools_lru_cache | |
6 | ||
7 | Summary: Backport of functools.lru_cache from Python 3.3 | |
8 | Name: python-%{pypi_name} | |
9 | Version: 1.4 | |
10 | Release: 1 | |
11 | License: MIT | |
12 | Group: Libraries/Python | |
13 | Source0: https://files.pythonhosted.org/packages/source/b/%{pypi_name}/%{pypi_name}-%{version}.tar.gz | |
14 | # Source0-md5: b954e7d5e2ca0f0f66ad2ed12ba800e5 | |
15 | URL: https://github.com/jaraco/backports.functools_lru_cache | |
16 | BuildRequires: python-setuptools | |
17 | BuildRequires: rpm-pythonprov | |
18 | BuildRequires: rpmbuild(macros) >= 1.714 | |
19 | Requires: python-backports | |
20 | BuildArch: noarch | |
21 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
22 | ||
23 | %description | |
24 | Backport of functools.lru_cache from Python 3.3. | |
25 | ||
26 | %prep | |
27 | %setup -q -n %{pypi_name}-%{version} | |
28 | ||
29 | %build | |
30 | %py_build %{?with_tests:test} | |
31 | ||
32 | %install | |
33 | rm -rf $RPM_BUILD_ROOT | |
34 | ||
35 | %py_install | |
36 | ||
37 | %py_postclean | |
38 | ||
39 | rm $RPM_BUILD_ROOT%{py_sitescriptdir}/backports/__init__.* | |
40 | ||
41 | %clean | |
42 | rm -rf $RPM_BUILD_ROOT | |
43 | ||
44 | %files | |
45 | %defattr(644,root,root,755) | |
46 | %doc CHANGES.rst README.rst | |
47 | %{py_sitescriptdir}/backports/functools_lru_cache.py[co] | |
48 | %{py_sitescriptdir}/%{pypi_name}-%{version}-py*.egg-info |