diff --git a/python-novaclient.spec b/python-novaclient.spec index 11d8731..7bceba4 100644 --- a/python-novaclient.spec +++ b/python-novaclient.spec @@ -2,10 +2,6 @@ %global sname novaclient -%if 0%{?fedora} -%global with_python3 1 -%endif - %global common_desc \ This is a client for the OpenStack Nova API. There's a Python API (the \ novaclient module), and a command-line script (nova). Each implements 100% of \ @@ -14,7 +10,7 @@ the OpenStack Nova API. Name: python-novaclient Epoch: 1 Version: 10.1.0 -Release: 2%{?dist} +Release: 3%{?dist} Summary: Python API and CLI for OpenStack Nova License: ASL 2.0 URL: https://launchpad.net/%{name} @@ -26,32 +22,10 @@ BuildRequires: git %description %{common_desc} -%package -n python2-%{sname} -Summary: Python API and CLI for OpenStack Nova -%{?python_provide:%python_provide python2-novaclient} - -BuildRequires: python2-devel -BuildRequires: python2-pbr -BuildRequires: python2-setuptools - -Requires: python2-babel >= 2.3.4 -Requires: python2-iso8601 >= 0.1.11 -Requires: python2-keystoneauth1 >= 3.3.0 -Requires: python2-oslo-i18n >= 3.15.3 -Requires: python2-oslo-serialization >= 2.18.0 -Requires: python2-oslo-utils >= 3.33.0 -Requires: python2-pbr >= 2.0.0 -Requires: python2-prettytable >= 0.7.1 -Requires: python-simplejson >= 3.5.1 -Requires: python2-six >= 1.10.0 - -%description -n python2-%{sname} -%{common_desc} - -%if 0%{?with_python3} %package -n python3-%{sname} Summary: Python API and CLI for OpenStack Nova %{?python_provide:%python_provide python3-novaclient} +Obsoletes: python2-%{sname} < %{version}-%{release} BuildRequires: python3-devel BuildRequires: python3-pbr @@ -70,17 +44,16 @@ Requires: python3-six >= 1.10.0 %description -n python3-%{sname} %{common_desc} -%endif %package doc Summary: Documentation for OpenStack Nova API Client -BuildRequires: python2-sphinx -BuildRequires: python2-openstackdocstheme -BuildRequires: python2-oslo-utils -BuildRequires: python2-keystoneauth1 -BuildRequires: python2-oslo-serialization -BuildRequires: python2-prettytable +BuildRequires: python3-sphinx +BuildRequires: python3-openstackdocstheme +BuildRequires: python3-oslo-utils +BuildRequires: python3-keystoneauth1 +BuildRequires: python3-oslo-serialization +BuildRequires: python3-prettytable %description doc %{common_desc} @@ -94,54 +67,28 @@ This package contains auto-generated documentation. rm -rf {,test-}requirements.txt %build -%py2_build -%if 0%{?with_python3} %py3_build -%endif %install -%if 0%{?with_python3} %py3_install mv %{buildroot}%{_bindir}/nova %{buildroot}%{_bindir}/nova-%{python3_version} ln -s ./nova-%{python3_version} %{buildroot}%{_bindir}/nova-3 +ln -s ./nova-3 %{buildroot}%{_bindir}/nova # Delete tests rm -fr %{buildroot}%{python3_sitelib}/novaclient/tests -%endif - -%py2_install -mv %{buildroot}%{_bindir}/nova %{buildroot}%{_bindir}/nova-%{python2_version} -ln -s ./nova-%{python2_version} %{buildroot}%{_bindir}/nova-2 - -ln -s ./nova-2 %{buildroot}%{_bindir}/nova mkdir -p %{buildroot}%{_sysconfdir}/bash_completion.d install -pm 644 tools/nova.bash_completion \ %{buildroot}%{_sysconfdir}/bash_completion.d/nova -# Delete tests -rm -fr %{buildroot}%{python2_sitelib}/novaclient/tests - -%{__python2} setup.py build_sphinx -b html -%{__python2} setup.py build_sphinx -b man +%{__python3} setup.py build_sphinx -b html +%{__python3} setup.py build_sphinx -b man install -p -D -m 644 doc/build/man/nova.1 %{buildroot}%{_mandir}/man1/nova.1 # Fix hidden-file-or-dir warnings rm -fr doc/build/html/.doctrees doc/build/html/.buildinfo -%files -n python2-%{sname} -%license LICENSE -%doc README.rst -%{python2_sitelib}/%{sname} -%{python2_sitelib}/*.egg-info -%{_sysconfdir}/bash_completion.d -%{_mandir}/man1/nova.1.gz -%{_bindir}/nova -%{_bindir}/nova-2 -%{_bindir}/nova-%{python2_version} - - -%if 0%{?with_python3} %files -n python3-%{sname} %license LICENSE %doc README.rst @@ -149,15 +96,18 @@ rm -fr doc/build/html/.doctrees doc/build/html/.buildinfo %{python3_sitelib}/*.egg-info %{_sysconfdir}/bash_completion.d %{_mandir}/man1/nova.1.gz +%{_bindir}/nova %{_bindir}/nova-3 %{_bindir}/nova-%{python3_version} -%endif %files doc %doc doc/build/html %license LICENSE %changelog +* Fri Feb 15 2019 Alfredo Moralejo - 1:10.1.0-3 +- Remove python2 subpackages + * Sat Feb 02 2019 Fedora Release Engineering - 1:10.1.0-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild