sdist build: use modern pip
the one in apt refused to install certain package versions (that were pinned by hash!!) and installed different versions instead... e.g.: Collecting wheel==0.34.2 (from -r /opt/electrum/contrib/build-linux/sdist/../../../contrib/deterministic-build/requirements.txt (line 112)) Downloading521c6dc7fe/wheel-0.34.2.tar.gz(58kB) 100% |████████████████████████████████| 61kB 3.8MB/s Requested wheel==0.34.2 from521c6dc7fe/wheel-0.34.2.tar.gz (sha256)=8788e9155fe14f54164c1b9eb0a319d98ef02c160725587ad60f14ddc57b6f96 (from -r /opt/electrum/contrib/build-linux/sdist/../../../contrib/deterministic-build/requirements.txt (line 112)), but installing version 0.30.0
This commit is contained in:
@@ -9,6 +9,15 @@ DISTDIR="$PROJECT_ROOT/dist"
|
||||
|
||||
. "$CONTRIB"/build_tools_util.sh
|
||||
|
||||
python3 --version || fail "python interpreter not found"
|
||||
|
||||
# upgrade to modern pip so that it knows the flags we need.
|
||||
# we will then install a pinned version of pip as part of requirements-sdist-build
|
||||
python3 -m pip install --upgrade pip
|
||||
|
||||
info "Installing pinned requirements."
|
||||
python3 -m pip install --no-dependencies --no-warn-script-location -r "$CONTRIB"/deterministic-build/requirements-sdist-build.txt
|
||||
|
||||
|
||||
"$CONTRIB"/make_packages || fail "make_packages failed"
|
||||
|
||||
|
||||
9
contrib/deterministic-build/requirements-sdist-build.txt
Normal file
9
contrib/deterministic-build/requirements-sdist-build.txt
Normal file
@@ -0,0 +1,9 @@
|
||||
pip==20.1.1 \
|
||||
--hash=sha256:27f8dc29387dd83249e06e681ce087e6061826582198a425085e0bf4c1cf3a55 \
|
||||
--hash=sha256:b27c4dedae8c41aa59108f2fa38bf78e0890e590545bc8ece7cdceb4ba60f6e4
|
||||
setuptools==46.4.0 \
|
||||
--hash=sha256:4334fc63121aafb1cc98fd5ae5dd47ea8ad4a38ad638b47af03a686deb14ef5b \
|
||||
--hash=sha256:d05c2c47bbef97fd58632b63dd2b83426db38af18f65c180b2423fea4b67e6b8
|
||||
wheel==0.34.2 \
|
||||
--hash=sha256:8788e9155fe14f54164c1b9eb0a319d98ef02c160725587ad60f14ddc57b6f96 \
|
||||
--hash=sha256:df277cb51e61359aba502208d680f90c0493adec6f0e848af94948778aed386e
|
||||
@@ -20,7 +20,7 @@ which virtualenv > /dev/null 2>&1 || { echo "Please install virtualenv" && exit
|
||||
|
||||
${SYSTEM_PYTHON} -m hashin -h > /dev/null 2>&1 || { ${SYSTEM_PYTHON} -m pip install hashin; }
|
||||
|
||||
for i in '' '-hw' '-binaries' '-wine-build' '-mac-build'; do
|
||||
for i in '' '-hw' '-binaries' '-wine-build' '-mac-build' '-sdist-build'; do
|
||||
rm -rf "$venv_dir"
|
||||
virtualenv -p ${SYSTEM_PYTHON} $venv_dir
|
||||
|
||||
|
||||
3
contrib/requirements/requirements-sdist-build.txt
Normal file
3
contrib/requirements/requirements-sdist-build.txt
Normal file
@@ -0,0 +1,3 @@
|
||||
# need modern versions of pip (and maybe other build tools), the one in apt had issues
|
||||
pip
|
||||
setuptools
|
||||
Reference in New Issue
Block a user