From 4967166811c0e0096de4e2ae8e10720a26dcd66b Mon Sep 17 00:00:00 2001 From: Christian Helmuth Date: Wed, 21 Aug 2019 12:13:43 +0200 Subject: [PATCH] run: exit if boot modules are missing on linux --- tool/run/boot_dir/linux | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/tool/run/boot_dir/linux b/tool/run/boot_dir/linux index cdf99ca67..bbdcebda7 100644 --- a/tool/run/boot_dir/linux +++ b/tool/run/boot_dir/linux @@ -10,9 +10,19 @@ proc run_boot_dir {binaries} { if {![file exists [run_dir]/genode/ld.lib.so]} { build { lib/ld/linux } } + set missing_boot_modules { } foreach binary $binaries { set src_binary_path "[pwd]/bin/[kernel_specific_binary $binary]" - exec ln -sf $src_binary_path [run_dir]/genode/$binary } + if {[file exists $src_binary_path]} { + exec ln -sf $src_binary_path [run_dir]/genode/$binary + } else { + lappend missing_boot_modules $binary + } + } + if {[llength $missing_boot_modules]} { + puts stderr "Missing boot modules: $missing_boot_modules" + exit -1 + } # check syntax of all boot modules named *.config foreach file [glob -nocomplain [run_dir]/genode/*.config] {