Dependency-free, suckless bootable disk image creator and boot manager

bzt 31d20593cf More docs 2 weeks ago
distrib 9a39125970 Added partition UUIDs 2 weeks ago
docs 31d20593cf More docs 2 weeks ago
src 9a39125970 Added partition UUIDs 2 weeks ago
.gitignore 23061f9add BSD plugins 1 year ago
LEAME.md e229ccde24 SMP became a built-in feature, no plugin needed 1 month ago
LEGGIMI.md 31d20593cf More docs 2 weeks ago
LICENSE e61c652eb9 Initial commit 1 year ago
LIESMICH.md e229ccde24 SMP became a built-in feature, no plugin needed 1 month ago
LISMOI.md e229ccde24 SMP became a built-in feature, no plugin needed 1 month ago
OLVASSEL.md e229ccde24 SMP became a built-in feature, no plugin needed 1 month ago
PRZECZYTAJ.md 31d20593cf More docs 2 weeks ago
README.md e229ccde24 SMP became a built-in feature, no plugin needed 1 month ago
easyboot.h 9a39125970 Added partition UUIDs 2 weeks ago
ПРОЧТИМЕНЯ.md e229ccde24 SMP became a built-in feature, no plugin needed 1 month ago
リードミー.md 31d20593cf More docs 2 weeks ago
自述文档.md e229ccde24 SMP became a built-in feature, no plugin needed 1 month ago

README.md

Easyboot

Easyboot is an all-in-one boot manager and bootable disk image creator that can load various OS kernels and Multiboot2 compliant kernels in various binary formats.

Easyboot

NOTE: If you're looking for a boot loader, that loads a single kernel only, then take a look at Easyboot's little brother, Simpleboot.

Acknowledgement

This project wouldn't have been possible without the support of Free Software Foundation Hungary. The project was created in appliance of FSF.hu's Free Software Tender 2023.

Advantages over GRUB

  • dependency-free, easy to use, multilingual installer
  • not bloated, it's only about 0.5% of GRUB's size
  • easy to configure, with syntax checker
  • easily patch ACPI tables with user provided DSDT
  • shows a very detailed error screen if kernel goes off at early stage
  • Multiboot2: clean 64-bit entry point (no need to embed tags nor for 32-bit trampoline code in kernel)
  • Multiboot2: support for higher-half kernels
  • Multiboot2: firmware independent, consistent memory map on all platforms
  • Multiboot2: firmware independent, consistent framebuffer on all platforms
  • Multiboot2: the monitor's EDID info also provided
  • Multiboot2: if requested, starts the kernel on all processor cores (SMP support)
  • there's also a plugin to simulate GRUB booting with all its pitfalls and bugs.

Supported kernels: Multiboot1 (ELF32, PE/COFF, a.out; BIOS, UEFI, RPi), Multiboot2 (ELF32, ELF64, PE32+/COFF, a.out; BIOS, UEFI, RPi), Linux (BIOS, UEFI, RPi), Windows (UEFI), OpenBSD (BIOS, UEFI), FreeBSD (BIOS, UEFI), FreeDOS (BIOS), ReactOS (BIOS), MenuetOS 32 / 64 (BIOS, UEFI), KolibriOS (BIOS, UEFI), SerenityOS (BIOS, UEFI), Haiku (BIOS, UEFI)

Supported file systems: FAT12/16/32, exFAT, NTFS (v3, v3.1), ext2/3/4, XFS (SGI), UFS (v2, v4.4), mfs (Minix3), BeFS (Haiku), AXFS (OS/Z)

(When the kernel is located on the boot partition then any file system can be used for root: ZFS, btrfs, etc.)

Rationale

I've created a simple to use boot loader, and users were asking for more and more features. I wanted to keep that boot loader as simple as possible, but FSF.hu offered support, so I've decided to fork it and add all those requested features in this boot manager instead.

This is also a suckless tool like Simpleboot, has no dependencies, and extremely easy to use:

  1. create a directory and put your boot files in it, among other things your menu configuration and the optional plugins
  2. execute the easyboot (source directory) (output image file) command
  3. and... that's about it... nothing else left to do! The image Just Works (TM), it will get your kernels booted!

You can install the boot manager and make an existing device or image bootable; or you can create a bootable image anew. You can boot that image in a VM, or you can write it with dd or USBImager to a storage and boot that on a real machine too.

Simplicity is the ultimate sophistication!

Installation

Just download the binary for your OS. These are portable executables, they don't require installation and they don't need any shared libraries / DLLs.

Furthermore you can find various packaging solutions in the distrib directory (for Debian, Ubuntu, RaspiOS, Gentoo, Arch).

When creating an image then (depending on your configuration) you might also need some plugins in your (source directory). You can find these in the src/plugins directory using the extension plg. When installed from a package, these will be placed under /usr/share/easyboot.

Documentation

The detailed documentation on how to use the bootable disk creator and how a kernel is booted can be found in the docs directory.

Example kernel

If you want to write a kernel that can be loaded without any plugins using Easyboot's simplified Multiboot2 protocol, then take a look at Simpleboot Example Kernel directory. Both loaders use the same boot protocol, that kernel works with Easyboot as-is. You'll see that no Assembly nor embedded tags required, otherwise the source code is 99.9% the same as the example in the Multiboot2 specification (the only difference is, it prints to the serial console and not on the VGA teletype screen, because that latter doesn't exists on UEFI and on RaspberryPi machines).

Compilation

GNU/make needed for orchestration (although it's literally just cc easyboot.c -o easyboot). The toolchain doesn't matter, any ANSI C compiler will do, works on POSIX and WIN32 MINGW too. Just go to the src directory and run make. That's all. Despite of it's small size, it is self-contained and compilation has exactly zero library dependencies. It's not called Easyboot for nothing :-)

To recompile the loaders, you'll need the flatassembler, and LLVM Clang and lld (gcc and GNU ld won't work I'm afraid). But don't worry, I've added all of them to src/data.h as a byte array, so you don't have to compile these unless you really really want to (for that, just delete data.h before you run make).

On the other hand to compile the plugins, you'll have to have a cross-compiler, either LLVM CLang or GNU gcc (x86_64-elf-gcc, aarch64-elf-gcc). The repo includes these as binaries too. To do the recompilation, just delete the src/plugins/*.plg files before running make.

License

Easyboot is Free and Open Source Software, licensed under the terms of GPL version 3 or (at your opinion) any later version. See the LICENSE file for details.

bzt