File python-neutron-lib.spec of Package python-neutron-lib

#
# spec file for package python-neutron-lib
#
# Copyright (c) 2020 SUSE LLC
#
# 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/
#


%global sname neutron-lib
Name:           python-neutron-lib
Version:        1.18.0
Release:        0
Summary:        OpenStack Neutron library
License:        Apache-2.0
Group:          Development/Languages/Python
URL:            https://docs.openstack.org/developer/neutron-lib/
Source0:        https://files.pythonhosted.org/packages/source/n/%{sname}/%{sname}-%{version}.tar.gz
BuildRequires:  openstack-macros
BuildRequires:  python-SQLAlchemy
BuildRequires:  python-debtcollector
BuildRequires:  python-devel
BuildRequires:  python-fixtures
BuildRequires:  python-keystoneauth1
BuildRequires:  python-os-api-ref
BuildRequires:  python-oslo.concurrency
BuildRequires:  python-oslo.config
BuildRequires:  python-oslo.context
BuildRequires:  python-oslo.db
BuildRequires:  python-oslo.i18n
BuildRequires:  python-oslo.log
BuildRequires:  python-oslo.messaging
BuildRequires:  python-oslo.policy
BuildRequires:  python-oslo.service
BuildRequires:  python-oslo.utils
BuildRequires:  python-oslotest
BuildRequires:  python-osprofiler
BuildRequires:  python-pbr
BuildRequires:  python-pecan
BuildRequires:  python-pep8
BuildRequires:  python-python-subunit
BuildRequires:  python-setuptools
BuildRequires:  python-stestr
BuildRequires:  python-testrepository
BuildRequires:  python-testresources
BuildRequires:  python-testscenarios
BuildRequires:  python-testtools
BuildRequires:  python-weakrefmethod
Requires:       python-SQLAlchemy
Requires:       python-debtcollector
Requires:       python-keystoneauth1
Requires:       python-oslo.concurrency
Requires:       python-oslo.config
Requires:       python-oslo.context
Requires:       python-oslo.db
Requires:       python-oslo.i18n
Requires:       python-oslo.log
Requires:       python-oslo.messaging
Requires:       python-oslo.policy
Requires:       python-oslo.service
Requires:       python-oslo.utils
BuildArch:      noarch

%description
OpenStack Neutron library shared by all Neutron sub-projects.

%package doc
Summary:        OpenStack Neutron library documentation
Group:          Documentation/HTML
BuildRequires:  python-Sphinx
BuildRequires:  python-openstackdocstheme
BuildRequires:  python-reno

%description doc
OpenStack Neutron library shared by all Neutron sub-projects.

%prep
%autosetup -n neutron-lib-%{version}
sed -i 's/^warning-is-error.*/warning-is-error = 0/g' setup.cfg

%build
%{py2_build}

%install
%{py2_install}

# Build HTML docs and man page
PBR_VERSION=%{version} sphinx-build -b html doc/source doc/build/html
# remove the sphinx-build leftovers
rm -rf doc/build/html/.{doctrees,buildinfo}

%check
rm -rf .testrepository
stestr init
stestr run

%files
%license LICENSE
%doc README.rst
%{python2_sitelib}/neutron_lib
%{python2_sitelib}/neutron_lib*egg-info

%files doc
%doc doc/build/html
%license LICENSE

%changelog
openSUSE Build Service is sponsored by