#bootloader #bios #sector #x86-64-bios

app bootloader-x86_64-bios-boot-sector

BIOS boot sector for the bootloader crate

21 releases

Uses new Rust 2024

new 0.11.14 Jan 13, 2026
0.11.13 Nov 27, 2025
0.11.12 Sep 3, 2025
0.11.10 Feb 10, 2025
0.11.0-beta.4 Nov 27, 2022

#360 in Filesystem

Download history 112/week @ 2025-09-23 121/week @ 2025-09-30 148/week @ 2025-10-07 122/week @ 2025-10-14 98/week @ 2025-10-21 101/week @ 2025-10-28 117/week @ 2025-11-04 80/week @ 2025-11-11 91/week @ 2025-11-18 91/week @ 2025-11-25 117/week @ 2025-12-02 230/week @ 2025-12-09 118/week @ 2025-12-16 146/week @ 2025-12-23 126/week @ 2025-12-30 138/week @ 2026-01-06

642 downloads per month

MIT/Apache

11KB
252 lines

First Stage: Bootsector

This executable needs to fit into the 512-byte boot sector, so we need to use all kinds of tricks to keep the size down.

Build Commands

  1. cargo build --profile=stage-1 -Zbuild-std=core --target ../../i386-code16-boot-sector.json -Zbuild-std-features=compiler-builtins-mem
  2. objcopy -I elf32-i386 -O binary ../../target/i386-code16-boot-sector/stage-1/bootloader-x86_64-bios-boot-sector ../../target/disk_image.img

To run in QEMU:

  • qemu-system-x86_64 -drive format=raw,file=../../target/disk_image.img

To print the contents of the ELF file, e.g. for trying to bring the size down:

  • objdump -xsdS -M i8086,intel ../../target/i386-code16-boot-sector/stage-1/bootloader-x86_64-bios-boot-sector

No runtime deps