# sitelib for noarch packages, sitearch for others (remove the unneeded one) %{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")} Name: python-morph Version: 0.89 Release: 1%{?dist} Summary: Image Morphology Toolbox Group: Development/Languages License: BSD URL: http://luispedro.org/pymorph/ Source0: http://luispedro.org/files/pymorph-%{version}.tar.gz BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch BuildRequires: python-devel, python-setuptools Requires: numpy %description The image morphology toolbox implements the basic binary and grayscale morphology operations, working with numpy arrays to hold image data. %prep %setup -q -n pymorph-%{version} %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 # For noarch packages: sitelib %{python_sitelib}/* %changelog * Fri Aug 15 2008 Kushal Das 0.89-1 - Initial release