top-level: Make config-overriden stdenv bootstrap more normally

This commit is contained in:
John Ericson
2016-11-06 21:28:38 -08:00
parent ea7bf02268
commit 6bfe04277f
4 changed files with 29 additions and 14 deletions
+17
View File
@@ -0,0 +1,17 @@
{ system, allPackages, platform, crossSystem, config, ... } @ args:
rec {
vanillaStdenv = (import ../. (args // {
# Remove config.replaceStdenv to ensure termination.
config = builtins.removeAttrs config [ "replaceStdenv" ];
})).stdenv;
buildPackages = allPackages {
# It's OK to change the built-time dependencies
allowCustomOverrides = true;
bootStdenv = vanillaStdenv;
inherit system platform crossSystem config;
};
stdenvCustom = config.replaceStdenv { pkgs = buildPackages; };
}