!1 python-os-xenapi打包材料提交
From: @the-moon-is-blue Reviewed-by: Signed-off-by:
This commit is contained in:
commit
5512c883e1
BIN
os-xenapi-0.3.4.tar.gz
Normal file
BIN
os-xenapi-0.3.4.tar.gz
Normal file
Binary file not shown.
131
python-os-xenapi.spec
Normal file
131
python-os-xenapi.spec
Normal file
@ -0,0 +1,131 @@
|
|||||||
|
%global _empty_manifest_terminate_build 0
|
||||||
|
%global with_doc 0
|
||||||
|
|
||||||
|
|
||||||
|
Name: python-os-xenapi
|
||||||
|
Version: 0.3.4
|
||||||
|
Release: 1%{?dist}
|
||||||
|
Summary: XenAPI library for OpenStack projects
|
||||||
|
License: Apache-2.0
|
||||||
|
URL: http://launchpad.net/os-xenapi/
|
||||||
|
Source0: http://tarballs.openstack.org/os-xenapi/os-xenapi-0.3.4.tar.gz
|
||||||
|
BuildArch: noarch
|
||||||
|
|
||||||
|
BuildRequires: git
|
||||||
|
BuildRequires: openstack-macros
|
||||||
|
|
||||||
|
%package -n python3-os-xenapi
|
||||||
|
Summary: XenAPI client library for OpenStack projects
|
||||||
|
%{?python_provide:%python_provide python3-os-xenapi}
|
||||||
|
Obsoletes: python2-os-xenapi < 0.3.4-1
|
||||||
|
|
||||||
|
BuildRequires: python3-devel
|
||||||
|
BuildRequires: python3-pbr >= 2.0.0
|
||||||
|
BuildRequires: python3-pip
|
||||||
|
BuildRequires: python3-mock
|
||||||
|
BuildRequires: python3-setuptools
|
||||||
|
BuildRequires: python3-babel
|
||||||
|
BuildRequires: python3-paramiko
|
||||||
|
# Required for tests
|
||||||
|
BuildRequires: python3-oslo-concurrency
|
||||||
|
BuildRequires: python3-oslo-i18n
|
||||||
|
BuildRequires: python3-oslo-log
|
||||||
|
BuildRequires: python3-oslotest
|
||||||
|
BuildRequires: python3-os-testr
|
||||||
|
BuildRequires: python3-testrepository
|
||||||
|
BuildRequires: python3-testscenarios
|
||||||
|
BuildRequires: python3-testtools
|
||||||
|
BuildRequires: python3-eventlet >= 0.18.2
|
||||||
|
|
||||||
|
Requires: python3-eventlet >= 0.18.2
|
||||||
|
Requires: python3-oslo-concurrency >= 3.26.0
|
||||||
|
Requires: python3-oslo-log >= 3.36.0
|
||||||
|
Requires: python3-oslo-utils >= 3.33.0
|
||||||
|
Requires: python3-oslo-i18n >= 3.15.3
|
||||||
|
Requires: python3-six >= 1.10.0
|
||||||
|
Requires: python3-pbr >= 2.0.0
|
||||||
|
Requires: python3-babel
|
||||||
|
Requires: python3-paramiko
|
||||||
|
|
||||||
|
%description -n python3-os-xenapi
|
||||||
|
XenAPI library for OpenStack projects.
|
||||||
|
|
||||||
|
%package -n python3-os-xenapi-tests
|
||||||
|
Summary: Tests for XenAPI library for OpenStack projects
|
||||||
|
Requires: python3-os-xenapi = 0.3.4-1
|
||||||
|
Requires: python3-oslotest
|
||||||
|
Requires: python3-os-testr
|
||||||
|
Requires: python3-testrepository
|
||||||
|
Requires: python3-testscenarios
|
||||||
|
Requires: python3-testtools
|
||||||
|
|
||||||
|
%description -n python3-os-xenapi-tests
|
||||||
|
XenAPI library for OpenStack projects.
|
||||||
|
|
||||||
|
|
||||||
|
%if 0%{?with_doc}
|
||||||
|
%package -n python-os-xenapi-doc
|
||||||
|
Summary: Documentation for XenAPI library for OpenStack projects
|
||||||
|
|
||||||
|
BuildRequires: python3-sphinx
|
||||||
|
BuildRequires: python3-oslo-sphinx
|
||||||
|
|
||||||
|
%description -n python-os-xenapi-doc
|
||||||
|
XenAPI library for OpenStack projects.
|
||||||
|
|
||||||
|
This package contains the documentation.
|
||||||
|
%endif
|
||||||
|
|
||||||
|
%description
|
||||||
|
XenAPI library for OpenStack projects.
|
||||||
|
|
||||||
|
|
||||||
|
%prep
|
||||||
|
%autosetup -n os-xenapi-0.3.4 -S git
|
||||||
|
|
||||||
|
# Let's handle dependencies ourseleves
|
||||||
|
%py_req_cleanup
|
||||||
|
|
||||||
|
%build
|
||||||
|
%{py3_build}
|
||||||
|
|
||||||
|
%if 0%{?with_doc}
|
||||||
|
# generate html docs
|
||||||
|
%{py3_bin} setup.py build_sphinx
|
||||||
|
# remove the sphinx-build-%{pyver} leftovers
|
||||||
|
rm -rf doc/build/html/.{doctrees,buildinfo}
|
||||||
|
%endif
|
||||||
|
|
||||||
|
%install
|
||||||
|
%{py3_install}
|
||||||
|
# Remove the dom0 bits, we're not supporting them
|
||||||
|
rm -rf %{buildroot}%{python3_sitelib}/os_xenapi/dom0
|
||||||
|
# Create a versioned binary for backwards compatibility until everything is pure py3
|
||||||
|
ln -s xenapi_bootstrap %{buildroot}%{_bindir}/xenapi_bootstrap-3
|
||||||
|
|
||||||
|
|
||||||
|
%check
|
||||||
|
export PYTHON=python3
|
||||||
|
|
||||||
|
ostestr --color --slowest --blacklist_file exclusion_py3.txt
|
||||||
|
|
||||||
|
%files -n python3-os-xenapi
|
||||||
|
%license LICENSE
|
||||||
|
%{python3_sitelib}/os_xenapi
|
||||||
|
%{python3_sitelib}/os_xenapi-*.egg-info
|
||||||
|
%{_bindir}/xenapi_bootstrap
|
||||||
|
%{_bindir}/xenapi_bootstrap-3
|
||||||
|
%exclude /%{python3_sitelib}/os_xenapi/tests
|
||||||
|
|
||||||
|
%files -n python3-os-xenapi-tests
|
||||||
|
%{python3_sitelib}/os_xenapi/tests
|
||||||
|
|
||||||
|
%if 0%{?with_doc}
|
||||||
|
%files -n python-os-xenapi-doc
|
||||||
|
%license LICENSE
|
||||||
|
%doc doc/build/html README.rst
|
||||||
|
%endif
|
||||||
|
|
||||||
|
%changelog
|
||||||
|
* Thu Jan 13 2021 Python_Bot <Python_Bot@openeuler.org>
|
||||||
|
- Package Spec generated
|
||||||
Loading…
x
Reference in New Issue
Block a user