%{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")} Summary: LZO bindings for Python Name: python-lzo Version: 1.08 Release: 2%{?dist} Source0: http://www.oberhumer.com/opensource/lzo/download/LZO-v1/%{name}-%{version}.tar.gz URL: http://www.oberhumer.com/opensource/lzo/ Patch0: python-lzo-1.08-build-against-lzo2.patch License: GPLv2+ Group: Development/Languages BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: python-setuptools BuildRequires: python-devel BuildRequires: lzo-devel %description Python-LZO provides Python bindings for the LZO data compression library. %prep %setup -q %patch0 -p1 -b .lzo2 %build %if 0%{?fedora} > 8 CFLAGS="$RPM_OPT_FLAGS" %{__python} setup.py build %else CFLAGS="$RPM_OPT_FLAGS" %{__python} -c 'import setuptools; execfile("setup.py")' build %endif %install rm -rf $RPM_BUILD_ROOT %if 0%{?fedora} > 8 %{__python} setup.py install -O1 --skip-build --root %{buildroot} %else %{__python} -c 'import setuptools; execfile("setup.py")' install -O1 --skip-build --root %{buildroot} %endif %clean rm -rf $RPM_BUILD_ROOT %files %doc COPYING NEWS README %defattr(-,root,root,-) %{python_sitelib}/* %changelog * Fri Apr 4 2008 Huzaifa Sidhpurwala - 1.08-2 - Made changes so that it builds on f9 - A couple of other changes to spec file to make it more complaint with pkg standards * Thu Apr 3 2008 Huzaifa Sidhpurwala - 1.08-1 - Initial rebuild from Mandriva (Per Øyvind Karlsen )