remove python2

This commit is contained in:
19909236985 2020-10-30 14:34:35 +08:00
parent 59a84dee56
commit fee495e5a0

View File

@ -2,15 +2,13 @@
%bcond_with tests
Name: python-jwt
Version: 1.7.1
Release: 2
Release: 3
Summary: JSON Web Token implementation in Python
License: MIT
URL: https://github.com/jpadilla/pyjwt
Source0: https://files.pythonhosted.org/packages/source/P/PyJWT/PyJWT-1.7.1.tar.gz
BuildArch: noarch
BuildRequires: python2-devel python2-setuptools python2-cryptography
%if %{with tests}
BuildRequires: python2-pytest python-pytest-cov python-pytest-runner
BuildRequires: python3-pytest python3-pytest-cov python3-pytest-runner
%endif
BuildRequires: python%{python3_pkgversion}-devel python%{python3_pkgversion}-setuptools python%{python3_pkgversion}-cryptography
@ -20,12 +18,6 @@ JWT is an open, industry-standard (RFC 7519) for representing claims securely be
%description %{_description}
%package -n python2-%{srcname}
Summary: %{summary}
Requires: python2-cryptography
%{?python_provide:%python_provide python2-%{srcname}}
%description -n python2-%{srcname} %{_description}
%package -n python%{python3_pkgversion}-%{srcname}
Summary: %{summary}
@ -40,24 +32,16 @@ Requires: python%{python3_pkgversion}-cryptography
%autosetup -n PyJWT-%{version}
%build
%py2_build
%py3_build
%install
%py2_install
%py3_install
%check
%if %{with tests}
%{__python2} setup.py test
%{__python3} setup.py test
%endif
%files -n python2-jwt
%license LICENSE AUTHORS
%{python2_sitelib}/%{srcname}/
%{python2_sitelib}/*.egg-info
%files -n python%{python3_pkgversion}-jwt
%license LICENSE AUTHORS
%{python3_sitelib}/%{srcname}/
@ -68,6 +52,12 @@ Requires: python%{python3_pkgversion}-cryptography
%doc README.rst
%changelog
* Fri Oct 30 2020 wuchaochao <wuchaochao4@huawei.com> - 1.7.1-3
- Type:bufix
- CVE:NA
- SUG:NA
- DESC:remove python2
* Fri Oct 11 2019 yefei <yefei25@huawei.com> - 1.7.1-2
- Type:enhancement
- ID:NA