From 5eeb4ed7caba69141f2c40dc658b5a26eb4cb6b2 Mon Sep 17 00:00:00 2001 From: Haikel Guemar Date: Jan 15 2016 20:28:23 +0000 Subject: Initial package. --- diff --git a/.gitignore b/.gitignore index e69de29..1e3c66c 100644 --- a/.gitignore +++ b/.gitignore @@ -0,0 +1 @@ +/django-redis-4.3.0.tar.gz diff --git a/python-django-redis.spec b/python-django-redis.spec new file mode 100644 index 0000000..e306bc2 --- /dev/null +++ b/python-django-redis.spec @@ -0,0 +1,85 @@ +%global pypi_name django-redis +%global modname django_redis +%if 0%{?fedora} +%global with_python3 1 +%endif + +Name: python-%{pypi_name} +Version: 4.3.0 +Release: 1%{?dist} +Summary: Full featured redis cache backend for Django + +License: BSD +URL: https://github.com/niwibe/django-redis +Source0: https://pypi.python.org/packages/source/d/%{pypi_name}/%{pypi_name}-%{version}.tar.gz +BuildArch: noarch + +%description +Full featured redis cache backend for Django. + + +%package -n python2-%{pypi_name} +Summary: Full featured redis cache backend for Django +%{?python_provide:%python_provide python2-%{pypi_name}} + +BuildRequires: python2-devel +BuildRequires: python-setuptools +BuildRequires: python-django +Requires: python-django +Requires: python-redis >= 2.10.0 + +%description -n python2-%{pypi_name} +Full featured redis cache backend for Django. + +%if 0%{?with_python3} +%package -n python3-%{pypi_name} +Summary: Full featured redis cache backend for Django +%{?python_provide:%python_provide python3-%{pypi_name}} + +BuildRequires: python3-devel +BuildRequires: python3-setuptools +BuildRequires: python3-django +Requires: python3-django +Requires: python3-redis >= 2.10.0 + +%description -n python3-%{pypi_name} +Full featured redis cache backend for Django. +%endif + +%prep +%autosetup -n %{pypi_name}-%{version} +# Remove bundled egg-info +rm -rf %{pypi_name}.egg-info + +%build +%py2_build +%if 0%{?with_python3} +%py3_build +%endif + +%install +# Must do the subpackages' install first because the scripts in /usr/bin are +# overwritten with every setup.py install. +%if 0%{?with_python3} +%py3_install +%endif + +%py2_install + +%files -n python2-%{pypi_name} +%doc README.rst +%license LICENSE +%{python2_sitelib}/%{modname} +%{python2_sitelib}/django_redis-%{version}-py?.?.egg-info + +%if 0%{?with_python3} +%files -n python3-%{pypi_name} +%doc README.rst +%license LICENSE +%{python3_sitelib}/%{modname} +%{python3_sitelib}/django_redis-%{version}-py?.?.egg-info +%endif + +%changelog +* Thu Jan 14 2016 Haïkel Guémar - 4.3.0-1 +- Initial package. diff --git a/sources b/sources index e69de29..c027c93 100644 --- a/sources +++ b/sources @@ -0,0 +1 @@ +271fc8f34da4bc1ca1257b2574207aec django-redis-4.3.0.tar.gz