MoleculeOS is a minimalist, text-based i386 monolithic operating system, developed in C++ as a hobby project.
The goal of this project is to create a clearly structured, modular learning and experimentation system that makes the fundamental building blocks of an operating system understandable and transparent - hence the name MoleculeOS.
- Minimal 32‑bit kernel in C++
- VGA text mode output
- Basic hardware initialization
- Interrupt Descriptor Table (IDT)
- Global Descriptor Table (GDT)
- Simple endless-loop scheduling
- simple ATA-PIO-driver
- block-allocator System Heap
- PS/2 Keyboard input
- Shell Interpreter
- Simple Terminal
- grub Boot-Setup
- custom direct RAM flat file-system
- central APIs for all components
- strict separation between architecture-specific and non-architecture-specific code
MoleculeOS is intentionally simple:
- no paging
- no multitasking
- no 64‑bit mode
- no complex drivers
The goal is to understand the essence of OS development without unnecessary complexity.
Below is the current state of MoleculeOS running in QEMU:
Below is the current state of MoleculeOS running in QEMU (deliberately triggered panic with a division by 0):
To build and run MoleculeOS, the following software is required:
- Grub (for the Boot setup and configurations)
- NASM (Netwide Assembler for assembling the Bootloader and Assembly Files in the Kernel)
- Clang++ (for compiling the 32‑bit kernel and the C++ runtime, requires i386 target support)
- Clang (for compiling the C Runtime and C components in the Kernel, requires i386 target support)
- Make (for Building and running the Project)
- ld.lld (for the linking)
- QEMU (for running the OS in a virtual machine)
- WSL (Windows Subsystem for Linux, if you work under Windows) (for using Grub and run Shell Scripts)
CTRL + SHIFT + B chmod +x build.sh
./tools/build.shThis will:
- assemble the bootloader
- compile the kernel
- compile the runtime
- build a
.isoFile - launch QEMU


