Simpleboot, a suckless GRUB alternative

This forums is for OS project announcements including project openings, new releases, update notices, test requests, and job openings (both paying and volunteer).
Post Reply
simpleboot
Posts: 1
Joined: Thu Jul 20, 2023 6:51 am

Simpleboot, a suckless GRUB alternative

Post by simpleboot »

Hi OSDevers,

I've created a simple boot loader in the spirit of suckless.org. I got fed up how difficult it is to use grub-install, and how much dependencies grub-mkrescue has. So I created a dependency-free tool (portable executable available on Windows and Linux as well), a single command which can create a bootable disk image with ease or make existing images or actual devices bootable. Free and Open Source, MIT licensed.

Simpleboot

Usage:

Code: Select all

simpleboot (input directory) (output image file)
That's all. It takes the contents of the given directory and constructs an image file from them that then can be booted on UEFI machines as well as on legacy BIOS systems. No further steps required, and it is totally dependency-free (neither mtools nor root privilege required, it Just Works). Command line tool's manual can be found here.

Supported kernel formats:
  • ELF (32-bit CDECL, 64-bit SysV ABI with Multiboot2 protocol)
  • COFF/PE32+ (32-bit CDECL, 64-bit MS fastcall ABI with Multiboot2 protocol)
  • Linux kernel (x86 boot protocol)
The Multiboot2 protocol is the same as grub's, but simpler and more featureful (and yet, still backward compatible): there's no need for embedded data (it uses a plain test file instead), and it is also capable of loading higher-half (upper-half) kernels, and passes the MBI to your entry point using standard ABI for your kernel format. The full boot protocol specification can be found here.

Minimal example kernels are provided in the repo, the Multiboot2 version is almost 100% the same as in the Multiboot2 spec, but it prints the info on the serial console and not as VGA text (Simpleboot sets up the framebuffer for you). There's also a Linux kernel mock up example, in case you want to support the Linux boot protocol in your kernel. Makfile rules to boot under qemu (UEFI and BIOS) and bochs (BIOS) also provided.

Cheers
Alexey1994
Member
Member
Posts: 61
Joined: Sat Jan 28, 2023 11:41 am
Location: Belarus
Contact:

Re: Simpleboot, a suckless GRUB alternative

Post by Alexey1994 »

Thanks! You helped me with my raspberry.
alecco
Posts: 6
Joined: Sat Jun 08, 2019 4:36 am

Re: Simpleboot, a suckless GRUB alternative

Post by alecco »

I was looking for a fast and simple bootloader for a bare metal cloud/server kernel.
No more being annoyed with sudo prompts to make disk images.
And most of the code is readable C instead of assembly.
This is brilliant.
Thanks.
Post Reply