top-level: Allow manually specifying a stdenv, and fix stdenv tests

- The darwin test can now force the use of the freshly-booted darwin stdenv
 - The linux test now passes enough dummy arguments

This may make debugging harder, if so, check out #20889
This commit is contained in:
John Ericson
2016-12-03 17:21:07 -08:00
parent 4751d9e5ad
commit 5c6234a7d3
3 changed files with 16 additions and 5 deletions
+5 -1
View File
@@ -23,6 +23,10 @@
, # Allow a configuration attribute set to be passed in as an argument.
config ? {}
, # The standard environment for building packages, or rather a function
# providing it. See below for the arguments given to that function.
stdenv ? assert false; null
, crossSystem ? null
, platform ? assert false; null
} @ args:
@@ -72,7 +76,7 @@ in let
inherit lib nixpkgsFun;
} // newArgs);
stdenv = import ../stdenv {
stdenv = (args.stdenv or (import ../stdenv)) {
inherit lib allPackages system platform crossSystem config;
};