Self-made Kernel
This project consists in building my own minimal kernel. It starts following this site.
This version allow to build a simple bootable 32-bit kernel that will print a phrase (here it is Welcome to my Kernel) and allow keyboard input.
To build this project you need some tools :
- Linux
- nasm (to compile assembly)
- gcc (to compile your main function)
- ld (to link your files)
- qemu (to test your kernel)
- make
Note that make is optional, it is of course possible to manually write each command. But it will become really exhausting while the project is getting bigger.
Note also that using qemu is not necessary but it is a good and lightweight solution to test your kernel. You can use another virtualizer or even test it directly on a computer (as long as you know what you are doing).
On OSX you can use the shell script to build a cross-compiler for this project.
The following command will build a kernel executable called kernel.
make
You can test your kernel with Qemu running the following command.
qemu-system-i386 -kernel kernel