diff --git a/bin/os b/bin/os index 8790395..176ac3d 100755 Binary files a/bin/os and b/bin/os differ diff --git a/flake.nix b/flake.nix index 93b0572..c59284e 100644 --- a/flake.nix +++ b/flake.nix @@ -16,7 +16,8 @@ pkgs.clang pkgs.gcc pkgs.gnumake - pkgs.nasm + pkgs.mtools + pkgs.gptfdisk ]; }; }; diff --git a/image.hdd b/image.hdd index b879f01..2e49f3f 100644 Binary files a/image.hdd and b/image.hdd differ diff --git a/limine b/limine index 7a6892a..e0e61c9 160000 --- a/limine +++ b/limine @@ -1 +1 @@ -Subproject commit 7a6892a36f1fb6dbdd6e6f6d00b8062d5bcb813b +Subproject commit e0e61c946933696453f591da525ab1f8a66a553d diff --git a/limine.sh b/limine.sh index 3172b31..2b18033 100644 --- a/limine.sh +++ b/limine.sh @@ -2,27 +2,27 @@ dd if=/dev/zero bs=1M count=0 seek=64 of=image.hdd # Create a partition table. -, sgdisk image.hdd -n 1:2048 -t 1:ef00 -m 1 +sgdisk image.hdd -n 1:2048 -t 1:ef00 -m 1 -#rm -rf limine +rm -rf limine # Download the latest Limine binary release for the 10.x branch. -#git clone https://codeberg.org/Limine/Limine.git limine --branch=v10.x-binary --depth=1 +git clone https://codeberg.org/Limine/Limine.git limine --branch=v10.x-binary --depth=1 # Build "limine" utility. -#make -C limine +make -C limine # Install the Limine BIOS stages onto the image. ./limine/limine bios-install image.hdd # Format the image as fat32. -, mformat -i image.hdd@@1M +mformat -i image.hdd@@1M # Make relevant subdirectories. -, mmd -i image.hdd@@1M ::/EFI ::/EFI/BOOT ::/boot ::/boot/limine +mmd -i image.hdd@@1M ::/EFI ::/EFI/BOOT ::/boot ::/boot/limine # Copy over the relevant files. -, mcopy -i image.hdd@@1M bin/os ::/boot -, mcopy -i image.hdd@@1M limine.conf limine/limine-bios.sys ::/boot/limine -, mcopy -i image.hdd@@1M limine/BOOTX64.EFI ::/EFI/BOOT -, mcopy -i image.hdd@@1M limine/BOOTIA32.EFI ::/EFI/BOOT +mcopy -i image.hdd@@1M bin/os ::/boot +mcopy -i image.hdd@@1M limine.conf limine/limine-bios.sys ::/boot/limine +mcopy -i image.hdd@@1M limine/BOOTX64.EFI ::/EFI/BOOT +mcopy -i image.hdd@@1M limine/BOOTIA32.EFI ::/EFI/BOOT diff --git a/obj/src/int.c.o b/obj/src/int.c.o index 505fbc1..f0a1663 100644 Binary files a/obj/src/int.c.o and b/obj/src/int.c.o differ diff --git a/obj/src/main.c.o b/obj/src/main.c.o index 3d4f34c..5054645 100644 Binary files a/obj/src/main.c.o and b/obj/src/main.c.o differ diff --git a/src/print.c b/src/print.c index f071bd4..fe8251d 100644 --- a/src/print.c +++ b/src/print.c @@ -4,7 +4,7 @@ #include "../include/limine.h" u32 bg = 0x00000000; -u32 fg = 0xFFFFFFFF; +u32 fg = 0x00030200; static size_t row; static size_t col; static size_t term_width, term_height; @@ -71,7 +71,7 @@ void put(int ch) { for (size_t x = 0; x < TERM_WIDTH; x++) { size_t off = (py + y) * fb_width + (px + x); bool padding = (y == 0 || y == TERM_HEIGHT-1 || x == 0 || x == TERM_WIDTH-1); - fb_scr[off] = ((~glyph & 1) | padding )? bg : (x^y * off + y*term_width); + fb_scr[off] = ((~glyph & 1) | padding )? bg : (x^y * off + y*term_width) * fg; glyph >>= !padding; } }