Skip to content

Commit

Permalink
fix: OVMF rom and variables
Browse files Browse the repository at this point in the history
  • Loading branch information
kroese authored Feb 4, 2024
1 parent 5e79358 commit 9de3053
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/boot.sh
Original file line number Diff line number Diff line change
Expand Up @@ -41,14 +41,12 @@ if [[ "${BOOT_MODE,,}" != "legacy" ]] && [[ "${BOOT_MODE,,}" != "windows_legacy"

if [ ! -f "$DEST.rom" ]; then
[ ! -f "$OVMF/$ROM" ] && error "UEFI boot file ($OVMF/$ROM) not found!" && exit 44
dd if=/dev/zero "of=$DEST.rom" bs=1M count=4 status=none
dd "if=$OVMF/$ROM" "of=$DEST.rom" conv=notrunc status=none
cp "$OVMF/$ROM" "$DEST.rom"
fi

if [ ! -f "$DEST.vars" ]; then
[ ! -f "$OVMF/$VARS" ] && error "UEFI vars file ($OVMF/$VARS) not found!" && exit 45
dd if=/dev/zero "of=$DEST.vars" bs=1M count=4 status=none
dd "if=$OVMF/$VARS" "of=$DEST.vars" conv=notrunc status=none
cp "$OVMF/$VARS" "$DEST.vars"
fi

if [[ "${BOOT_MODE,,}" != "uefi" ]]; then
Expand Down

0 comments on commit 9de3053

Please sign in to comment.