From bffddd7e15f24cd5e58b0d53b8153c7a23c91e36 Mon Sep 17 00:00:00 2001 From: Adrian-Ken Rueegsegger Date: Fri, 21 Aug 2015 18:12:42 +0200 Subject: [PATCH] tool: Extend hw boot_dir script to support Muen SK build --- tool/run/boot_dir/hw | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/tool/run/boot_dir/hw b/tool/run/boot_dir/hw index f3375781e..0098172e7 100644 --- a/tool/run/boot_dir/hw +++ b/tool/run/boot_dir/hw @@ -145,20 +145,14 @@ proc run_boot_dir {binaries} { # offer ELF image set elf_img "[run_dir]/image.elf" - # Use raw binary object for base-hw on Muen - if {[have_spec "muen"]} { - set raw_img "[run_dir]/image.raw" - exec [cross_dev_prefix]objcopy -O binary bin/$core_bin $raw_img - exit 0 - } - - if {[have_spec "x86_64"] && ![have_spec "muen"]} { + if {[have_spec "x86_64"]} { # as startup is done in 32 bit mode, GRUB expects a 32 bit image exec [cross_dev_prefix]objcopy -O elf32-i386 bin/$core_bin $elf_img } if {[expr [have_spec "arm"] || [have_spec "x86_32"]]} { exec cp -L bin/$core_bin $elf_img } + exec [cross_dev_prefix]strip $elf_img if {[have_include "image/iso"] || [have_include "image/disk"]} { @@ -173,9 +167,15 @@ proc run_boot_dir {binaries} { set fh [open "[run_dir]/boot/grub/menu.lst" "WRONLY CREAT TRUNC"] puts $fh "timeout 0" puts $fh "default 0" - puts $fh "\ntitle Genode on base-hw" - puts $fh " kernel /boot/bender" - puts $fh " module /image.elf" + + if {[have_spec "muen"]} { + puts $fh "\ntitle Genode on base-hw/Muen SK" + puts $fh " kernel /image.bin" + } else { + puts $fh "\ntitle Genode on base-hw" + puts $fh " kernel /boot/bender" + puts $fh " module /image.elf" + } close $fh } @@ -190,7 +190,7 @@ proc run_boot_dir {binaries} { } } - if {[have_spec x86] && [have_include "load/tftp"]} { + if {[have_spec x86] && ![have_spec muen] && [have_include "load/tftp"]} { # # Install PXE bootloader pulsar #