mirror of
https://github.com/genodelabs/genode.git
synced 2025-03-15 08:41:01 +00:00
Renaming 'get_cmd_switch' and 'get_cmd_arg' to 'have_cmd_arg' and 'cmd_arg' respectively blends in nicely with the now omnipresent pattern with 'have_[spec|board|installed|include]'. This commit deprecates 'get_cmd_switch' and 'get_cmd_arg', which will be removed in a later commit. Issue #5432
41 lines
816 B
PHP
41 lines
816 B
PHP
set qemu_spawn_id ""
|
|
set qemu_args [cmd_arg --qemu-args ""]
|
|
|
|
|
|
#
|
|
# Enable run scripts to extend 'qemu_arg' via 'append' without bothering
|
|
# about the required whitespace in front of the custom arguments.
|
|
#
|
|
append qemu_args " "
|
|
|
|
|
|
proc qemu_args { } {
|
|
global qemu_args
|
|
return $qemu_args
|
|
}
|
|
|
|
proc append_qemu_nic_args { { extra_netdev_args "" } } {
|
|
global qemu_args
|
|
append qemu_args " -netdev user,id=net0"
|
|
|
|
if { $extra_netdev_args ne "" } {
|
|
append qemu_args ",$extra_netdev_args"
|
|
}
|
|
}
|
|
|
|
|
|
##
|
|
# Check whether Qemu support is available
|
|
#
|
|
proc is_qemu_available { } {
|
|
set qemu_args_file [file join "board" [board] "qemu_args"]
|
|
|
|
set repo [repository_contains $qemu_args_file]
|
|
|
|
if {$repo == ""} {
|
|
puts stderr "skipping execution because platform is not supported by qemu"
|
|
return false
|
|
}
|
|
return true
|
|
}
|