An educational kernel built completely from scratch to explore low-level systems programming, memory management, interrupts, scheduling, and hardware interaction.
- QEMU - An open-source emulator that allows you to run the kernel in a virtual environment.
- GCC - The GNU Compiler Collection, used to compile the kernel code.
- i686-elf-gcc - A cross-compiler for the i686 architecture, used to compile the kernel code for the target architecture.
- NASM - The Netwide Assembler, used for assembling low-level assembly code.
- GCC - The GNU Compiler Collection, used to compile the kernel code.
- Make - A build automation tool that simplifies the compilation process.
- GDB - The GNU Debugger, used for debugging the kernel during development.
- PWNdbg - A TUI debugger for GDB, providing an enhanced debugging experience.
.
├── conf.gdb
├── Dockerfile
├── linker.ld
├── Makefile
├── README.md
├── bin/
├── build/
├── docs/
├── includes/
│ ├── kernel.h
│ ├── panic.h
│ ├── timer.h
│ ├── driver/
│ ├── interrupt/
│ ├── lib/
│ └── utils/
├── scripts/
│ └── requirements.sh
├── src/
│ ├── bootloader/
│ ├── driver/
│ ├── interrupt/
│ ├── kernel/
│ ├── libs/
│ └── utils/
└── test/
To install all the required tools, you can use the following commands:
-
if u'r using Linux:
sh ./scripts/install.sh
-
if u'r using Windows: (shame on you)
- Uninstall windows
- Install linux
- Run the above command
- clone the repository and navigate to the project directory:
git clone https://github.com/Ox03bb/kernel-from-scratch.git
cd kernel-from-scratch- install the required tools using the provided script:
sh ./scripts/install.sh- build the kernel using the Makefile:
make setup # to setup the build environment(build docker image...etc) && build the kernel
# or
make build # if u'r already setup the build environment- run the kernel in QEMU:
make run