%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 1
%endif
Name: python-%{pypi_name}
Version: 0.2.3
Release: 6%{?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: python2-setuptools
Requires: python2-requests
Requires: python2-oslo-utils
Requires: python2-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
* Tue Jun 19 2018 Miro HronĨok <mhroncok@redhat.com> - 0.2.3-6
- Rebuilt for Python 3.7
* Thu Mar 08 2018 Iryna Shcherbina <ishcherb@redhat.com> - 0.2.3-5
- Update Python 2 dependency declarations to new packaging standards
(See https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3)
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.2.3-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.2.3-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
* Fri Jul 14 2017 Chandan Kumar <chkumar246@gmail.com> - 0.2.3-2
- Fixed Python3 subpackage requires.
- Fixed Package URL
* Fri Jul 14 2017 Chandan Kumar <chkumar246@gmail.com> - 0.2.3-1
- Initial package.