python3Packages.pip: allow setting reproducible temporary directory via NIX_PIP_INSTALL_TMPDIR

This commit is contained in:
misuzu
2020-06-22 10:58:26 +03:00
committed by Frederik Rietdijk
parent ae1584dc98
commit aedbade43e
3 changed files with 20 additions and 1 deletions

View File

@@ -11,7 +11,9 @@ pipInstallPhase() {
export PYTHONPATH="$out/@pythonSitePackages@:$PYTHONPATH"
pushd dist || return 1
@pythonInterpreter@ -m pip install ./*.whl --no-index --prefix="$out" --no-cache $pipInstallFlags --build tmpbuild
mkdir tmpbuild
NIX_PIP_INSTALL_TMPDIR=tmpbuild @pythonInterpreter@ -m pip install ./*.whl --no-index --prefix="$out" --no-cache $pipInstallFlags
rm -rf tmpbuild
popd || return 1
runHook postInstall