pkgs/overlays/unstable-from-source: fix handling of overlays
crossOverlays are just overlays applied only in the final layer
This commit is contained in:
parent
2d88df163a
commit
6e95f125ce
1 changed files with 11 additions and 5 deletions
|
@ -17,6 +17,13 @@ let
|
||||||
"parsed"
|
"parsed"
|
||||||
];
|
];
|
||||||
|
|
||||||
|
# if overlay is found in previous layer, then it was provided in "overlays" argument
|
||||||
|
# otherwise, it is provided in "crossOverlays" argument.
|
||||||
|
overlays = self.lib.groupBy (overlay:
|
||||||
|
if self.lib.elem overlay self.buildPackages.overlays then "allLayers"
|
||||||
|
else "finalLayer"
|
||||||
|
) self.overlays;
|
||||||
|
|
||||||
unstablePkgs = import unstableSource {
|
unstablePkgs = import unstableSource {
|
||||||
# localSystem -> pkgs.stdenv.buildPlatform
|
# localSystem -> pkgs.stdenv.buildPlatform
|
||||||
localSystem = sanitizePlatform self.stdenv.buildPlatform;
|
localSystem = sanitizePlatform self.stdenv.buildPlatform;
|
||||||
|
@ -24,11 +31,10 @@ let
|
||||||
# passing below
|
# passing below
|
||||||
# config -> pkgs.config
|
# config -> pkgs.config
|
||||||
config = self.config;
|
config = self.config;
|
||||||
# overlays -> partial of pkgs.overlays
|
# overlays -> pkgs.buildPackages.overlays
|
||||||
overlays = self.overlays;
|
overlays = overlays.allLayers;
|
||||||
# crossOverlays -> partial of pkgs.overlays
|
# crossOverlays -> pkgs.overlays without pkgs.buildPackages.overlays
|
||||||
# crossOverlays are merged to overlays, not sure what issues that might raise.
|
crossOverlays = overlays.finalLayer;
|
||||||
# ignoring.
|
|
||||||
} // self.lib.optionalAttrs (
|
} // self.lib.optionalAttrs (
|
||||||
self.lib.systems.equals self.stdenv.buildPlatform self.stdenv.hostPlatform
|
self.lib.systems.equals self.stdenv.buildPlatform self.stdenv.hostPlatform
|
||||||
) {
|
) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue