[packages/python-cachetools] Initial version 0.6.0.
matkor
matkor at pld-linux.org
Fri Oct 31 12:36:01 CET 2014
commit 19ecff7c258acded4dff214c89f59d3e4a95740f
Author: Mateusz Korniak <matkor at pld-linux.org>
Date: Fri Oct 31 12:35:45 2014 +0100
Initial version 0.6.0.
python-cachetools.spec | 132 +++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 132 insertions(+)
---
diff --git a/python-cachetools.spec b/python-cachetools.spec
new file mode 100644
index 0000000..4136ebb
--- /dev/null
+++ b/python-cachetools.spec
@@ -0,0 +1,132 @@
+#
+# Conditional build:
+%bcond_with doc # don't build doc (not provided by package)
+%bcond_without tests # do not perform "make test"
+%bcond_without python2 # CPython 2.x module
+%bcond_without python3 # CPython 3.x module
+
+%define module cachetools
+Summary: Various cache implementations based on different cache algorithms
+Summary(pl.UTF-8): Rózne implementacje cache bazujące na róznych algorytmach
+# Name must match the python module/package name (as in 'import' statement)
+Name: python-%{module}
+Version: 0.6.0
+Release: 1
+License: MIT
+Group: Libraries/Python
+
+Source0: https://pypi.python.org/packages/source/c/%{module}/%{module}-%{version}.tar.gz
+# Source0-md5: 45522c095523ab09af859c9fd54643c2
+URL: https://github.com/tkem/cachetools
+BuildRequires: rpm-pythonprov
+# if py_postclean is used
+BuildRequires: rpmbuild(macros) >= 1.219
+%if %{with python2}
+BuildRequires: python-distribute
+%endif
+%if %{with python3}
+BuildRequires: python3-distribute
+BuildRequires: python3-modules
+%endif
+Requires: python-modules
+BuildArch: noarch
+BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%description
+This module provides various cache implementations based on different cache algorithms,
+as well as decorators for easily memoizing function and method calls.
+
+%description -l pl.UTF-8
+Moduł dostarcza rózne implementacje cache'u bazujące na róznych algorytmach, jak również
+dektoratory do łatwego zapamiętywania wyników funcji i metod.
+
+%package -n python3-%{module}
+Summary: Various cache implementations based on different cache algorithms
+Summary(pl.UTF-8): Rózne implementacje cache bazujące na róznych algorytmach
+Group: Libraries/Python
+Requires: python3-modules
+
+%description -n python3-%{module}
+This module provides various cache implementations based on different cache algorithms,
+as well as decorators for easily memoizing function and method calls.
+
+%description -n python3-%{module} -l pl.UTF-8
+Moduł dostarcza rózne implementacje cache'u bazujące na róznych algorytmach, jak również
+dektoratory do łatwego zapamiętywania wyników funcji i metod.
+
+%package apidocs
+Summary: %{module} API documentation
+Summary(pl.UTF-8): Dokumentacja API %{module}
+Group: Documentation
+
+%description apidocs
+API documentation for %{module}.
+
+%description apidocs -l pl.UTF-8
+Dokumentacja API %{module}.
+
+%prep
+%setup -q -n %{module}-%{version}
+
+%build
+%if %{with python2}
+%{__python} setup.py build --build-base build-2 %{?with_tests:test}
+%endif
+
+%if %{with python3}
+%{__python3} setup.py build --build-base build-3 %{?with_tests:test}
+%endif
+
+%if %{with doc}
+cd docs
+%{__make} -j1 html
+rm -rf _build/html/_sources
+%endif
+
+%install
+rm -rf $RPM_BUILD_ROOT
+
+%if %{with python2}
+%{__python} setup.py \
+ build --build-base build-2 \
+ install --skip-build \
+ --optimize=2 \
+ --root=$RPM_BUILD_ROOT
+
+%py_postclean
+%endif
+
+%if %{with python3}
+%{__python3} setup.py \
+ build --build-base build-3 \
+ install --skip-build \
+ --optimize=2 \
+ --root=$RPM_BUILD_ROOT
+%endif
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%if %{with python2}
+%files
+%defattr(644,root,root,755)
+%doc Changes LICENSE README.rst
+%{py_sitescriptdir}/%{module}
+%if "%{py_ver}" > "2.4"
+%{py_sitescriptdir}/%{module}-%{version}-py*.egg-info
+%endif
+%endif
+
+%if %{with python3}
+%files -n python3-%{module}
+%defattr(644,root,root,755)
+%doc Changes LICENSE README.rst
+%{py3_sitescriptdir}/%{module}
+%{py3_sitescriptdir}/%{module}-%{version}-py*.egg-info
+%endif
+
+%if %{with doc}
+%files apidocs
+%defattr(644,root,root,755)
+%doc docs/_build/html/*
+%endif
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/python-cachetools.git/commitdiff/19ecff7c258acded4dff214c89f59d3e4a95740f
More information about the pld-cvs-commit
mailing list