An x86_64 kernel.
  • C 91.9%
  • Assembly 3.4%
  • Makefile 2.8%
  • Shell 1.9%
Find a file
2026-03-25 10:06:07 +09:00
kernel Initrd seek 2026-03-25 10:05:00 +09:00
libc Libc syscall helpers now in plain asm 2026-03-08 22:52:30 +09:00
userspace Basic sleep and nanosleep syscalls 2026-03-08 00:48:11 +09:00
.clang-format Run clang-format 2025-11-18 09:11:29 +09:00
.gitignore Basic scheduler locking 2026-01-15 21:04:02 +09:00
.vimspector.json Put builds in dedicated arch/build type directories 2025-11-18 09:46:53 +09:00
build.sh Remove elf file from boot modules 2026-03-23 13:02:50 +09:00
build_initrd.sh Implement basic readdir (& some minor cleanup) 2026-03-23 23:30:11 +09:00
clean.sh Add initrd tar image builder 2026-03-18 19:09:53 +09:00
config.sh Exit syscall 2026-03-08 00:12:47 +09:00
default_host.sh Working kernel with libk printf 2025-05-04 00:29:24 +09:00
headers.sh Working kernel with libk printf 2025-05-04 00:29:24 +09:00
LICENSE Add MIT license and basic readme 2025-07-11 19:50:01 +09:00
limine.conf A working TTY with scrolling 2025-10-23 21:00:09 +09:00
make_iso.sh Remove elf file from boot modules 2026-03-23 13:02:50 +09:00
README.md Fix todos in logger 2026-02-15 22:07:27 +09:00
run_virtual.sh Exit syscall 2026-03-08 00:12:47 +09:00
target_triplet_to_arch.sh WIP: more work on booting with Limine 2025-10-17 09:58:55 +09:00

Hojicha

This project is a first effort at developing an operating system for the x86_64 platform. Thanks for checking it out!

Caution: Hojicha is very much a work in progress. It is very incomplete, and likely has many bugs. Please do not try to install it on real hardware - I'm not responsible for what happens if you do.

Current Status

Under (early) active development.

Current Goal:

Executable loading and first steps into userspace

MVP Done:

  • Boot hello world
  • Basic TTY output
  • Serial debug logs
  • GDT
  • IDT, simple PIC driver
  • Timer interrupts
  • Keyboard input
  • Physical memory manager
  • Virtual memory manager (paging)
  • Basic malloc()/free()
  • Framebuffer TTY
  • Migrate to x86_64
  • Round robin scheduling

If you're reading this and you have feedback, please don't hesitate to let me know!

Building & Running:

Prerequisites

  • GCC cross-compiler targeting x86_64 ELF - there are good instructions for this at https://wiki.osdev.org/GCC_Cross-Compiler. I personally am building with v15.2.0 - other versions should work as well, but no guarantees.
  • NASM
  • Xorriso
  • QEMU - Other emulators likely work as well, but the build/run scripts are built around using QEMU for emulation.

It then should be as simple as ./run_virtual.sh from the project root - see below for notes on build flags.

Build Flags

  • You can set the default kernel log level by passing --hlog-level=INFO (or WARN, ERROR, FATAL, DEBUG, VERBOSE) to ./build.sh or ./run_virtual.sh.
  • You can enable debugging via QEMU by passing --debug-qemu to ./build.sh and ./run_virtual.sh.