OSDev.org

The Place to Start for Operating System Developers
It is currently Sat Sep 23, 2023 9:09 am

All times are UTC - 6 hours




Post new topic Reply to topic  [ 2 posts ] 
Author Message
 Post subject: Simpleboot, a suckless GRUB alternative
PostPosted: Thu Jul 20, 2023 7:15 am 
Offline

Joined: Thu Jul 20, 2023 6:51 am
Posts: 1
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:
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


Top
 Profile  
 
 Post subject: Re: Simpleboot, a suckless GRUB alternative
PostPosted: Tue Sep 12, 2023 2:50 am 
Offline

Joined: Sat Jan 28, 2023 11:41 am
Posts: 20
Location: Belarus
Thanks! You helped me with my raspberry.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC - 6 hours


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group