From d309bdfbb853cc7b2145903d1edcc86d8370981b Mon Sep 17 00:00:00 2001 From: Charalampos Stratakis Date: Wed, 15 Feb 2017 13:31:07 +0100 Subject: [PATCH] Rebuild as wheel --- python-six.spec | 39 ++++++++++++++++++++++++++++++++++++--- 1 file changed, 36 insertions(+), 3 deletions(-) diff --git a/python-six.spec b/python-six.spec index 94b97dc..3a3eec9 100644 --- a/python-six.spec +++ b/python-six.spec @@ -1,8 +1,12 @@ %global modname six +%global build_wheel 1 + +%global python2_wheelname %{modname}-%{version}-py2.py3-none-any.whl +%global python3_wheelname %python2_wheelname Name: python-%{modname} Version: 1.10.0 -Release: 7%{?dist} +Release: 8%{?dist} Summary: Python 2 and 3 compatibility utilities License: MIT @@ -26,6 +30,11 @@ BuildRequires: python2-setuptools BuildRequires: python2-pytest BuildRequires: tkinter +%if 0%{?build_wheel} +BuildRequires: python2-pip +BuildRequires: python-wheel +%endif + %description -n python2-%{modname} %{_description} Python 2 version. @@ -40,6 +49,11 @@ BuildRequires: python3-setuptools BuildRequires: python3-pytest BuildRequires: python3-tkinter +%if 0%{?build_wheel} +BuildRequires: python%{python3_pkgversion}-pip +BuildRequires: python%{python3_pkgversion}-wheel +%endif + %description -n python3-%{modname} %{_description} Python 3 version. @@ -48,12 +62,28 @@ Python 3 version. %autosetup -n %{modname}-%{version} %build +%if 0%{?build_wheel} +%py2_build_wheel +%else %py2_build +%endif +%if 0%{?build_wheel} +%py3_build_wheel +%else %py3_build +%endif %install +%if 0%{?build_wheel} +%py2_install_wheel %{python2_wheelname} +%else %py2_install +%endif +%if 0%{?build_wheel} +%py3_install_wheel %{python3_wheelname} +%else %py3_install +%endif %check py.test-2 -rfsxX test_six.py @@ -62,17 +92,20 @@ py.test-3 -rfsxX test_six.py %files -n python2-%{modname} %license LICENSE %doc README documentation/index.rst -%{python2_sitelib}/%{modname}-*.egg-info/ +%{python2_sitelib}/%{modname}-*.dist-info/ %{python2_sitelib}/%{modname}.py* %files -n python3-%{modname} %license LICENSE %doc README documentation/index.rst -%{python3_sitelib}/%{modname}-*.egg-info/ +%{python3_sitelib}/%{modname}-*.dist-info/ %{python3_sitelib}/%{modname}.py %{python3_sitelib}/__pycache__/%{modname}.* %changelog +* Mon Feb 13 2017 Charalampos Stratakis - 1.10.0-8 +- Rebuild as wheel + * Sat Feb 11 2017 Fedora Release Engineering - 1.10.0-7 - Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild