diff options
author | Jan Malakhovski <oxij@oxij.org> | 2019-02-23 00:00:00 +0000 |
---|---|---|
committer | danbst <abcz2.uprola@gmail.com> | 2019-03-08 11:37:20 +0200 |
commit | 83ae1ffed43f5dc54bcfd58655974293d215df6e (patch) | |
tree | 55558ec1d2444341995889f3ebf9c4a5c563286c /pkgs/top-level/default.nix | |
parent | 5aa813dcc942d05485b89a89e734d231f31eaa9f (diff) | |
download | nixlib-83ae1ffed43f5dc54bcfd58655974293d215df6e.tar nixlib-83ae1ffed43f5dc54bcfd58655974293d215df6e.tar.gz nixlib-83ae1ffed43f5dc54bcfd58655974293d215df6e.tar.bz2 nixlib-83ae1ffed43f5dc54bcfd58655974293d215df6e.tar.lz nixlib-83ae1ffed43f5dc54bcfd58655974293d215df6e.tar.xz nixlib-83ae1ffed43f5dc54bcfd58655974293d215df6e.tar.zst nixlib-83ae1ffed43f5dc54bcfd58655974293d215df6e.zip |
pkgs/top-level/stage.nix: don't override `overlays` and `config` in `nixpkgsFun`
`nixpkgsFun` already sets them via `args`. Doing this also introduces unexpected hard to debug errors, see the patch.
Diffstat (limited to 'pkgs/top-level/default.nix')
-rw-r--r-- | pkgs/top-level/default.nix | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/pkgs/top-level/default.nix b/pkgs/top-level/default.nix index 4afea6d7fdff..b6de076a570c 100644 --- a/pkgs/top-level/default.nix +++ b/pkgs/top-level/default.nix @@ -98,6 +98,14 @@ in let # compiling toolchains and 32-bit packages on x86_64). In both those cases we # want the provided non-native `localSystem` argument to affect the stdenv # chosen. + # + # NB!!! This thing gets its `config` argument from `args`, i.e. it's actually + # `config0`. It is important to keep it to `config0` format (as opposed to the + # result of `evalModules`, i.e. the `config` variable above) throughout all + # nixpkgs evaluations since the above function `config0 -> config` implemented + # via `evalModules` is not idempotent. In other words, if you add `config` to + # `newArgs`, expect strange very hard to debug errors! (Yes, I'm speaking from + # experience here.) nixpkgsFun = newArgs: import ./. (args // newArgs); # Partially apply some arguments for building bootstraping stage pkgs |