@@ -98,7 +98,18 @@ rec {
9898 packagePlatforms = mapAttrs (name: value:
9999 let res = builtins.tryEval (
100100 if isDerivation value then
101− value.meta.hydraPlatforms or (value.meta.platforms or [ "x86_64-linux" ])
101+ # TODO(@Ericson2314) deduplicate with `checkPlatform` in
102+ # `pkgs/stdenv/generic/check-meta.nix`.
103+ value.meta.hydraPlatforms or (let
104+ raw = value.meta.platforms or [ "x86_64-linux" ];
105+ toPattern = x: if builtins.isString x
106+ then { system = x; }
107+ else { parsed = x; };
108+ uniform = map toPattern raw;
109+ pred = hostPlatform:
110+ lib.any (pat: lib.matchAttrs pat hostPlatform) uniform;
111+ pred' = system: pred (lib.systems.elaborate { inherit system; });
112+ in lib.filter pred' supportedSystems)
102113 else if value.recurseForDerivations or false || value.recurseForRelease or false then
103114 packagePlatforms value
104115 else