%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")} %global bname sh Name: python-%{bname} Version: 1.08 Release: 1%{?dist} Summary: Python subprocess interface License: MIT URL: https://github.com/amoffat/sh # Correct url to download is actually # https://github.com/amoffat/sh/archive/%{version}.zip Source0: https://github.com/amoffat/sh/archive/%{bname}-%{version}.zip BuildArch: noarch BuildRequires: python-devel %description sh (previously pbs) is a full-fledged subprocess interface for Python 2.6 - 3.2 that allows you to call any program as if it were a function. sh is not a collection of system commands implemented in Python. Documentation can be found at http://amoffat.github.com/sh. %prep %setup -q -n %{bname}-%{version} %build %{__python} setup.py build %install rm -rf $RPM_BUILD_ROOT %{__python} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT %files %doc AUTHORS.md CHANGELOG.md LICENSE.txt README.md %{python_sitelib}/* %changelog * Wed Apr 10 2013 Xavier Lamien - 1.08-1 - Initial RPM release.