tool/run: coding style

This commit is contained in:
Norman Feske 2021-01-21 13:57:56 +01:00
parent ad4211ae2c
commit 4bc9b9a2ef

View File

@ -261,9 +261,11 @@ proc build_boot_image {binaries} {
run_boot_dir $binaries
}
# set expect match-buffer size
match_max -d 40000
##
# Execute Genode
#
@ -484,6 +486,7 @@ proc get_cmd_arg { arg_name default_value } {
return $result
}
##
# Return command-line argument value
#
@ -779,11 +782,13 @@ proc core_ld_opts { } {
return $ret
}
##
# Default core link address
#
proc core_link_address { } { return "0x01000000" }
##
# Check if a specific file is included
#
@ -840,6 +845,7 @@ proc board { } {
#
proc have_board {board} { global board_var; return [expr {$board_var} eq {$board}] }
##
# Determine GDB executable installed at the host
#
@ -998,35 +1004,36 @@ proc build_core_image { modules } {
exec cp -f [run_dir]/genode/config [run_dir].config
}
proc build_initrd { modules } {
copy_genode_binaries_to_run_dir $modules
copy_genode_binaries_to_run_dir $modules
set modules [glob -nocomplain -tails -directory [run_dir]/genode/ *]
set excluded_modules [kernel_files]
set modules [glob -nocomplain -tails -directory [run_dir]/genode/ *]
set excluded_modules [kernel_files]
foreach file [glob -nocomplain [run_dir]/genode/*.config] {
foreach file [glob -nocomplain [run_dir]/genode/*.config] {
check_xml_syntax $file }
exec cp -f [run_dir]/genode/config [run_dir].config
exec cp -f [run_dir]/genode/config [run_dir].config
set here [pwd]
cd [run_dir]
puts "generating initrd"
exec cp genode/initramfs init
exec mkdir tmp
exec mkdir dev
set files "init\ntmp\ndev\ngenode\n"
append files [exec find genode -type f,l -printf "genode/%f\n"]
exec -ignorestderr echo $files | [installed_command cpio] -o -L -H newc > initrd
set here [pwd]
cd [run_dir]
puts "generating initrd"
exec cp genode/initramfs init
exec mkdir tmp
exec mkdir dev
set files "init\ntmp\ndev\ngenode\n"
append files [exec find genode -type f,l -printf "genode/%f\n"]
exec -ignorestderr echo $files | [installed_command cpio] -o -L -H newc > initrd
#workaround because cpio fails to compress broken links sometimes
exec touch dev/platform_info
cd genode
exec ln -s ../dev/platform_info platform_info
cd ..
exec -ignorestderr echo "genode/platform_info" | [installed_command cpio] -o -A -H newc -O initrd
cd ${here}
#workaround because cpio fails to compress broken links sometimes
exec touch dev/platform_info
cd genode
exec ln -s ../dev/platform_info platform_info
cd ..
exec -ignorestderr echo "genode/platform_info" | [installed_command cpio] -o -A -H newc -O initrd
cd ${here}
}
source [genode_dir]/tool/run/depot.inc