diff --git a/.gitignore b/.gitignore index 9559470..b9a6d43 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,5 @@ build cmake-build-debug noxos.log -ramdisk/shell.elf \ No newline at end of file +ramdisk/shell.elf +ramdisk/*.nxkm \ No newline at end of file diff --git a/build.sh b/build.sh index d8d21e8..8a9db36 100755 --- a/build.sh +++ b/build.sh @@ -43,13 +43,21 @@ kernel_build() { } libnx_build() { - cd ../libnx + cd ../libraries/libnx bash build.sh - cd ../kernel + cd ../../kernel +} + +libnxdrv_build() { + cd ../libraries/libnxdrv + bash build.sh + cd ../../kernel } shell_build() { - gcc shell.c -o ramdisk/shell.elf -nostdlib -nolibc -fno-stack-protector -I../libnx/inc ../libnx/build/cmake/libnx.so + echo " --> Building shell" +# gcc shell.c -o ramdisk/shell.elf -nostdlib -nolibc -fno-stack-protector -I../libraries/libnx/inc/public ../libraries/libnx/build/cmake/libnx.so + gcc test_driver.c -o ramdisk/test_driver.nxkm -nostdlib -nolibc -I../libraries/libnxdrv/inc -L../libraries/libnxdrv/build -lnxdrv } @@ -109,6 +117,7 @@ case $1 in kernel_build [ ! -d "build/limine" ] && limine_install libnx_build + libnxdrv_build shell_build generate_initial_ramdisk generate_image diff --git a/ramdisk/noxos.json b/ramdisk/noxos.json index 22fe65e..ad44cc4 100644 --- a/ramdisk/noxos.json +++ b/ramdisk/noxos.json @@ -1,6 +1,6 @@ { "PS2_ACPI_VALIDATION": true, - "LOG_GRAPHICAL": false, + "LOG_GRAPHICAL": true, "modules": { "FAT32": "/initrd/modules/fat32.nxkm" diff --git a/test_driver.c b/test_driver.c new file mode 100644 index 0000000..b78feba --- /dev/null +++ b/test_driver.c @@ -0,0 +1,7 @@ +#include "libnxdrv.h" + +int main() { + nx_drv_init(); + + return 0; +} \ No newline at end of file