From 316134caf81fc749967199167c922a29a3e8cce0 Mon Sep 17 00:00:00 2001 From: Adrian-Ken Rueegsegger Date: Fri, 18 Dec 2015 13:09:39 +0100 Subject: [PATCH] run: Add iPXE support to hw --- tool/run/boot_dir/hw | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/tool/run/boot_dir/hw b/tool/run/boot_dir/hw index 0098172e7..a5dc4dde6 100644 --- a/tool/run/boot_dir/hw +++ b/tool/run/boot_dir/hw @@ -207,6 +207,30 @@ proc run_boot_dir {binaries} { generate_tftp_config } + if {[have_spec x86] && [have_include "load/ipxe"]} { + # + # Generate iPXE config file + # + set fh [open "[run_dir]/boot.cfg" "WRONLY CREAT TRUNC"] + puts $fh "#!ipxe" + + if {[have_spec "muen"]} { + puts $fh "kernel image.bin" + } else { + puts $fh "kernel boot/bender" + puts $fh "module image.elf" + + # + # Install bender + # + install_bender_to_run_dir + } + puts $fh "boot" + close $fh + + update_ipxe_boot_dir + } + # retrieve stand-alone core exec cp $core_target/$core_bin.standalone bin/$core_bin exec rm $core_target/$core_bin.standalone