boot/splash: describe libraries used
, mruby
}:
+let
+ inherit (lib) concatMapStringsSep;
+
+ # Select libs we need from the libs folder.
+ libs = concatMapStringsSep " " (name: "${../lib}/${name}") [
+ "lvgui/args.rb"
+ "lvgui/fiddlier.rb"
+ "lvgui/lvgl/*.rb"
+ "lvgui/lvgui/*.rb"
+ "lvgui/vtconsole.rb"
+ ];
+in
+
# mkDerivation will append something like -aarch64-unknown-linux-gnu to the
# derivation name with cross, which will break the mruby code loading.
# Since we don't need anything from mkDerivation, really, let's use runCommand.
@@ -16,6 +29,7 @@ runCommand "boot-splash.mrb" {
} ''
mrbc \
-o $out \
+ ${libs} \
$(find $lib -type f -name '*.rb' | sort) \
$(find $src/lib -type f -name '*.rb' | sort) \
$src/main.rb
