diff options
author | Milan Pässler <milan@petabyte.dev> | 2020-10-11 21:06:30 +0200 |
---|---|---|
committer | Milan Pässler <milan@petabyte.dev> | 2020-10-12 12:27:12 +0200 |
commit | 53b6b4673d12b72519f5bc76f451305ac941b1b4 (patch) | |
tree | 7ea6b5e82a088a642cce31f0ca40e9bc4d06dd02 /pkgs/coreboot/default.nix | |
parent | b00e192187b0df94682712d5ba5a88c923a6b0ce (diff) |
add seabios
Diffstat (limited to 'pkgs/coreboot/default.nix')
-rw-r--r-- | pkgs/coreboot/default.nix | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/pkgs/coreboot/default.nix b/pkgs/coreboot/default.nix index 044e3667d650..3a24dd92fb54 100644 --- a/pkgs/coreboot/default.nix +++ b/pkgs/coreboot/default.nix @@ -44,9 +44,12 @@ let ''; }; - filteredConfig = lib.filterAttrs (n: v: v != null) corebootConfig; - lines = lib.mapAttrsToList (name: value: "${name}=${value}") filteredConfig; - configFile = writeText "config" (lib.concatStringsSep "\n" lines); + writeConfig = config: let + filteredConfig = lib.filterAttrs (n: v: v != null) config; + lines = lib.mapAttrsToList (name: value: "${name}=${value}") filteredConfig; + configFile = writeText "config" (lib.concatStringsSep "\n" lines); + in configFile; + in stdenv.mkDerivation rec { pname = "coreboot"; @@ -61,7 +64,7 @@ in stdenv.mkDerivation rec { configurePhase = '' runHook preConfigure - cp ${configFile} .config + cp ${writeConfig corebootConfig} .config make olddefconfig runHook postConfigure ''; @@ -72,6 +75,6 @@ in stdenv.mkDerivation rec { ''; passthru = { - inherit toolchain configFile; + inherit toolchain writeConfig corebootConfig; }; } |