File python-osc-lib.spec of Package python-osc-lib
#
# spec file for package python-osc-lib
#
# Copyright (c) 2020 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/
#
%global sname osc-lib
Name: python-osc-lib
Version: 1.1.0
Release: 0
Summary: OpenStackClient Library
License: Apache-2.0
Group: Development/Languages/Python
Url: http://docs.openstack.org/developer/osc-lib
Source0: https://pypi.io/packages/source/o/%{sname}/%{sname}-%{version}.tar.gz
BuildRequires: openstack-macros
BuildRequires: python-Babel
BuildRequires: python-cliff
BuildRequires: python-devel
BuildRequires: python-fixtures
BuildRequires: python-keystoneauth1
BuildRequires: python-mock
BuildRequires: python-os-client-config
BuildRequires: python-os-testr
BuildRequires: python-oslo.i18n
BuildRequires: python-oslo.utils
BuildRequires: python-oslotest
BuildRequires: python-osprofiler
BuildRequires: python-pbr
BuildRequires: python-reno
BuildRequires: python-requests-mock
BuildRequires: python-simplejson
BuildRequires: python-six
BuildRequires: python-stevedore
BuildRequires: python-testrepository
BuildRequires: python-testtools
Requires: python-Babel
Requires: python-cliff
Requires: python-keystoneauth1
Requires: python-os-client-config
Requires: python-oslo.i18n
Requires: python-oslo.utils
Requires: python-pbr
Requires: python-simplejson
Requires: python-six
Requires: python-stevedore
BuildArch: noarch
%description
OpenStackClient (aka OSC) is a command-line client for OpenStack. osc-lib
is a package of common support modules for writing OSC plugins.
%package doc
Summary: Documentation for the OpenStack client library
Group: Development/Languages/Python
BuildRequires: python-Sphinx
BuildRequires: python-oslosphinx
%description doc
Documentation for the OpenStack client library.
%prep
%setup -q -n %{sname}-%{version}
%build
%{__python2} setup.py build
%install
%{__python2} setup.py install --skip-build --root %{buildroot}
# generate html docs
%{__python2} setup.py build_sphinx
# remove the sphinx-build leftovers
rm -rf doc/build/html/.{doctrees,buildinfo}
%check
%{__python2} setup.py testr
%files
%license LICENSE
%doc README.rst ChangeLog
%{python2_sitelib}/osc_lib
%{python2_sitelib}/*.egg-info
%files doc
%license LICENSE
%doc doc/build/html
%changelog