%{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")} %define module feedcache Name: python-feedcache Version: 1.3 Release: 2%{?dist} Summary: Wrapper for Mark Pilgrim's FeedParser module which caches feed content Group: Development/Languages License: MIT URL: http://www.doughellmann.com/projects/feedcache/ Source0: http://www.doughellmann.com/downloads/%{module}-%{version}.tar.gz BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch BuildRequires: python-devel BuildRequires: python-setuptools-devel Requires: python-feedparser %description A class to wrap Mark Pilgrim's FeedParser module so that parameters can be used to cache the feed results locally instead of fetching the feed every time it is requested. Uses both etag and modified times for caching. The cache is parameterized to use different backend storage options. %prep %setup -q -n %{module}-%{version} # Remove unnecessary shebangs to make rpmlint happy for file in cachestoragelock __init__ test_cachestoragelock test_cache cache test_server example example_threads test_shovefilesystem ; do %{__sed} -i.orig -e 1d feedcache/${file}.py touch -r feedcache/${file}.py.orig feedcache/${file}.py %{__rm} feedcache/${file}.py.orig done %build %{__python} setup.py build %install rm -rf %{buildroot} %{__python} setup.py install --skip-build --root %{buildroot} %clean rm -rf %{buildroot} %files %defattr(-,root,root,-) %doc LICENSE.txt README.txt %{python_sitelib}/* %changelog * Mon Nov 17 2008 Luke Macken 1.3-2 - Remove script shebangs to make rpmlint happy * Tue Sep 16 2008 Luke Macken 1.3-1 - Initial package for Fedora