%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")} %global tarball_name pycontrol Name: python-icontrol Version: 2.1 Release: 1%{?dist} Summary: Library for F5 iControl API Group: Development/Languages License: GPLv2 URL: https://github.com/mcauthorn/pycontrol Source0: http://pypi.python.org/packages/source/p/pycontrol/%{tarball_name}-%{version}.tar.gz BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch BuildRequires: python-setuptools Requires: python-suds %description pyControl is a Python-based library that integrates with F5's BIG-IP iControl management API. %prep %setup -qn %{tarball_name}-%{version} %build %{__python} setup.py build %install rm -rf %{buildroot} %{__python} setup.py install -O1 --skip-build --root %{buildroot} %clean rm -rf %{buildroot} %files %defattr(-,root,root,-) %doc README %{python_sitelib}/* %changelog * Wed Aug 13 2014 Daniel Bruno - 2.1-1 - First RPM build for python-icontrol