%global pypi_name django-keyedcache %global srcversion 1.4-6 %global obs_ver 1.4.1-5 Name: python-%{pypi_name} Version: 1.4.6 Release: 3%{?dist} Summary: Utilities for simplified development of cache aware objects Group: Development/Languages License: BSD URL: http://pypi.python.org/pypi/%{pypi_name} Source0: http://pypi.python.org/packages/source/d/%{pypi_name}/%{pypi_name}-%{srcversion}.tar.gz BuildArch: noarch BuildRequires: python-setuptools-devel BuildRequires: python-devel BuildRequires: python-django BuildRequires: gettext Requires: python-django Provides: django-keyedcache = %{version}-%{release} Obsoletes: django-keyedcache < %{obs_ver} %description Django Keyedcache provides utilities and class mixins for simplified development of cache-aware objects. Used in Satchmo %prep %setup -q -n %{pypi_name}-%{srcversion} rm -rf tests %build %{__python} setup.py build %install rm -rf $RPM_BUILD_ROOT %{__python} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT %find_lang django # remove unneeded .po files pushd $RPM_BUILD_ROOT find -type f -name '*.po' -exec rm {} \; popd %check pushd keyedcache/test_app # remove unneded 'livesettings' app sed -i "/'livesettings'/d" settings.py PYTHONPATH=../.. python manage.py test keyedcache popd %files -f django.lang %doc PKG-INFO %dir %{python_sitelib}/keyedcache/ %{python_sitelib}/keyedcache/*.py* # own all the locale directories %dir %{python_sitelib}/keyedcache/locale/ %dir %{python_sitelib}/keyedcache/locale/*/ %dir %{python_sitelib}/keyedcache/locale/*/*/ %{python_sitelib}/keyedcache/templates/ %exclude %{python_sitelib}/keyedcache/test_app %{python_sitelib}/django_keyedcache*.egg-info %changelog * Tue Aug 14 2012 Bohuslav Kabrda - 1.4.6-3 - Add proper Provides and Obsoletes tags. * Tue Aug 14 2012 Bohuslav Kabrda - 1.4.6-2 - Fixed the package's locale directory ownership issue. * Mon Aug 13 2012 Bohuslav Kabrda - 1.4.6-1 - Renamed to python-django-keyedcache. - Updated to latest upstream release. - Fixed URL to point to upstream, not to PyPI. - Introduced %%check section. - Improved lang files handling. * Wed Jul 18 2012 Fedora Release Engineering - 1.4.1-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild * Fri Jan 13 2012 Fedora Release Engineering - 1.4.1-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild * Sat Jun 09 2011 Rahul Sundaram - 1.4.1-2 - Fix a build issue * Thu Apr 14 2011 Rahul Sundaram - 1.4.1-1 - initial spec