Working kernel written on C and userspace-ready #1

Merged
sonya merged 61 commits from dev into main 2026-05-03 09:13:20 +00:00
Showing only changes of commit a05b51fca3 - Show all commits
+30 -27
View File
@@ -67,44 +67,47 @@ _prep:
@mcopy -i {{IMG_FILE}} {{BOOT_BIN}} ::/EFI/BOOT/BOOTAA64.EFI @mcopy -i {{IMG_FILE}} {{BOOT_BIN}} ::/EFI/BOOT/BOOTAA64.EFI
@mcopy -i {{IMG_FILE}} {{BUILD_DIR}}/Kernel/ksOSKernel.elf ::/ksOSKernel.elf @mcopy -i {{IMG_FILE}} {{BUILD_DIR}}/Kernel/ksOSKernel.elf ::/ksOSKernel.elf
@run: _image
@echo "🚀 Launching (accel: {{ACCEL_INFO}})..."
qemu-system-aarch64 {{ACCEL}} \
-machine virt,acpi=off \
-cpu {{CPU}} \
-m {{RAM}} \
-device ramfb \
{{DISPLAY_FLAGS}} \
-drive if=pflash,format=raw,readonly=on,file={{OVMF_ARM}} \
-drive file={{IMG_FILE}},format=raw,if=none,id=hd0 \
-device virtio-blk-device,drive=hd0 \
-serial stdio \
-monitor telnet:127.0.0.1:5555,server,nowait
@drun: _image run *FLAGS:
@echo "🚀 Debugging (accel: {{ACCEL_INFO}})..." #!/usr/bin/env bash
set -e
FLAGS=" {{FLAGS}} "
if [[ "$FLAGS" == *" -clean "* ]]; then
echo "🧹 Cleaning..."
just clean
fi
just _image
DEBUG_ARGS=""
DISPLAY_ARGS="{{DISPLAY_FLAGS}}"
STATE_MSG="Launching"
if [[ "$FLAGS" == *" -debug "* ]]; then
DEBUG_ARGS="-s -S"
STATE_MSG="Debugging"
fi
if [[ "$FLAGS" == *" -nographic "* ]]; then
DISPLAY_ARGS="-nographic"
fi
echo "🚀 $STATE_MSG (accel: {{ACCEL_INFO}})..."
qemu-system-aarch64 {{ACCEL}} \ qemu-system-aarch64 {{ACCEL}} \
-machine virt,acpi=off \ -machine virt,acpi=off \
-cpu {{CPU}} \ -cpu {{CPU}} \
-m {{RAM}} \ -m {{RAM}} \
-device ramfb \ -device ramfb \
{{DISPLAY_FLAGS}} \ $DISPLAY_ARGS \
-drive if=pflash,format=raw,readonly=on,file={{OVMF_ARM}} \ -drive if=pflash,format=raw,readonly=on,file={{OVMF_ARM}} \
-drive file={{IMG_FILE}},format=raw,if=none,id=hd0 \ -drive file={{IMG_FILE}},format=raw,if=none,id=hd0 \
-device virtio-blk-device,drive=hd0 \ -device virtio-blk-device,drive=hd0 \
-serial stdio \ -serial stdio \
-monitor telnet:127.0.0.1:5555,server,nowait \ -monitor telnet:127.0.0.1:5555,server,nowait \
-s -S $DEBUG_ARGS
@crun:
@echo "🧹 Cleaning and running.."
just clean
just run
@dcrun:
@echo "🧹 Cleaning and debugging.."
just clean
just drun
@clean: @clean:
just Bootloader clean just Bootloader clean