From 568d663a9e23a4f2783df244458dd2e28448cf09 Mon Sep 17 00:00:00 2001 From: Parag Nemade Date: Tue, 18 Sep 2018 14:16:28 +0530 Subject: [PATCH] Remove python2 subpackage --- python-cpuinfo.spec | 39 ++++++++------------------------------- 1 file changed, 8 insertions(+), 31 deletions(-) diff --git a/python-cpuinfo.spec b/python-cpuinfo.spec index 53a29be..f935791 100644 --- a/python-cpuinfo.spec +++ b/python-cpuinfo.spec @@ -1,9 +1,10 @@ +%{?python_enable_dependency_generator} %global srcname cpuinfo %global sum Getting CPU info Name: python-%{srcname} Version: 4.0.0 -Release: 3%{?dist} +Release: 4%{?dist} Summary: %{sum} License: MIT @@ -16,10 +17,8 @@ Patch0: py-cpuinfo-s390x.patch BuildArch: noarch # https://github.com/workhorsy/py-cpuinfo/issues/55 -# ExclusiveArch: %{ix86} x86_64 %{power64} s390x noarch +# ExclusiveArch: %%{ix86} x86_64 %%{power64} s390x noarch -BuildRequires: python2-devel -BuildRequires: python2-setuptools BuildRequires: python3-devel BuildRequires: python3-setuptools @@ -36,22 +35,6 @@ These approaches are used for getting info: Querying x86 CPUID register -%package -n python2-%{srcname} -Summary: %{sum} -%{?python_provide:%python_provide python2-%{srcname}} - -%description -n python2-%{srcname} -Py-cpuinfo gets CPU info with pure Python. Py-cpuinfo should work without -any extra programs or libraries, beyond what your OS provides. - -These approaches are used for getting info: - Windows Registry - /proc/cpuinfo - sysctl - dmesg - isainfo and psrinfo - Querying x86 CPUID register - %package -n python3-%{srcname} Summary: %{sum} %{?python_provide:%python_provide python3-%{srcname}} @@ -76,25 +59,16 @@ sed -i -e '/^#!\//, 1d' cpuinfo/cpuinfo.py %build -%py2_build %py3_build %install %py3_install -cp -p %{buildroot}/%{_bindir}/cpuinfo %{buildroot}/%{_bindir}/cpuinfo-3 -%py2_install +mv %{buildroot}/%{_bindir}/cpuinfo %{buildroot}/%{_bindir}/cpuinfo-3 + %check -%{__python2} setup.py test %{__python3} setup.py test -%files -n python2-%{srcname} -%doc README.rst ChangeLog -%license LICENSE -%{_bindir}/cpuinfo -%{python2_sitelib}/%{srcname}/ -%{python2_sitelib}/py_%{srcname}-%{version}-py2.*.egg-info - %files -n python3-%{srcname} %doc README.rst ChangeLog %license LICENSE @@ -104,6 +78,9 @@ cp -p %{buildroot}/%{_bindir}/cpuinfo %{buildroot}/%{_bindir}/cpuinfo-3 %changelog +* Tue Sep 18 2018 Parag Nemade - 4.0.0-4 +- Remove python2 subpackage + * Fri Jul 13 2018 Fedora Release Engineering - 4.0.0-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild