python3: add pythonForBuild as parameter, fixes python3Minimal
`pythonForBuild` exists for cross-compilation. When one overrides python, one needs to ensure pythonForBuild matches.
This commit is contained in:
parent
26328a4cf2
commit
1939a97811
@ -17,6 +17,7 @@
|
|||||||
# For the Python package set
|
# For the Python package set
|
||||||
, packageOverrides ? (self: super: {})
|
, packageOverrides ? (self: super: {})
|
||||||
, buildPackages
|
, buildPackages
|
||||||
|
, pythonForBuild ? buildPackages.${"python${sourceVersion.major}${sourceVersion.minor}"}
|
||||||
, sourceVersion
|
, sourceVersion
|
||||||
, sha256
|
, sha256
|
||||||
, passthruFun
|
, passthruFun
|
||||||
@ -63,7 +64,7 @@ let
|
|||||||
|
|
||||||
hasDistutilsCxxPatch = !(stdenv.cc.isGNU or false);
|
hasDistutilsCxxPatch = !(stdenv.cc.isGNU or false);
|
||||||
|
|
||||||
pythonForBuild = buildPackages.${"python${sourceVersion.major}${sourceVersion.minor}"};
|
inherit pythonForBuild;
|
||||||
|
|
||||||
pythonForBuildInterpreter = if stdenv.hostPlatform == stdenv.buildPlatform then
|
pythonForBuildInterpreter = if stdenv.hostPlatform == stdenv.buildPlatform then
|
||||||
"$out/bin/python"
|
"$out/bin/python"
|
||||||
|
@ -129,6 +129,7 @@ in rec {
|
|||||||
# Minimal versions of Python (built without optional dependencies)
|
# Minimal versions of Python (built without optional dependencies)
|
||||||
python3Minimal = (python37.override {
|
python3Minimal = (python37.override {
|
||||||
self = python3Minimal;
|
self = python3Minimal;
|
||||||
|
pythonForBuild = pkgs.buildPackages.python3Minimal;
|
||||||
# strip down that python version as much as possible
|
# strip down that python version as much as possible
|
||||||
openssl = null;
|
openssl = null;
|
||||||
readline = null;
|
readline = null;
|
||||||
|
Loading…
Reference in New Issue
Block a user