WIP: Upgrade to 20.3
This commit is contained in:
parent
f444f50981
commit
58c5acd7e8
3 changed files with 27 additions and 53 deletions
|
|
@ -13,21 +13,16 @@
|
|||
%endif
|
||||
|
||||
%global srcname pip
|
||||
%global base_version 20.2.4
|
||||
%global base_version 20.3
|
||||
%global upstream_version %{base_version}%{?prerel}
|
||||
%global python_wheelname %{srcname}-%{upstream_version}-py2.py3-none-any.whl
|
||||
%global python_wheeldir %{_datadir}/python-wheels
|
||||
|
||||
%if %{with doc}
|
||||
# Commit hash to use from the repo https://github.com/pypa/pypa-docs-theme
|
||||
%global pypa_theme_commit_hash d2e63fbfc62af3b7050f619b2f5bb8658985b931
|
||||
%endif
|
||||
|
||||
%global bashcompdir %(pkg-config --variable=completionsdir bash-completion 2>/dev/null)
|
||||
|
||||
Name: python-%{srcname}
|
||||
Version: %{base_version}%{?prerel:~%{prerel}}
|
||||
Release: 2%{?dist}
|
||||
Release: 3%{?dist}
|
||||
Summary: A tool for installing and managing Python packages
|
||||
|
||||
# We bundle a lot of libraries with pip, which itself is under MIT license.
|
||||
|
|
@ -73,24 +68,15 @@ BuildRequires: python-setuptools-wheel
|
|||
BuildRequires: python-wheel-wheel
|
||||
%endif
|
||||
|
||||
# Themes required to build the docs.
|
||||
%if %{with doc}
|
||||
Source1: https://github.com/pypa/pypa-docs-theme/archive/%{pypa_theme_commit_hash}.tar.gz
|
||||
Source2: https://github.com/python/python-docs-theme/archive/2018.2.tar.gz
|
||||
%endif
|
||||
|
||||
# Downstream only patch
|
||||
# Emit a warning to the user if pip install is run with root privileges
|
||||
# Issue upstream: https://github.com/pypa/pip/issues/4288
|
||||
Patch1: emit-a-warning-when-running-with-root-privileges.patch
|
||||
|
||||
# Add path to the doc themes to conf.py
|
||||
Patch2: html_theme_path.patch
|
||||
|
||||
# Prevent removing of the system packages installed under /usr/lib
|
||||
# when pip install -U is executed.
|
||||
# https://bugzilla.redhat.com/show_bug.cgi?id=1550368#c24
|
||||
Patch3: remove-existing-dist-only-if-path-conflicts.patch
|
||||
#Patch3: remove-existing-dist-only-if-path-conflicts.patch
|
||||
|
||||
# Use the system level root certificate instead of the one bundled in certifi
|
||||
# https://bugzilla.redhat.com/show_bug.cgi?id=1655253
|
||||
|
|
@ -99,7 +85,7 @@ Patch4: dummy-certifi.patch
|
|||
# Don't warn the user about pip._internal.main() entrypoint
|
||||
# In Fedora, we use that in ensurepip and users cannot do anything about it,
|
||||
# this warning is juts moot. Also, the warning breaks CPython test suite.
|
||||
Patch5: nowarn-pip._internal.main.patch
|
||||
#Patch5: nowarn-pip._internal.main.patch
|
||||
|
||||
# Downstream only patch
|
||||
# Users might have local installations of pip from using
|
||||
|
|
@ -138,9 +124,9 @@ Packages" or "Pip Installs Python".
|
|||
%global bundled() %{expand:
|
||||
Provides: bundled(python%{1}dist(appdirs)) = 1.4.4
|
||||
Provides: bundled(python%{1}dist(cachecontrol)) = 0.12.6
|
||||
Provides: bundled(python%{1}dist(certifi)) = 2020.6.20
|
||||
Provides: bundled(python%{1}dist(certifi)) = 2020.11.8
|
||||
Provides: bundled(python%{1}dist(chardet)) = 3.0.4
|
||||
Provides: bundled(python%{1}dist(colorama)) = 0.4.3
|
||||
Provides: bundled(python%{1}dist(colorama)) = 0.4.4
|
||||
Provides: bundled(python%{1}dist(contextlib2)) = 0.6^post1
|
||||
Provides: bundled(python%{1}dist(distlib)) = 0.3.1
|
||||
Provides: bundled(python%{1}dist(distro)) = 1.5
|
||||
|
|
@ -148,17 +134,17 @@ Provides: bundled(python%{1}dist(html5lib)) = 1.1
|
|||
Provides: bundled(python%{1}dist(idna)) = 2.10
|
||||
Provides: bundled(python%{1}dist(ipaddress)) = 1.0.23
|
||||
Provides: bundled(python%{1}dist(msgpack)) = 1
|
||||
Provides: bundled(python%{1}dist(packaging)) = 20.4
|
||||
Provides: bundled(python%{1}dist(pep517)) = 0.8.2
|
||||
Provides: bundled(python%{1}dist(packaging)) = 20.7
|
||||
Provides: bundled(python%{1}dist(pep517)) = 0.9.1
|
||||
Provides: bundled(python%{1}dist(progress)) = 1.5
|
||||
Provides: bundled(python%{1}dist(pyparsing)) = 2.4.7
|
||||
Provides: bundled(python%{1}dist(requests)) = 2.24
|
||||
Provides: bundled(python%{1}dist(resolvelib)) = 0.4
|
||||
Provides: bundled(python%{1}dist(requests)) = 2.25
|
||||
Provides: bundled(python%{1}dist(resolvelib)) = 0.5.3
|
||||
Provides: bundled(python%{1}dist(retrying)) = 1.3.3
|
||||
Provides: bundled(python%{1}dist(setuptools)) = 44
|
||||
Provides: bundled(python%{1}dist(six)) = 1.15
|
||||
Provides: bundled(python%{1}dist(toml)) = 0.10.1
|
||||
Provides: bundled(python%{1}dist(urllib3)) = 1.25.9
|
||||
Provides: bundled(python%{1}dist(toml)) = 0.10.2
|
||||
Provides: bundled(python%{1}dist(urllib3)) = 1.26.2
|
||||
Provides: bundled(python%{1}dist(webencodings)) = 0.5.1
|
||||
}
|
||||
|
||||
|
|
@ -233,6 +219,7 @@ Packages" or "Pip Installs Python".
|
|||
Summary: A documentation for a tool for installing and managing Python packages
|
||||
|
||||
BuildRequires: python%{python3_pkgversion}-sphinx
|
||||
BuildRequires: python%{python3_pkgversion}-sphinx-inline-tabs
|
||||
|
||||
%description doc
|
||||
A documentation for a tool for installing and managing Python packages
|
||||
|
|
@ -254,22 +241,15 @@ Requires: ca-certificates
|
|||
A Python wheel of pip to use with venv.
|
||||
|
||||
%prep
|
||||
%setup -q -n %{srcname}-%{upstream_version}
|
||||
|
||||
%if %{with doc}
|
||||
pushd docs/html
|
||||
tar -xf %{SOURCE1}
|
||||
mv pypa-docs-theme-%{pypa_theme_commit_hash} pypa
|
||||
tar -xf %{SOURCE2}
|
||||
mv python-docs-theme-2018.2 python-docs-theme
|
||||
popd
|
||||
%endif
|
||||
|
||||
%autopatch -p1
|
||||
%autosetup -p1 -n %{srcname}-%{upstream_version}
|
||||
|
||||
# this goes together with patch4
|
||||
rm src/pip/_vendor/certifi/*.pem
|
||||
|
||||
# Do not use furo as HTML theme in docs
|
||||
# furo is not available in Fedora
|
||||
sed -i '/html_theme = "furo"/d' docs/html/conf.py
|
||||
|
||||
# tests expect wheels in here
|
||||
ln -s %{python_wheeldir} tests/data/common_wheels
|
||||
|
||||
|
|
@ -338,9 +318,10 @@ ln -s ./pip%{python3_version} %{buildroot}%{_bindir}/pip-%{python3_version}
|
|||
ln -s ./pip-%{python3_version} %{buildroot}%{_bindir}/pip-3
|
||||
|
||||
|
||||
# Make sure the INSTALLER is not pip, otherwise Patch2 won't work
|
||||
# Make sure the INSTALLER is not pip and remove RECORD, otherwise Patch2 won't work
|
||||
# %%pyproject macros do this for all packages
|
||||
echo rpm > %{buildroot}%{python3_sitelib}/pip-%{upstream_version}.dist-info/INSTALLER
|
||||
rm %{buildroot}%{python3_sitelib}/pip-%{upstream_version}.dist-info/RECORD
|
||||
|
||||
mkdir -p %{buildroot}%{python_wheeldir}
|
||||
install -p dist/%{python_wheelname} -t %{buildroot}%{python_wheeldir}
|
||||
|
|
@ -411,6 +392,12 @@ pytest_k='not completion and
|
|||
%{python_wheeldir}/%{python_wheelname}
|
||||
|
||||
%changelog
|
||||
* Thu Dec 17 2020 Miro Hrončok <mhroncok@redhat.com> - 20.3-1
|
||||
- Update to 20.3
|
||||
- Add support for PEP 600: Future manylinux Platform Tags
|
||||
- New resolver
|
||||
- Fixes: rhbz#1893470
|
||||
|
||||
* Fri Dec 04 2020 Miro Hrončok <mhroncok@redhat.com> - 20.2.4-2
|
||||
- Disable tests and documentation in Fedora ELN (and RHEL)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue