Skip to content
jmcddn edited this page Oct 17, 2012 · 12 revisions

To build ebbos for baremetal, you can now pass the --enable-baremetal flag at configure time.

x86_64

Everything else will work as before, except now the application binaries will be multiboot compatible binaries. These binaries can be packaged up however (floppy, iso, tftpboot, etc.). I've created a target to build an iso with grub on it to boot:

make apps/helloworld/helloworld.iso

I can now boot this iso with, for example, qemu or bochs: sudo qemu -cpu host -s -cdrom apps/helloworld/helloworld.iso -nographic

Output goes via serial, and with the qemu nographic flag, it outputs serial to stdout ('ctrl+a', 'c' to drop into the monitor, at which point the 'q' command will quit).

I've also installed two versions of bochs on kd. One version, 'bochs' will drop into the bochs debugger, hit c to continue and let it run. The other version is 'bochs-gdb' and it has a gdb-stub so we can attach to it. See contrib/dschatz/bochs/bochsrc.txt for an example bochsrc.

powerpc

Building on the Surveyor login nodes is a bit tricky:
PATH=$PATH:/bgsys/drivers/ppcfloor/gnu-linux/bin

CC=powerpc-bgp-linux-gcc CXX=powerpc-bgp-linux-g++ ../EBBlib/configure --build=powerpc64-unknown-linux --host=powerpc-unknown-linux --enable-baremetal --enable-simple-prim-alloc

The binaries will now be ELF files, you can package them up for uboot (for kittyhawk):

make apps/helloworld/helloworld.uimage

This can now be passed as a kernel to the kittyhawk infrastructure.

Clone this wiki locally