%global pypi_name abclient %global common_desc \ Abclient is a python library for EISOO AnyBackup APIs. It is a client \ library for EISOO AnyBackup APIs. It allows openstack karbor to \ create backups for databases and file systems. %if 0%{?fedora} %global with_python3 0 %endif Name: python-%{pypi_name} Version: 0.2.3 Release: 4%{?dist} Summary: Python client library for EISOO AnyBackup API License: ASL 2.0 URL: https://pypi.python.org/pypi/abclient Source0: https://files.pythonhosted.org/packages/source/a/%{pypi_name}/%{pypi_name}-%{version}.tar.gz BuildArch: noarch %description %{common_desc} %package -n python2-%{pypi_name} Summary: Python client library for EISOO AnyBackup API %{?python_provide:%python_provide python2-%{pypi_name}} BuildRequires: python2-devel BuildRequires: python-setuptools Requires: python-requests Requires: python-oslo-utils Requires: python-oslo-log %description -n python2-%{pypi_name} %{common_desc} %if 0%{?with_python3} %package -n python3-%{pypi_name} Summary: Python client library for EISOO AnyBackup API %{?python_provide:%python_provide python3-%{pypi_name}} BuildRequires: python3-devel BuildRequires: python3-setuptools Requires: python3-requests Requires: python3-oslo-utils Requires: python3-oslo-log %description -n python3-%{pypi_name} %{common_desc} %endif %prep %autosetup -n %{pypi_name}-%{version} # Remove bundled egg-info rm -rf %{pypi_name}.egg-info # Remove requirements.txt rm -f requirements.txt %build %py2_build %if 0%{?with_python3} %py3_build %endif %install %if 0%{?with_python3} %py3_install %endif %py2_install %files -n python2-%{pypi_name} %license LICENSE %doc README.rst %{python2_sitelib}/%{pypi_name} %{python2_sitelib}/%{pypi_name}-%{version}-py?.?.egg-info %if 0%{?with_python3} %files -n python3-%{pypi_name} %license LICENSE %doc README.rst %{python3_sitelib}/%{pypi_name} %{python3_sitelib}/%{pypi_name}-%{version}-py?.?.egg-info %endif %changelog * Mon Jul 17 2017 Chandan Kumar - 0.2.3-4 - Fixed setuptools package name * Mon Jul 17 2017 Chandan Kumar - 0.2.3-3 - Disable python3 for epel7 * Fri Jul 14 2017 Chandan Kumar - 0.2.3-2 - Fixed Python3 subpackage requires. - Fixed Package URL * Fri Jul 14 2017 Chandan Kumar - 0.2.3-1 - Initial package.