add hardware.dts.includes option

This commit is contained in:
Daniel Barlow
2024-12-17 20:36:14 +00:00
parent 44caefcd3b
commit b52133a28b
4 changed files with 24 additions and 6 deletions

View File

@@ -29,6 +29,11 @@ in
description = "List of directories to search for DTS includes (.dtsi files)";
type = types.listOf types.path;
};
includes = mkOption {
default = [ ];
description = "\"dtsi\" fragments to include in the generated device tree";
type = types.listOf types.path;
};
};
defaultOutput = mkOption {
description = "\"Default\" output: what gets built for this device when outputs.default is requested. Typically this is \"mtdimage\" or \"vmroot\"";

View File

@@ -104,7 +104,7 @@ in
system.outputs = rec {
dtb = liminix.builders.dtb {
inherit (config.boot) commandLine;
dts = config.hardware.dts.src;
dts = config.hardware.dts.includes ++ [config.hardware.dts.src];
includes = config.hardware.dts.includePaths ++ [
"${o.kernel.headers}/include"
];