%{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")} %define eggname TGCaptcha Name: python-tgcaptcha Version: 0.11 Release: 2%{?dist} Summary: A TurboGears CAPTCHA widget for forms Group: Development/Libraries License: MIT URL: http://code.google.com/p/tgcaptcha Source0: http://tgcaptcha.googlecode.com/files/%{eggname}-%{version}.tar.gz BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch BuildRequires: python python-devel TurboGears Requires: TurboGears >= 1.0.1 Requires: python-crypto >= 2.0.1 %description TGCaptcha is a TurboGears widget that provides an easy way to incorporate a captcha as part a form in an attempt to reduce spam or malicious activity. %prep %setup -q -n %{eggname}-%{version} chmod -x tgcaptcha/static/fonts/tuffy/* %build %{__python} setup.py build %install rm -rf $RPM_BUILD_ROOT %{__python} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT %clean rm -rf $RPM_BUILD_ROOT %files %defattr(-,root,root,-) %doc README.txt COPYRIGHT.txt %{python_sitelib}/* %changelog * Tue Mar 11 2008 Luke Macken 0.11-2 - Make package noarch - Fix lengthy description - Remove the executable bit from the fonts * Mon Mar 10 2008 Luke Macken 0.11-1 - Initial package