Skip to content

UEFI Boot & Real Hardware

MerlionOS supports UEFI boot via the Limine bootloader, enabling it to run on real x86_64 hardware — not just QEMU.

  • macOS or Linux build machine
  • Rust nightly toolchain (via rustup)
  • xorriso — ISO creation tool
  • QEMU (optional, for testing before real hardware)
Terminal window
brew install xorriso qemu
Terminal window
sudo apt install xorriso qemu-system-x86 ovmf

MerlionOS has two build targets:

TargetBoot MethodUse Case
make buildBIOS (bootloader 0.9)QEMU development
make isoUEFI (Limine)Real hardware & UEFI QEMU
Terminal window
git clone https://github.com/MerlionOS/merlion-kernel.git
cd merlion-kernel
make iso

This will:

  1. Clone the Limine bootloader (v8.x) automatically
  2. Build the kernel as a standard ELF binary for Limine
  3. Create merlionos.iso — a hybrid BIOS+UEFI bootable ISO

Before writing to USB, test in QEMU with UEFI firmware:

Terminal window
make run-uefi-mac
Terminal window
make run-uefi

You should see serial output showing all subsystems initializing:

[limine] _start reached!
MerlionOS v77.0.0 — Born for AI. Built by AI.
[limine] HHDM offset: 0xffff800000000000
[limine] Memory map: 37 entries
[limine] Total usable: 245 MiB
[limine] Framebuffer: 1280x800 bpp=32
[ok] GDT loaded
[ok] IDT + interrupts enabled
[ok] Heap ready (64K)
[e1000e] MAC: 52:54:00:12:34:56
[ok] Hardware drivers
[ok] Security + logging
[ok] Network services
[ok] AI platform
[ok] All subsystems initialized
Terminal window
# 1. Identify your USB device
diskutil list
# 2. Unmount the USB drive (replace disk2 with your device)
diskutil unmountDisk /dev/disk2
# 3. Write the ISO (use rdisk for faster writes)
sudo dd if=merlionos.iso of=/dev/rdisk2 bs=4M status=progress
# 4. Eject
diskutil eject /dev/disk2
Terminal window
# 1. Identify your USB device
lsblk
# 2. Write the ISO (replace sdX with your device)
sudo dd if=merlionos.iso of=/dev/sdX bs=4M status=progress && sync

Use Rufus:

  1. Select merlionos.iso
  2. Choose DD Image mode (not ISO mode)
  3. Select your USB drive
  4. Click Start
  1. Disable Secure Boot:

    • Power on → Press F10 for BIOS Setup
    • Navigate to SecuritySecure Boot Configuration
    • Set Secure Boot to Disabled
    • Save and exit
  2. Boot from USB:

    • Insert the USB drive
    • Power on → Press F9 for Boot Menu
    • Select your USB device (usually shows as “UEFI: USB…”)
    • MerlionOS will boot via Limine
BrandBIOS KeyBoot Menu Key
HPF10F9
DellF2F12
LenovoF1 / Fn+F1F12
ASUSDel / F2F8 / Esc
AcerF2 / DelF12
MSIDelF11
  1. Disable Secure Boot in BIOS/UEFI settings
  2. Ensure UEFI boot mode is enabled (not Legacy/CSM)
  3. Set USB as first boot priority, or use the boot menu

On successful boot, you’ll see:

  • Serial output (if connected via COM port or USB-serial adapter)
  • Framebuffer display — MerlionOS uses the UEFI GOP framebuffer for graphics output. The resolution is set by the UEFI firmware (typically the display’s native resolution).
  • Login prompt — Enter username root (default password is empty, just press Enter)
  • Shell — Type help for available commands
BIOS Boot (QEMU default):
bootloader 0.9 → bootimage → kernel_main(BootInfo)
UEFI Boot (Limine):
UEFI firmware → BOOTX64.EFI (Limine) → kernel.elf → _start()
→ reads HHDM, memory map, framebuffer from Limine responses
→ initializes all 243 modules
→ login → shell

→ Secure Boot is still enabled. Disable it in BIOS.

→ MerlionOS outputs to serial (COM1) first. Connect a serial adapter, or try a different display output.

Limine shows menu but kernel doesn’t load

Section titled “Limine shows menu but kernel doesn’t load”

→ Check that limine.conf is at /boot/limine.conf on the USB drive, and kernel.elf is at /boot/kernel.elf.

→ Some laptops need USB legacy support enabled in BIOS. MerlionOS uses PS/2 keyboard by default; USB keyboard support via xHCI is available but may not work on all hardware.

The boot configuration is in limine.conf:

timeout: 3
/MerlionOS
protocol: limine
kernel_path: boot():/boot/kernel.elf

You can add kernel command line arguments:

/MerlionOS
protocol: limine
kernel_path: boot():/boot/kernel.elf
kernel_cmdline: serial=on loglevel=debug