!13 remove python2

From: @jlwwlsqc
Reviewed-by: @small_leek
Signed-off-by: @small_leek
This commit is contained in:
openeuler-ci-bot 2020-11-02 12:00:07 +08:00 committed by Gitee
commit 7f34e59f08

View File

@ -4,15 +4,14 @@
Name: python-%{modname}
Version: 0.16
Release: 4
Release: 5
Summary: Documentation Utilities Written in Python, for General- and Special-Purpose Use
License: Public Domain and BSD and Python and GPLv3+
URL: http://docutils.sourceforge.net
Source0: http://downloads.sourceforge.net/docutils/docutils-0.16.tar.gz
BuildArch: noarch
BuildRequires: python2-devel python2-setuptools
BuildRequires: python3-devel python2-tools
BuildRequires: python3-devel
Patch0000: fix-test-error.patch
%global _description \
@ -24,16 +23,6 @@ to use, what-you-see-is-what-you-get plaintext markup language.
%description
%{_description}
%package -n python2-%{modname}
Summary: %{summary} for python2
%{?python_provide:%python_provide python2-%{modname}}
Provides: docutils = %{version}-%{release}
Obsoletes: docutils < %{version}-%{release}
%description -n python2-%{modname}
%{_description}
%package -n python3-%{modname}
Summary: %{summary} for python3
Requires: python3-lxml
@ -68,15 +57,11 @@ rm -rf test/test_writers/test_odt.py
popd
%build
%py2_build
pushd %{py3dir}
%py3_build
popd
%install
%py2_install
rm -rf %{buildroot}%{python3_sitelib}/test
mv %{flashfilepath}%{flashfilename} ./%{flashfilename}
@ -92,10 +77,6 @@ done
%check
mv %{flashfilename} %{flashfilepath}%{flashfilename}
python2 test/alltests.py
rm %{flashfilepath}%{flashfilename}
pushd %{py3dir}
mv %{flashfilename} %{flashfilepath}%{flashfilename}
python3 test/alltests.py
@ -103,10 +84,6 @@ rm %{flashfilepath}%{flashfilename}
popd
%files -n python2-%{modname}
%license COPYING.txt licenses/*.txt
%{python2_sitelib}/*
%files -n python3-%{modname}
%license COPYING.txt licenses/*.txt
%{python3_sitelib}/*
@ -117,6 +94,12 @@ popd
%doc THANKS.txt docs tools/editors
%changelog
* Mon Nov 2 2020 wangjie<wangjie294@huawei.com> -0.16-5
- Type:NA
- ID:NA
- SUG:NA
- DESC:remove python2
* Thu Sep 10 2020 wangxiao <wangxiao65@huawei.com> - 0.16-4
- fix rst2odt_prepstyles error