@@ -122,18 +122,22 @@ in let
122122 config = lib . showWarnings configEval . config . warnings configEval . config ;
123123
124124 # A few packages make a new package set to draw their dependencies from.
125- # Rather than give `all-packages.nix` all the arguments to this function,
126- # even ones that don't concern it, we give it this function to "re-call"
127- # nixpkgs, inheriting whatever arguments it doesn't explicitly provide. This
128- # way, `all-packages.nix` doesn't know more than it needs to.
125+ # (Currently to get a cross tool chain, or forced-i686 package.) Rather than
126+ # give `all-packages.nix` all the arguments to this function, even ones that
127+ # don't concern it, we give it this function to "re-call" nixpkgs, inheriting
128+ # whatever arguments it doesn't explicitly provide. This way,
129+ # `all-packages.nix` doesn't know more than it needs too.
129130 #
130131 # It's OK that `args` doesn't include default arguments from this file:
131132 # they'll be deterministically inferred. In fact we must *not* include them,
132133 # because it's important that if some parameter which affects the default is
133134 # substituted with a different argument, the default is re-inferred.
134135 #
135- # To put this in concrete terms, we want the provided non-native `localSystem`
136- # and `crossSystem` arguments to affect the stdenv chosen.
136+ # To put this in concrete terms, this function is basically just used today to
137+ # use package for a different platform for the current platform (namely cross
138+ # compiling toolchains and 32-bit packages on x86_64). In both those cases we
139+ # want the provided non-native `localSystem` argument to affect the stdenv
140+ # chosen.
137141 #
138142 # NB!!! This thing gets its `config` argument from `args`, i.e. it's actually
139143 # `config0`. It is important to keep it to `config0` format (as opposed to the
@@ -142,7 +146,7 @@ in let
142146 # via `evalModules` is not idempotent. In other words, if you add `config` to
143147 # `newArgs`, expect strange very hard to debug errors! (Yes, I'm speaking from
144148 # experience here.)
145- nixpkgsFun = f0 : import ./. ( args // f0 args ) ;
149+ nixpkgsFun = newArgs : import ./. ( args // newArgs ) ;
146150
147151 # Partially apply some arguments for building bootstraping stage pkgs
148152 # sets. Only apply arguments which no stdenv would want to override.
0 commit comments