Merge pull request #13165 from NixOS/python-wip
Python PIP fix, fixes #12190, closes #13035
This commit is contained in:
commit
846aa6e776
@ -42,6 +42,9 @@
|
||||
# generated binaries.
|
||||
, makeWrapperArgs ? []
|
||||
|
||||
# Additional flags to pass to "pip install".
|
||||
, installFlags ? []
|
||||
|
||||
, ... } @ attrs:
|
||||
|
||||
|
||||
@ -95,7 +98,7 @@ python.stdenv.mkDerivation (builtins.removeAttrs attrs ["disabled" "doCheck"] //
|
||||
export PYTHONPATH="$out/${python.sitePackages}:$PYTHONPATH"
|
||||
|
||||
pushd dist
|
||||
${bootstrapped-pip}/bin/pip install *.whl --no-index --prefix=$out --no-cache
|
||||
${bootstrapped-pip}/bin/pip install *.whl --no-index --prefix=$out --no-cache ${toString installFlags}
|
||||
popd
|
||||
|
||||
runHook postInstall
|
||||
|
@ -15067,6 +15067,10 @@ in modules // {
|
||||
sha256 = "46f4bd0d8dfd51125a554568d646fe4200a3c2c6c36b9f2d06d2212148439521";
|
||||
};
|
||||
|
||||
# pip detects that we already have bootstrapped_pip "installed", so we need
|
||||
# to force it a little.
|
||||
installFlags = [ "--ignore-installed" ];
|
||||
|
||||
buildInputs = with self; [ mock scripttest virtualenv pytest ];
|
||||
};
|
||||
|
||||
@ -15492,7 +15496,7 @@ in modules // {
|
||||
${python.executable} setup.py test
|
||||
'';
|
||||
|
||||
installFlags = optional (versionAtLeast protobuf.version "2.6.0") "--cpp_implementation";
|
||||
installFlags = optional (versionAtLeast protobuf.version "2.6.0") "--install-option='--cpp_implementation'";
|
||||
|
||||
doCheck = true;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user