Skip to content

Commit

Permalink
downloads: upgrade setuptools from 58.1.0 to 59.1.1
Browse files Browse the repository at this point in the history
setuptools finally upgraded the vendored packaging package, so we
can remove the patch we contributed upstream in
pypa/packaging#294.

A similar patch for pip still lingers (perhaps we haven't tried to
contribute that upstream yet).
  • Loading branch information
indygreg committed Nov 17, 2021
1 parent 759a20e commit cdbf634
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 32 deletions.
28 changes: 0 additions & 28 deletions cpython-unix/build-cpython.sh
Original file line number Diff line number Diff line change
Expand Up @@ -60,34 +60,6 @@ zip -r "${PIP_WHEEL}" *
popd
rm -rf pip-tmp

mkdir setuptools-tmp
pushd setuptools-tmp
unzip "${SETUPTOOLS_WHEEL}"
rm -f "${SETUPTOOLS_WHEEL}"

patch -p1 <<EOF
diff --git a/setuptools/_vendor/packaging/tags.py b/setuptools/_vendor/packaging/tags.py
index 9064910b..c541e648 100644
--- a/setuptools/_vendor/packaging/tags.py
+++ b/setuptools/_vendor/packaging/tags.py
@@ -475,7 +475,10 @@ def _glibc_version_string_ctypes():
# which libc our process is actually using.
#
# Note: typeshed is wrong here so we are ignoring this line.
- process_namespace = ctypes.CDLL(None) # type: ignore
+ try:
+ process_namespace = ctypes.CDLL(None) # type: ignore
+ except OSError:
+ return None
try:
gnu_get_libc_version = process_namespace.gnu_get_libc_version
except AttributeError:
EOF

zip -r "${SETUPTOOLS_WHEEL}" *
popd
rm -rf setuptools-tmp

# If we are cross-compiling, we need to build a host Python to use during
# the build.
if [ "${BUILD_TRIPLE}" != "${TARGET_TRIPLE}" ]; then
Expand Down
8 changes: 4 additions & 4 deletions pythonbuild/downloads.py
Original file line number Diff line number Diff line change
Expand Up @@ -284,10 +284,10 @@
"license_file": "LICENSE.readline.txt",
},
"setuptools": {
"url": "https://files.pythonhosted.org/packages/4e/2e/f8e006dbaaa46ed1e762c287585b92476deb8d3ccb79b720ed3b86bc6113/setuptools-58.1.0-py3-none-any.whl",
"size": 816725,
"sha256": "7324fd4b66efa05cdfc9c89174573a4410acc7848f318cc0565c7fb659dfdc81",
"version": "58.1.0",
"url": "https://files.pythonhosted.org/packages/ed/60/15ee37d6d3385e6a432d39b5ac51f8467178ad989ba50f2b55681c1a038e/setuptools-59.1.1-py3-none-any.whl",
"size": 951244,
"sha256": "fb537610c2dfe77b5896e3ee53dd53fbdd9adc48076c8f28cee3a30fb59a5038",
"version": "59.1.1",
},
"sqlite": {
"url": "https://www.sqlite.org/2021/sqlite-autoconf-3360000.tar.gz",
Expand Down

0 comments on commit cdbf634

Please sign in to comment.