diff options
author | Nicolas B. Pierron <nicolas.b.pierron@gmail.com> | 2016-03-20 18:23:29 +0000 |
---|---|---|
committer | Nicolas B. Pierron <nicolas.b.pierron@gmail.com> | 2016-03-20 18:23:29 +0000 |
commit | 598ed874df099987545bfb96fe0f8d076321bdea (patch) | |
tree | feac5eccc28a4b66922d5b672c54e80ea6301988 /pkgs/top-level/default.nix | |
parent | a190baa4791d4b29bfe51f2e21894454940d480c (diff) |
Add extra argument to better identity with the extend function later.
Diffstat (limited to 'pkgs/top-level/default.nix')
-rw-r--r-- | pkgs/top-level/default.nix | 25 |
1 files changed, 13 insertions, 12 deletions
diff --git a/pkgs/top-level/default.nix b/pkgs/top-level/default.nix index 36f0ce0ab3b06..f1082226d76ca 100644 --- a/pkgs/top-level/default.nix +++ b/pkgs/top-level/default.nix @@ -104,7 +104,7 @@ let # We don't want stdenv overrides in the case of cross-building, or # otherwise the basic overrided packages will not be built with the # crossStdenv adapter. - stdenvOverrides = pkgs: + stdenvOverrides = self: pkgs: lib.optionalAttrs (crossSystem == null && pkgs.stdenv ? overrides) (pkgs.stdenv.overrides pkgs); @@ -113,33 +113,34 @@ let # function is very expensive! pkgsWithOverrides = overrider: let - stdenvAdapters = + stdenvAdapters = self: super: let res = import ../stdenv/adapters.nix pkgs; in res // { stdenvAdapters = res; }; - trivialBuilders = + trivialBuilders = self: super: (import ../build-support/trivial-builders.nix { inherit lib; inherit (pkgs) stdenv; inherit (pkgs.xorg) lndir; }); - stdenvDefault = (import ./stdenv.nix topLevelArguments) {} pkgs; + stdenvDefault = self: super: (import ./stdenv.nix topLevelArguments) {} pkgs; allPackagesArgs = topLevelArguments // { inherit pkgsWithOverrides; }; - allPackages = + allPackages = self: super: let res = import ./all-packages.nix allPackagesArgs res pkgs; in res; - aliases = super: import ./aliases.nix super; + aliases = self: super: import ./aliases.nix super; - pkgs_2 = stdenvAdapters; - pkgs_3 = pkgs_2 // trivialBuilders; - pkgs_4 = pkgs_3 // stdenvDefault; - pkgs_5 = pkgs_4 // allPackages; - pkgs_6 = pkgs_5 // aliases pkgs_5; + pkgs_1 = {}; + pkgs_2 = pkgs_1 // stdenvAdapters pkgs pkgs_1; + pkgs_3 = pkgs_2 // trivialBuilders pkgs pkgs_2; + pkgs_4 = pkgs_3 // stdenvDefault pkgs pkgs_3; + pkgs_5 = pkgs_4 // allPackages pkgs pkgs_4; + pkgs_6 = pkgs_5 // aliases pkgs pkgs_5; pkgs_7 = pkgs_6 // overrider pkgs pkgs_6; # The overriden, final packages. - pkgs = pkgs_7 // stdenvOverrides pkgs_6; + pkgs = pkgs_7 // stdenvOverrides pkgs pkgs_6; in pkgs; in |