Skip to content

Instantly share code, notes, and snippets.

@robinsmidsrod
Created November 20, 2019 14:55
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save robinsmidsrod/db381ed90ee602bfefbcca823e25ac2c to your computer and use it in GitHub Desktop.
Save robinsmidsrod/db381ed90ee602bfefbcca823e25ac2c to your computer and use it in GitHub Desktop.
How to build iPXE VirtualBox ROM that fits into 56KB
make_vbox() {
pushd "$HOME/src/forked/ipxe/src" >/dev/null &&
make CONFIG=vbox bin/intel--virtio-net--pcnet32.isarom && #EMBED=config/vbox/embedded.ipxe &&
echo "Max size of VirtualBox ROM is 56KB, 57344 bytes" &&
ls -l bin/intel--virtio-net--pcnet32.isarom &&
prefix=$(date +%Y%m%d-%H%M%S) &&
mkdir -p /ipxe/$prefix &&
cp -v bin/intel--virtio-net--pcnet32.isarom /ipxe/$prefix/ &&
echo -e "@echo off\r\nvboxmanage setextradata global VBoxInternal/Devices/pcbios/0/Config/LanBootRom C:\\Programs\\iPXE\\$prefix\\intel--virtio-net--pcnet32.isarom\r\nvboxmanage getextradata global enumerate\r\n" >/ipxe/setvboxrom.bat &&
popd >/dev/null
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment