From 4b930236c7fd413b6240357f8410fe385f7090c3 Mon Sep 17 00:00:00 2001 From: Alex Date: Sun, 6 Aug 2023 04:55:00 +0300 Subject: [PATCH] Update OS --- Fennix Kernel.code-workspace | 10 +++++++++- Fennix Userspace.code-workspace | 4 +++- Kernel | 2 +- Makefile | 2 ++ Makefile.conf | 16 +++++++--------- Userspace | 2 +- initrd/etc/group | 1 + initrd/etc/passwd | 1 + tools/grub.cfg | 4 ++-- tools/limine.cfg | 24 +++++++----------------- 10 files changed, 34 insertions(+), 32 deletions(-) create mode 100644 initrd/etc/group create mode 100644 initrd/etc/passwd diff --git a/Fennix Kernel.code-workspace b/Fennix Kernel.code-workspace index bf064afb..6b5f4e4b 100644 --- a/Fennix Kernel.code-workspace +++ b/Fennix Kernel.code-workspace @@ -38,7 +38,14 @@ "syscalls.h": "c", "cmath": "cpp", "typeinfo": "c", - "exception": "cpp" + "exception": "cpp", + "errno.h": "c", + "float.h": "c", + "mutex": "cpp", + "type_trails": "cpp", + "utility": "cpp", + "algorithm": "cpp", + "functional": "cpp" }, "cSpell.words": [ "AABBCC", @@ -129,6 +136,7 @@ "FAFAFAI", "Fargc", "Fargv", + "fcreat", "fctprintf", "Femto", "FENIXOS", diff --git a/Fennix Userspace.code-workspace b/Fennix Userspace.code-workspace index cd5e748d..f3a94ca7 100644 --- a/Fennix Userspace.code-workspace +++ b/Fennix Userspace.code-workspace @@ -36,7 +36,9 @@ "wait.h": "c", "base.h": "c", "ld.h": "c", - "syscall.h": "c" + "syscall.h": "c", + "stdint.h": "c", + "setjmp.h": "c" }, "cSpell.words": [ "auxv", diff --git a/Kernel b/Kernel index 41db4771..2c51e443 160000 --- a/Kernel +++ b/Kernel @@ -1 +1 @@ -Subproject commit 41db47717374df5bd340e2eeb55f8dbd416e3f45 +Subproject commit 2c51e4432ff3ba3c2223a1925ae640225c3b24fa diff --git a/Makefile b/Makefile index a2a85c9a..0a769816 100644 --- a/Makefile +++ b/Makefile @@ -194,6 +194,8 @@ vscode_debug: build_lynx build_kernel build_userspace build_modules build_image qemu: qemu_vdisk rm -f serial.log profiler.log memtrk.dmp serial4.dmp network.dmp +# touch serial.log +# x-terminal-emulator -e tail -f serial.log & $(QEMU) $(QEMU_UEFI_BIOS) -cpu host $(QEMUFLAGS) $(QEMUHWACCELERATION) $(QEMUMEMORY) $(QEMU_SMP) qemubios: qemu_vdisk diff --git a/Makefile.conf b/Makefile.conf index aa2f967e..4d4e829b 100644 --- a/Makefile.conf +++ b/Makefile.conf @@ -26,8 +26,6 @@ BUILD_MODULES = 1 QUIET_BUILD = 1 -USERSPACE_STATIC_LIBS = 1 - # The path of the cross-compiler. COMPILER_PATH = tools/cross/bin @@ -39,14 +37,14 @@ LIMINE_FOLDER = tools/limine # it will be added automatically depending on the OSARCH) QEMU_PATH = tools/cross/bin/qemu-system- -# Enable mlibc -MLIBC = 0 - - - - - +# Set libc to use. Available options: +# - internal - Use the internal libc +# - musl - Use musl libc (linux syscalls) +# - mlibc - Use mlibc +USE_LIBC = internal +# Build all libraries as static libraries. +USERSPACE_STATIC_LIBS = 0 diff --git a/Userspace b/Userspace index 964d5fa2..2fd23205 160000 --- a/Userspace +++ b/Userspace @@ -1 +1 @@ -Subproject commit 964d5fa2d0a42637253f0877b3256a685412fa65 +Subproject commit 2fd23205dbc32591eb6a1980237fb0b60058e9e6 diff --git a/initrd/etc/group b/initrd/etc/group new file mode 100644 index 00000000..1dbf9013 --- /dev/null +++ b/initrd/etc/group @@ -0,0 +1 @@ +root:x:0: diff --git a/initrd/etc/passwd b/initrd/etc/passwd new file mode 100644 index 00000000..eb85a552 --- /dev/null +++ b/initrd/etc/passwd @@ -0,0 +1 @@ +root:x:0:0:root:/root:/bin/sh diff --git a/tools/grub.cfg b/tools/grub.cfg index 560b62d3..29e4a38d 100644 --- a/tools/grub.cfg +++ b/tools/grub.cfg @@ -4,10 +4,10 @@ set menu_color_normal=white/black set menu_color_highlight=black/light-gray menuentry "Fennix" { - load_video + load_video clear echo "Loading kernel" - multiboot2 /kernel.fsys --alloc=xallocv1 --cores=0 --ioapicirq=1 --tasking=multi --drvdir=/modules --init=/bin/init --ioc=true --udl=true --simd=false --bootanim=false + multiboot2 /kernel.fsys --ioapicirq=1 --linux=false --ioc=true --udl=true --simd=true echo "Loading initrd" module2 /initrd.tar.gz initrd echo "Booting..." diff --git a/tools/limine.cfg b/tools/limine.cfg index 3d1a37c4..aab207a4 100644 --- a/tools/limine.cfg +++ b/tools/limine.cfg @@ -2,21 +2,11 @@ TIMEOUT=1 INTERFACE_BRANDING=Fennix :Fennix (limine) - # DO NOT EDIT! - COMMENT=Boot Fennix using limine protocol - PROTOCOL=limine - KERNEL_CMDLINE=--alloc=xallocv1 --cores=0 --ioapicirq=1 --tasking=multi --drvdir=/modules --init=/bin/init --ioc=true --udl=true --simd=false --bootanim=false - KERNEL_PATH=boot:///kernel.fsys + # DO NOT EDIT! + COMMENT=Boot Fennix using limine protocol + PROTOCOL=limine + KERNEL_CMDLINE=--ioapicirq=1 --linux=false --ioc=true --udl=true --simd=true + KERNEL_PATH=boot:///kernel.fsys - MODULE_PATH=boot:///initrd.tar.gz - MODULE_CMDLINE=initrd - -:Fennix (multiboot2) - # DO NOT EDIT! - COMMENT=Boot Fennix using multiboot2 protocol - PROTOCOL=multiboot2 - KERNEL_CMDLINE=--alloc=xallocv1 --cores=0 --ioapicirq=1 --tasking=multi --drvdir=/modules --init=/bin/init --ioc=true --udl=true --simd=false --bootanim=false - KERNEL_PATH=boot:///kernel.fsys - - MODULE_PATH=boot:///initrd.tar.gz - MODULE_CMDLINE=initrd + MODULE_PATH=boot:///initrd.tar.gz + MODULE_CMDLINE=initrd