]> git.pld-linux.org Git - packages/python-cachetools.git/blame - python-cachetools.spec
Release 11 (by relup.sh)
[packages/python-cachetools.git] / python-cachetools.spec
CommitLineData
19ecff7c
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 cachetools
9Summary: Various cache implementations based on different cache algorithms
10Summary(pl.UTF-8): Rózne implementacje cache bazujące na róznych algorytmach
11# Name must match the python module/package name (as in 'import' statement)
12Name: python-%{module}
4285a92c 13Version: 0.7.0
97294189 14Release: 11
19ecff7c
MK
15License: MIT
16Group: Libraries/Python
17
18Source0: https://pypi.python.org/packages/source/c/%{module}/%{module}-%{version}.tar.gz
4285a92c 19# Source0-md5: c67ebb099e7607b689f79b2869585d36
19ecff7c
MK
20URL: https://github.com/tkem/cachetools
21BuildRequires: rpm-pythonprov
22# if py_postclean is used
5e22599f 23BuildRequires: rpmbuild(macros) >= 1.710
19ecff7c
MK
24%if %{with python2}
25BuildRequires: python-distribute
26%endif
27%if %{with python3}
19ecff7c
MK
28BuildRequires: python3-modules
29%endif
30Requires: python-modules
31BuildArch: noarch
32BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
33
34%description
35This module provides various cache implementations based on different cache algorithms,
36as well as decorators for easily memoizing function and method calls.
37
38%description -l pl.UTF-8
39Moduł dostarcza rózne implementacje cache'u bazujące na róznych algorytmach, jak również
40dektoratory do łatwego zapamiętywania wyników funcji i metod.
41
42%package -n python3-%{module}
43Summary: Various cache implementations based on different cache algorithms
44Summary(pl.UTF-8): Rózne implementacje cache bazujące na róznych algorytmach
45Group: Libraries/Python
46Requires: python3-modules
47
48%description -n python3-%{module}
49This module provides various cache implementations based on different cache algorithms,
50as well as decorators for easily memoizing function and method calls.
51
52%description -n python3-%{module} -l pl.UTF-8
53Moduł dostarcza rózne implementacje cache'u bazujące na róznych algorytmach, jak również
54dektoratory do łatwego zapamiętywania wyników funcji i metod.
55
56%package apidocs
57Summary: %{module} API documentation
58Summary(pl.UTF-8): Dokumentacja API %{module}
59Group: Documentation
60
61%description apidocs
62API documentation for %{module}.
63
64%description apidocs -l pl.UTF-8
65Dokumentacja API %{module}.
66
67%prep
68%setup -q -n %{module}-%{version}
69
70%build
71%if %{with python2}
3d265895 72%py_build %{?with_tests:test}
19ecff7c
MK
73%endif
74
75%if %{with python3}
3d265895 76%py3_build %{?with_tests:test}
19ecff7c
MK
77%endif
78
79%if %{with doc}
80cd docs
81%{__make} -j1 html
82rm -rf _build/html/_sources
83%endif
84
85%install
86rm -rf $RPM_BUILD_ROOT
87
88%if %{with python2}
3d265895 89%py_install
19ecff7c
MK
90
91%py_postclean
92%endif
93
94%if %{with python3}
3d265895 95%py3_install
19ecff7c
MK
96%endif
97
98%clean
99rm -rf $RPM_BUILD_ROOT
100
101%if %{with python2}
102%files
103%defattr(644,root,root,755)
4285a92c 104%doc LICENSE README.rst
19ecff7c
MK
105%{py_sitescriptdir}/%{module}
106%if "%{py_ver}" > "2.4"
107%{py_sitescriptdir}/%{module}-%{version}-py*.egg-info
108%endif
109%endif
110
111%if %{with python3}
112%files -n python3-%{module}
113%defattr(644,root,root,755)
4285a92c 114%doc LICENSE README.rst
19ecff7c
MK
115%{py3_sitescriptdir}/%{module}
116%{py3_sitescriptdir}/%{module}-%{version}-py*.egg-info
117%endif
118
119%if %{with doc}
120%files apidocs
121%defattr(644,root,root,755)
122%doc docs/_build/html/*
123%endif
This page took 0.500833 seconds and 4 git commands to generate.