Proka Bootloader - The bootloader of ProkaOS
Copyright (C) 2026 RainSTR Studio. All rights reserved.
Introduction
This is the main repository of the proka-bootloader, which contains the bootloader code (including BIOS and UEFI), and the library to help you parse the info easily.
This project is written in Rust, so you can use it through cargo add proka-bootloader and look for docs on Docs.rs.
How to use
Here, we'd like to introduce the usage of this bootloader.
Build the bootloader code
To build the bootloader, you shall install these components:
- NASM: For the bootloader code written in assembly;
- GCC: For the bootloader code written in C;
- Nightly Rust: For the bootloader code written in Rust;
- Make: To build the code
For nightly Rust, you should install these components and targets:
rust-src: To rebuild the core crate;x86_64-unknown-none: To generate the bare code;x86_64-unknown-uefi: To generate UEFI code;
Here's the example command that helps you install them:
# Debian/Ubuntu
# Arch Linux
# After installing rustup...
After installing these, go to the project root, run:
# If you want to build both BIOS and UEFI...
# If build BIOS only...
# If build UEFI only...
The assets will put in output/ in project root.
NOTE: The file pkldr is the stage2/3/4 file and MUST put into root; The partition must be FAT32 and with type 0x91!
If you want to install it to your disk, follow this file structures:
/mnt/
├── EFI
│ └── Boot
│ └── bootx64.efi
├── initprt.img
├── NvVars
├── pkldr
└── proka-kernel
Use this as a crate
- Do this command in your project root:
cargo add proka-bootloader
- Write the following example code:
use BootInfo;
use PanicInfo;
// Panic handler
!
pub extern "C" !
// Test runner
- Build your project
Run this command: cargo build --target x86_64-unknown-none
Contributing
Thank you to all contributors!
- zhangxuan2011 zx20110412@outlook.com
How to contribute
We welcome your contributions: Bug reports, Pull Requests (features, fixes, optimizations), documentation improvements, and feedback.
Also don't forget to add your name to Contributors List! :)
License
This project is under license GPL-v3, and you should follow this license during contributing.
See LICENSE for more details.