File python-vmware-nsxlib.spec of Package python-vmware-nsxlib

#
# spec file for package python-vmware-nsxlib
#
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via https://bugs.opensuse.org/
#


Name:           python-vmware-nsxlib
Version:        13.0.1~dev24
Release:        0
Summary:        VMware NSX python library
License:        Apache-2.0
Group:          Development/Languages/Python
URL:            https://launchpad.net/vmware-nsxlib
Source0:        vmware-nsxlib-stable-rocky.tar.gz
BuildRequires:  openstack-macros
BuildRequires:  python-neutron-lib
BuildRequires:  python2-mock
BuildRequires:  python2-os-testr
BuildRequires:  python2-oslo.log >= 3.36.0
BuildRequires:  python2-oslotest
BuildRequires:  python2-pyOpenSSL >= 17.1.0
BuildRequires:  python2-requests-mock
BuildRequires:  python2-testrepository
BuildRequires:  python2-testresources
BuildRequires:  python2-testscenarios
BuildRequires:  python2-testtools
BuildRequires:  python3-mock
BuildRequires:  python3-os-testr
BuildRequires:  python3-oslo.log >= 3.36.0
BuildRequires:  python3-oslotest
BuildRequires:  python3-pyOpenSSL >= 17.1.0
BuildRequires:  python3-requests-mock
BuildRequires:  python3-testrepository
BuildRequires:  python3-testresources
BuildRequires:  python3-testscenarios
BuildRequires:  python3-testtools
Requires:       python-eventlet >= 0.18.2
Requires:       python-netaddr >= 0.7.18
Requires:       python-oslo.i18n >= 3.15.3
Requires:       python-oslo.log >= 3.36.0
Requires:       python-oslo.serialization >= 2.18.0
Requires:       python-oslo.utils >= 3.33.0
Requires:       python-pyOpenSSL >= 17.1.0
Requires:       python-six >= 1.10.0
Requires:       python-tenacity >= 4.4.0
BuildArch:      noarch
%ifpython2
Requires:       python-enum34
Requires:       python-neutron-lib
Requires:       python-oslo.service >= 1.24.0
%endif
%python_subpackages

%description
vmware-nsxlib is a python library that interfaces with VMWare NSX

%package -n python-vmware-nsxlib-doc
Summary:        Documentation for vmware-nsxlib
Group:          Documentation/HTML
BuildRequires:  fdupes
BuildRequires:  python-Sphinx
BuildRequires:  python-oslosphinx

%description -n python-vmware-nsxlib-doc
vmware-nsxlib is a python library that interfaces with VMWare NSX
This package contains the documentation

%prep
%autosetup -p1 -n vmware-nsxlib-13.0.1.dev24
%py_req_cleanup
sed -i 's/^warning-is-error.*/warning-is-error = 0/g' setup.cfg

%build
%{python_build}
# generate html docs
PBR_VERSION=13.0.1.dev24 sphinx-build -b html doc/source doc/build/html
# remove the sphinx-build leftovers
rm -rf doc/build/html/.{doctrees,buildinfo}
%fdupes doc/build/html/

%install
%{python_install}
# remove duplicates
%fdupes %{buildroot}%{python_sitelib}

%check
%{python_expand rm -rf .testrepository
ostestr
}

%files %{python_files}
%defattr(-,root,root,-)
%license LICENSE
%{python_sitelib}/vmware_nsxlib
%{python_sitelib}/*.egg-info

%files -n python-vmware-nsxlib-doc
%license LICENSE
%doc README.rst doc/build/html

%changelog
openSUSE Build Service is sponsored by