overrideSDK: handle propagated lists of inputs

Improves `overrideSDK` compatibility with https://github.com/oxalica/rust-overlay.

(cherry picked from commit 4392e5a53c)
This commit is contained in:
Randy Eckenrode 2024-05-23 23:05:45 -04:00 committed by github-actions[bot]
parent 15ed5d4537
commit 1c407d20c6

View File

@ -287,6 +287,7 @@ let
replacements = lib.pipe propagatedInputs [
(lib.filter (pkg: pkg != null))
lib.flatten
(map (dep: {
name = builtins.unsafeDiscardStringContext dep;
value = getReplacement newPackages dep;
@ -311,6 +312,7 @@ let
let
mapPackageDeps = lib.flip lib.pipe [
(lib.filter (pkg: pkg != null))
lib.flatten
(map (pkg: {
key = builtins.unsafeDiscardStringContext pkg;
package = pkg;