-
Notifications
You must be signed in to change notification settings - Fork 72
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This change adds more packages from `device-pkgs` into the overlay that contributes to the system's package-set. The packages moved over in this change are notably ones that have the `requiredSystemFeatures` attribute. This means that we could eventually remove the `requiredSystemFeatures` option and let users change the derivation how they need in their own overlay.
- Loading branch information
Showing
4 changed files
with
115 additions
and
120 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
{ lib | ||
, pkgs | ||
, runCommand | ||
, cfg | ||
, flash-tools | ||
, mkFlashScript | ||
, mkFlashScriptArgs ? { } | ||
}: | ||
|
||
let | ||
variant = | ||
if builtins.length cfg.firmware.variants != 1 | ||
then throw "mkFlashCmdScript requires exactly one Jetson variant set in hardware.nvidia-jetson.firmware.variants" | ||
else builtins.elemAt cfg.firmware.variants 0; | ||
in | ||
builtins.trace "HERE ${flash-tools.system}" | ||
(runCommand "flash-tools-flashcmd" | ||
{ | ||
# Needed for signing | ||
inherit (cfg.firmware.secureBoot) requiredSystemFeatures; | ||
} '' | ||
export BOARDID=${variant.boardid} | ||
export BOARDSKU=${variant.boardsku} | ||
export FAB=${variant.fab} | ||
export BOARDREV=${variant.boardrev} | ||
${lib.optionalString (variant.chipsku != null) '' | ||
export CHIP_SKU=${variant.chipsku} | ||
''} | ||
export CHIPREV=${variant.chiprev} | ||
${lib.optionalString (variant.ramcode != null) '' | ||
export RAMCODE=${variant.ramcode} | ||
''} | ||
${cfg.firmware.secureBoot.preSignCommands pkgs} | ||
${mkFlashScript flash-tools (mkFlashScriptArgs // { flashArgs = [ "--no-root-check" "--no-flash" ] ++ (mkFlashScriptArgs.flashArgs or cfg.flashScriptOverrides.flashArgs); }) } | ||
cp -r ./ $out | ||
'') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters