From d85ba92b5a0ad083f74087b95e148028277162cb Mon Sep 17 00:00:00 2001 From: Emery Hemingway Date: Sat, 20 Mar 2021 19:50:32 +0100 Subject: [PATCH] nixos: support for an empty second-level init --- nixos-modules/genode-init.nix | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/nixos-modules/genode-init.nix b/nixos-modules/genode-init.nix index a02c2d2..d55bfc7 100644 --- a/nixos-modules/genode-init.nix +++ b/nixos-modules/genode-init.nix @@ -108,8 +108,8 @@ in { configFile = let - children = - lib.mapAttrsToList (name: value: ", `${name}` = ${value.config} ") + children = lib.mapAttrsToList + (name: value: '', { mapKey = "${name}", mapValue = ${value.config} }'') children'; nicRoutes = lib.mapAttrsToList (child: value: @@ -129,7 +129,9 @@ in { in baseConfig // { , verbose = ${if config.genode.init.verbose then "True" else "False"} - , children = baseConfig.children # toMap {${toString children} } + , children = baseConfig.children # ([ ${ + toString children + } ] : Genode.Init.Children.Type) , routes = baseConfig.routes # ([${ toString nicRoutes }] : List Genode.Init.ServiceRoute.Type)