From 480cc9f0dc01b6ee9957fafb259169659689eb8b Mon Sep 17 00:00:00 2001 From: Javier Pena Date: Mar 23 2017 14:07:54 +0000 Subject: Initial import (#1433455). --- diff --git a/.gitignore b/.gitignore index e69de29..4116b93 100644 --- a/.gitignore +++ b/.gitignore @@ -0,0 +1 @@ +/os-win-1.4.1.tar.gz diff --git a/python-os-win.spec b/python-os-win.spec new file mode 100644 index 0000000..ad957dd --- /dev/null +++ b/python-os-win.spec @@ -0,0 +1,148 @@ +%{!?upstream_version: %global upstream_version %{version}%{?milestone}} +%global pypi_name os-win +%global pyname os_win + +%if 0%{?fedora} +%global with_python3 1 +%endif + +Name: python-%{pypi_name} +Version: 1.4.1 +Release: 1%{?dist} +Summary: Windows / Hyper-V library for OpenStack projects + +License: ASL 2.0 +URL: http://www.cloudbase.it/ +Source0: https://tarballs.openstack.org/%{pypi_name}/%{pypi_name}-%{version}.tar.gz +BuildArch: noarch + +%description +This library contains Windows / Hyper-V code commonly used in the OpenStack +projects: nova, cinder, networking-hyperv. The library can be used in any +other OpenStack projects where it is needed. + +%package -n python2-%{pypi_name} +Summary: Windows / Hyper-V library for OpenStack projects +%{?python_provide:%python_provide python2-%{pypi_name}} + +Requires: python-babel >= 2.3.4 +Requires: python-eventlet >= 0.18.2 +Requires: python-oslo-concurrency >= 3.8.0 +Requires: python-oslo-config >= 2:3.14.0 +Requires: python-oslo-log >= 3.11.0 +Requires: python-oslo-utils +Requires: python-oslo-i18n >= 1.5.0 +Requires: python-oslo-service >= 0.7.0 + +BuildRequires: python2-devel +BuildRequires: python-pbr +BuildRequires: python-sphinx +BuildRequires: python-oslo-sphinx +# Required for tests +BuildRequires: python-ddt +BuildRequires: python-eventlet +BuildRequires: python-oslo-concurrency +BuildRequires: python-oslo-i18n +BuildRequires: python-oslo-log +BuildRequires: python-oslo-utils +BuildRequires: python-oslotest +BuildRequires: python-testrepository +BuildRequires: python-testscenarios +BuildRequires: python-testtools + +%description -n python2-%{pypi_name} +This library contains Windows / Hyper-V code commonly used in the OpenStack +projects: nova, cinder, networking-hyperv. The library can be used in any +other OpenStack projects where it is needed. + +%if 0%{?with_python3} +%package -n python3-%{pypi_name} +Summary: Windows / Hyper-V library for OpenStack projects +%{?python_provide:%python_provide python3-%{pypi_name}} + +Requires: python3-babel >= 2.3.4 +Requires: python3-eventlet >= 0.18.2 +Requires: python3-oslo-concurrency >= 3.8.0 +Requires: python3-oslo-config >= 2:3.14.0 +Requires: python3-oslo-log >= 3.11.0 +Requires: python3-oslo-utils +Requires: python3-oslo-i18n >= 1.5.0 +Requires: python3-oslo-service >= 0.7.0 + +BuildRequires: python3-devel +BuildRequires: python3-pbr +BuildRequires: python3-sphinx +BuildRequires: python3-oslo-sphinx +# Required for tests +BuildRequires: python3-ddt +BuildRequires: python3-eventlet +BuildRequires: python3-oslo-concurrency +BuildRequires: python3-oslo-i18n +BuildRequires: python3-oslo-log +BuildRequires: python3-oslo-utils +BuildRequires: python3-oslotest +BuildRequires: python3-testrepository +BuildRequires: python3-testscenarios +BuildRequires: python3-testtools + +%description -n python3-%{pypi_name} +This library contains Windows / Hyper-V code commonly used in the OpenStack +projects: nova, cinder, networking-hyperv. The library can be used in any +other OpenStack projects where it is needed. +%endif + +%package -n python-%{pypi_name}-doc +Summary: Windows / Hyper-V library for OpenStack projects - documentation + +%description -n python-%{pypi_name}-doc +Documentation for the Windows / Hyper-V library for OpenStack projects + +%prep +%setup -q -n %{pypi_name}-%{upstream_version} +# We want to manage requirements ourselves +rm -rf *requirements.txt + +%build +%py2_build +%if 0%{?with_python3} +%py3_build +%endif + +# generate html docs +sphinx-build doc/source html +# remove the sphinx-build leftovers +rm -rf html/.{doctrees,buildinfo} + +%install +%py2_install +%if 0%{?with_python3} +%py3_install +%endif + +%check +%if 0%{?with_python3} +%{__python3} setup.py test +rm -rf .testrepository +%endif +%{__python2} setup.py test + + +%files -n python2-%{pypi_name} +%doc doc/source/readme.rst README.rst +%license LICENSE +%{python2_sitelib}/%{pyname}* + +%if 0%{?with_python3} +%files -n python3-%{pypi_name} +%license LICENSE +%doc doc/source/readme.rst README.rst +%{python3_sitelib}/%{pyname}* +%endif + +%files -n python-%{pypi_name}-doc +%doc html +%license LICENSE + +%changelog +* Fri Mar 17 2017 Javier Peña - 1.4.1-1 +- Initial version, based on the RDO spec diff --git a/sources b/sources index e69de29..07a7a80 100644 --- a/sources +++ b/sources @@ -0,0 +1 @@ +SHA512 (os-win-1.4.1.tar.gz) = 1bc21be5e336a90c3bc96ee3e727e3192fdc8baab548ba67c5b68d10b88661759d02c006a3f579bc0c66ab0c4d63a4b40f684e4f7c6cab9431256cb2fbc1634c