%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")} %global tarball_name rq Name: python-rq Version: 0.4.6 Release: 1%{?dist} Summary: Library for creating background jobs, and processing them. Group: Development/Languages License: BSD URL: http://python-rq.org Source0: http://pypi.python.org/packages/source/a/apache-libcloud/%{tarball_name}-%{version}.tar.gz Source1: LICENSE-pythonrq Source2: README-pythonrq.md BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch Requires: python-redis BuildRequires: python-setuptools BuildRequires: python2-devel %description RQ (Redis Queue) is a simple Python library for queueing jobs and processing them in the background with workers. It is backed by Redis and it is designed to have a low barrier to entry. %prep %setup -qn %{tarball_name}-%{version} %build %{__python} setup.py build %install rm -rf %{buildroot} %{__python} setup.py install -O1 --skip-build --root %{buildroot} /bin/cp %{SOURCE1} ./LICENSE /bin/cp %{SOURCE2} ./README %clean rm -rf %{buildroot} %files %defattr(-,root,root,-) %{_bindir}/rqinfo %{_bindir}/rqworker %doc LICENSE README %{python_sitelib}/* %changelog * Tue Dec 16 2014 Daniel Bruno - 0.4.6-1 - First RPM build