pkgs/overlays/unstable-from-source: use lib.systems.equals for comparing platforms

This commit is contained in:
Wroclaw 2025-02-17 19:31:00 +01:00
parent ab2379f5e5
commit 5e16b1b0b1

View file

@ -27,11 +27,13 @@ let
# crossOverlays -> partial of pkgs.overlays
# crossOverlays are merged to overlays, not sure what issues that might raise.
# ignoring.
} // (if nixpkgs.stdenv.buildPlatform == nixpkgs.stdenv.hostPlatform then {} else {
} // self.lib.optionalAttrs (
self.lib.systems.equals nixpkgs.stdenv.buildPlatform nixpkgs.stdenv.hostPlatform
) {
# workaround for some odd structured packages that changes behaviour
# when crossSystem is passed.
crossSystem = sanitizePlatform nixpkgs.stdenv.hostPlatform;
});
};
in
{
"${attributeName}" = if useUnstable then unstablePkgsForNixpkgs self else self;