remove python2

This commit is contained in:
root 2020-10-29 11:21:59 +08:00
parent c603ab8f8a
commit 591ad00a54

View File

@ -5,7 +5,7 @@ These handlers are designed for Python standard library's logging package.
Name: python-logutils Name: python-logutils
Version: 0.3.5 Version: 0.3.5
Release: 7 Release: 8
License: BSD License: BSD
Summary: Handlers for Python library's logging package Summary: Handlers for Python library's logging package
URL: https://pypi.io/project/logutils URL: https://pypi.io/project/logutils
@ -13,17 +13,10 @@ Source0: https://pypi.io/packages/source/l/logutils/logutils-%{version}.t
BuildArch: noarch BuildArch: noarch
BuildRequires: python2-devel python3-devel BuildRequires: python3-devel
%description %_description %description %_description
%package -n python2-logutils
Summary: Handlers for Python library's logging package
%{?python_provide:%python_provide python2-logutils}
%description -n python2-logutils
%_description
%package -n python3-logutils %package -n python3-logutils
Summary: Handlers for Python library's logging package Summary: Handlers for Python library's logging package
@ -42,32 +35,17 @@ Documentation for python-logutils
%autosetup -n logutils-%{version} %autosetup -n logutils-%{version}
rm -rf logutils.egg-info rm -rf logutils.egg-info
rm -rf %{py3dir} rm -rf %{py2dir}
cp -a . %{py3dir}
%build %build
%{__python2} setup.py build
cd %{py3dir}
%{__python3} setup.py build %{__python3} setup.py build
cd -
%install %install
cd %{py3dir}
%{__python3} setup.py install -O1 --skip-build --root=%{buildroot} %{__python3} setup.py install -O1 --skip-build --root=%{buildroot}
cd -
%{__python2} setup.py install -O1 --skip-build --root=%{buildroot}
%check %check
%{__python2} setup.py test
cd %{py3dir}
%{__python3} setup.py test %{__python3} setup.py test
%files -n python2-logutils
%license LICENSE.txt
%doc README.rst NEWS.txt
%{python2_sitelib}/logutils/
%{python2_sitelib}/logutils-%{version}*
%files -n python3-logutils %files -n python3-logutils
%license LICENSE.txt %license LICENSE.txt
%doc README.rst NEWS.txt %doc README.rst NEWS.txt
@ -78,5 +56,8 @@ cd %{py3dir}
%doc doc/ %doc doc/
%changelog %changelog
* Wed Oct 21 2020 Ge Wang <wangge20@huawei.com> 0.3.5-8
- remove python2
* Thu Mar 12 2020 lihao <lihao129@huawei.com> - 0.3.5-7 * Thu Mar 12 2020 lihao <lihao129@huawei.com> - 0.3.5-7
- Package Init - Package Init