From 0886057526de872f90daa43caeb4c359fef15d59 Mon Sep 17 00:00:00 2001 From: Miro Hrončok Date: Sep 16 2019 09:32:21 +0000 Subject: Subpackage python2-nine has been removed --- diff --git a/python-nine.spec b/python-nine.spec index f82a5b0..cf946f8 100644 --- a/python-nine.spec +++ b/python-nine.spec @@ -1,20 +1,8 @@ -%if 0%{?fedora} -%global with_python3 1 -%endif - -%{!?_licensedir: %global license %%doc} - -%if 0%{?rhel} && 0%{?rhel} <= 6 -%{!?__python2: %global __python2 /usr/bin/python2} -%{!?python2_sitelib: %global python2_sitelib %(%{__python2} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")} -%{!?python2_sitearch: %global python2_sitearch %(%{__python2} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib(1))")} -%endif - %global modname nine Name: python-nine Version: 0.3.4 -Release: 19%{?dist} +Release: 20%{?dist} Summary: Python 2 / 3 compatibility, like six, but favouring Python 3 License: Public Domain @@ -23,17 +11,9 @@ Source0: https://pypi.python.org/packages/source/n/%{modname}/%{modna BuildArch: noarch -BuildRequires: python2-devel -BuildRequires: python2-setuptools - -%if 0%{?with_python3} BuildRequires: python3-devel BuildRequires: python3-setuptools -%endif -%if 0%{?rhel} && 0%{?rhel} <= 6 -BuildRequires: python-importlib -%endif %global _description\ Let's write Python 3 right now!\ @@ -55,90 +35,39 @@ new projects. %description %_description -%package -n python2-nine -Summary: %summary -%if 0%{?rhel} && 0%{?rhel} <= 6 -Requires: python-importlib -%endif -%{?python_provide:%python_provide python2-nine} - -%description -n python2-nine %_description - -%if 0%{?with_python3} %package -n python3-nine -Summary: Python 2 / 3 compatibility, like six, but favouring Python 3 - -%description -n python3-nine -Let's write Python 3 right now! +Summary: %{summary} +%{?python_provide:%python_provide python3-nine} -When the best Python 2/Python 3 compatibility modules -- especially the -famous `*six* library invented by Benjamin Peterson -`_ -- were created, they were written -from the point of view of a Python 2 programmer starting to grok Python 3. - -When thou writeth Python, thou shalt write Python 3 and, just for a while, -ensure that the thing worketh on Python 2.7 and, possibly, even 2.6. - -Just before Python 2 is finally phased out, thine codebase shall look more -like 3 than like 2. - -nine facilitates this new point of view. You can write code that is as -3ish as possible while still supporting 2.6. Very comfortable for writing -new projects. -%endif +%description -n python3-nine %_description %prep %setup -q -n %{modname}-%{version} # Remove bundled egg-info in case it exists rm -rf %{modname}.egg-info -%if 0%{?with_python3} -rm -rf %{py3dir} -cp -a . %{py3dir} -%endif %build -%{__python2} setup.py build -%if 0%{?with_python3} -pushd %{py3dir} -%{__python3} setup.py build -popd -%endif +%py3_build %install -%if 0%{?with_python3} -pushd %{py3dir} -%{__python3} setup.py install -O1 --skip-build --root=%{buildroot} -popd -%endif -%{__python2} setup.py install -O1 --skip-build --root=%{buildroot} +%py3_install %check -%{__python2} setup.py test -%if 0%{?with_python3} -pushd %{py3dir} %{__python3} setup.py test -popd -%endif -%files -n python2-nine -%doc README.rst porting.rst -%{!?_licensedir:%global license %%doc} -%license LICENSE.rst -%{python2_sitelib}/%{modname}/ -%{python2_sitelib}/%{modname}-%{version}* - -%if 0%{?with_python3} %files -n python3-nine %doc README.rst porting.rst -%{!?_licensedir:%global license %%doc} %license LICENSE.rst %{python3_sitelib}/%{modname}/ %{python3_sitelib}/%{modname}-%{version}* -%endif %changelog +* Mon Sep 16 2019 Miro Hrončok - 0.3.4-20 +- Subpackage python2-nine has been removed + See https://fedoraproject.org/wiki/Changes/Mass_Python_2_Package_Removal + * Mon Aug 19 2019 Miro Hrončok - 0.3.4-19 - Rebuilt for Python 3.8