disable python2

This commit is contained in:
jackie_wu 2020-11-02 11:36:41 +08:00
parent 3f8fba0dd1
commit 74b4542264

View File

@ -1,6 +1,6 @@
Name: pyxdg Name: pyxdg
Version: 0.26 Version: 0.26
Release: 2 Release: 3
Summary: Python library to access freedesktop APIs Summary: Python library to access freedesktop APIs
License: LGPLv2 License: LGPLv2
URL: http://freedesktop.org/Software/pyxdg URL: http://freedesktop.org/Software/pyxdg
@ -12,52 +12,42 @@ BuildRequires: hicolor-icon-theme shared-mime-info
%description %description
PyXDG package provides a library to invoke APIs that conform to freedesktop.org standards. PyXDG package provides a library to invoke APIs that conform to freedesktop.org standards.
%package -n python2-pyxdg
Summary: Python2 library to access freedesktop APIs
BuildRequires: python2-devel python2-nose
%{?python_provide:%python_provide python2-pyxdg}
Provides: pyxdg = %{version}-%{release}
Obsoletes: pyxdg < 0.25-10
%description -n python2-pyxdg
This package contains a Python 2 version of PyXDG.
%package -n python3-pyxdg %package -n python3-pyxdg
Summary: Python3 library to access freedesktop APIs Summary: Python3 library to access freedesktop APIs
BuildRequires: python3-devel python3-nose BuildRequires: python%{python3_pkgversion}-devel
%{?python_provide:%python_provide python3-pyxdg} %if %{with check}
%description -n python3-pyxdg BuildRequires: python%{python3_pkgversion}-nose
%endif
%{?python_provide:%python_provide python%{python3_pkgversion}-pyxdg}
%description -n python%{python3_pkgversion}-pyxdg
This package contains a Python 3 version of PyXDG. This package contains a Python 3 version of PyXDG.
%prep %prep
%autosetup -p1 %autosetup -p1
%build %build
%py2_build
%py3_build %py3_build
%install %install
%py2_install
%py3_install %py3_install
%if %{with check}
%check %check
nosetests-%{python2_version} || :
nosetests-%{python3_version} || : nosetests-%{python3_version} || :
%endif
%files -n python2-pyxdg %files -n python%{python3_pkgversion}-pyxdg
%{python2_sitelib}/xdg
%{python2_sitelib}/pyxdg-*.egg-info
%license COPYING %license COPYING
%doc AUTHORS ChangeLog README TODO %doc AUTHORS ChangeLog README TODO
%files -n python3-pyxdg
%{python3_sitelib}/xdg %{python3_sitelib}/xdg
%{python3_sitelib}/pyxdg-*.egg-info %{python3_sitelib}/pyxdg-*.egg-info
%license COPYING
%doc AUTHORS ChangeLog README TODO
%changelog %changelog
* Wed Oct 21 2020 zhangpeng <zhangpeng228@huawei.com> - 0.26-3
- disable python2
* Thu Nov 28 2019 lihao <lihao129@huawei.com> - 0.26-2 * Thu Nov 28 2019 lihao <lihao129@huawei.com> - 0.26-2
- Package Init - Package Init