Blame python-designateclient.spec

6ce4532
# Macros for py2/py3 compatibility
6ce4532
%if 0%{?fedora} || 0%{?rhel} > 7
6ce4532
%global pyver %{python3_pkgversion}
6ce4532
%else
6ce4532
%global pyver 2
6ce4532
%endif
6ce4532
6ce4532
%global pyver_bin python%{pyver}
6ce4532
%global pyver_sitelib %python%{pyver}_sitelib
6ce4532
%global pyver_install %py%{pyver}_install
6ce4532
%global pyver_build %py%{pyver}_build
6ce4532
# End of macros for py2/py3 compatibility
6ce4532
f7411d7
%{!?upstream_version: %global upstream_version %{version}%{?milestone}}
6ce4532
%global with_doc 1
7b1a76b
7b1a76b
%global common_desc \
7b1a76b
Client library and command line utility for interacting with Openstack Designate API
f7411d7
e917630
%global sname designateclient
e917630
e917630
Name:       python-%{sname}
6ce4532
Version:    2.11.0
6ce4532
Release:    1%{?dist}
f7411d7
Summary:    Python API and CLI for OpenStack Designate
f7411d7
f7411d7
License:    ASL 2.0
e917630
URL:        https://launchpad.net/python-%{sname}/
7b1a76b
Source0:    https://tarballs.openstack.org/%{name}/%{name}-%{upstream_version}.tar.gz
f7411d7
f7411d7
BuildArch:  noarch
f7411d7
7b1a76b
BuildRequires: git
7b1a76b
e917630
%description
7b1a76b
%{common_desc}
e917630
6ce4532
%package -n python%{pyver}-%{sname}
e917630
Summary:    Python API and CLI for OpenStack Designate
6ce4532
%{?python_provide:%python_provide python%{pyver}-%{sname}}
6ce4532
6ce4532
BuildRequires: python%{pyver}-devel
6ce4532
BuildRequires: python%{pyver}-setuptools
6ce4532
BuildRequires: python%{pyver}-pbr
6ce4532
6ce4532
Requires: python%{pyver}-pbr
6ce4532
Requires: python%{pyver}-keystoneauth1 >= 3.4.0
6ce4532
Requires: python%{pyver}-requests >= 2.14.2
6ce4532
Requires: python%{pyver}-six >= 1.10.0
6ce4532
Requires: python%{pyver}-stevedore
6ce4532
Requires: python%{pyver}-osc-lib >= 1.8.0
6ce4532
Requires: python%{pyver}-debtcollector
6ce4532
Requires: python%{pyver}-oslo-utils >= 3.33.0
6ce4532
Requires: python%{pyver}-oslo-serialization >= 2.18.0
6ce4532
Requires: python%{pyver}-cliff
6ce4532
Requires: python%{pyver}-jsonschema >= 2.6.0
6ce4532
6ce4532
%description -n python%{pyver}-%{sname}
f7411d7
%{common_desc}
f7411d7
f7411d7
6ce4532
%package -n python%{pyver}-%{sname}-tests
e917630
Summary:    Python API and CLI for OpenStack Designate (tests)
6ce4532
%{?python_provide:%python_provide python%{pyver}-%{sname}-tests}
6ce4532
Requires:	python%{pyver}-%{sname} = %{version}-%{release}
f7411d7
6ce4532
%description -n python%{pyver}-%{sname}-tests
e917630
%{common_desc}
e917630
e917630
This package contains Designate client tests files.
e917630
6ce4532
%if 0%{?with_doc}
e917630
%package doc
e917630
Summary:          Documentation for OpenStack Designate API Client
e917630
6ce4532
BuildRequires:    python%{pyver}-sphinx
6ce4532
BuildRequires:    python%{pyver}-openstackdocstheme
6ce4532
BuildRequires:    python%{pyver}-keystoneauth1
6ce4532
BuildRequires:    python%{pyver}-osc-lib
6ce4532
BuildRequires:    python%{pyver}-jsonschema
e917630
e917630
%description      doc
e917630
%{common_desc}
e917630
e917630
This package contains auto-generated documentation.
6ce4532
%endif
Victoria Martínez de la Cruz 6969687
Victoria Martínez de la Cruz 6969687
%prep
7b1a76b
%autosetup -n %{name}-%{upstream_version} -S git
f7411d7
6ce4532
rm -rf *requirements.txt
Victoria Martínez de la Cruz 6969687
Victoria Martínez de la Cruz 6969687
%build
6ce4532
%{pyver_build}
Victoria Martínez de la Cruz 6969687
6ce4532
%if 0%{?with_doc}
6ce4532
%{pyver_bin} setup.py build_sphinx -b html
e917630
%endif
f7411d7
6ce4532
%install
6ce4532
%{pyver_install}
f7411d7
6ce4532
%files -n python%{pyver}-%{sname}
Victoria Martínez de la Cruz 6969687
e917630
%doc README.rst
e917630
%license LICENSE
e917630
6ce4532
%{pyver_sitelib}/designateclient
6ce4532
%exclude %{pyver_sitelib}/%{sname}/tests
6ce4532
%{pyver_sitelib}/*.egg-info
c5eaf5b
%{_bindir}/designate
e917630
6ce4532
%files -n python%{pyver}-%{sname}-tests
6ce4532
%{pyver_sitelib}/%{sname}/tests
e917630
6ce4532
%if 0%{?with_doc}
e917630
%files doc
7b1a76b
%doc doc/build/html
f7411d7
%license LICENSE
6ce4532
%endif
b281c6d
f7411d7
%changelog
6ce4532
* Tue Mar 12 2019 RDO <dev@lists.rdoproject.org> 2.11.0-1
6ce4532
- Update to 2.11.0
9d67e6d