diff --git a/Makefile b/Makefile index 5891c9b..c6d91ed 100644 --- a/Makefile +++ b/Makefile @@ -25,7 +25,7 @@ $(BUILDDIR): $(BUILDDIR)/%.o: $(SRC)/%.c mkdir -p $(dir $@) - $(CC) -g -c -Isrc $< $(CC_PROBLEMATIC_FLAGS) $(CC_FLAGS) -o $@ + $(CC) -g -c -Iinclude $< $(CC_PROBLEMATIC_FLAGS) $(CC_FLAGS) -o $@ limine/limine: rm -rf limine diff --git a/src/config.h b/include/config.h similarity index 100% rename from src/config.h rename to include/config.h diff --git a/src/idt/idt.h b/include/idt/idt.h similarity index 100% rename from src/idt/idt.h rename to include/idt/idt.h diff --git a/src/io/kbd/ps2.h b/include/io/kbd/ps2.h similarity index 100% rename from src/io/kbd/ps2.h rename to include/io/kbd/ps2.h diff --git a/src/io/serial/serial.h b/include/io/serial/serial.h similarity index 100% rename from src/io/serial/serial.h rename to include/io/serial/serial.h diff --git a/src/io/term/flanterm.h b/include/io/term/flanterm.h similarity index 100% rename from src/io/term/flanterm.h rename to include/io/term/flanterm.h diff --git a/src/io/term/flanterm_backends/fb.h b/include/io/term/flanterm_backends/fb.h similarity index 100% rename from src/io/term/flanterm_backends/fb.h rename to include/io/term/flanterm_backends/fb.h diff --git a/src/io/term/flanterm_backends/fb_private.h b/include/io/term/flanterm_backends/fb_private.h similarity index 100% rename from src/io/term/flanterm_backends/fb_private.h rename to include/io/term/flanterm_backends/fb_private.h diff --git a/src/io/term/flanterm_private.h b/include/io/term/flanterm_private.h similarity index 100% rename from src/io/term/flanterm_private.h rename to include/io/term/flanterm_private.h diff --git a/src/io/term/nanoprintf.h b/include/io/term/nanoprintf.h similarity index 100% rename from src/io/term/nanoprintf.h rename to include/io/term/nanoprintf.h diff --git a/src/io/term/term.h b/include/io/term/term.h similarity index 100% rename from src/io/term/term.h rename to include/io/term/term.h diff --git a/src/kernel.h b/include/kernel.h similarity index 94% rename from src/kernel.h rename to include/kernel.h index bf5c324..58784aa 100644 --- a/src/kernel.h +++ b/include/kernel.h @@ -15,9 +15,9 @@ enum ErrorCodes { #define CLEAR_INTERRUPTS __asm__ volatile("cli") #define SET_INTERRUPTS __asm__ volatile("sti") -#include "io/serial/serial.h" -#include "io/term/term.h" -#include "idt/idt.h" +#include +#include +#include #include extern volatile uint64_t ticks; diff --git a/src/limine.h b/include/limine.h similarity index 100% rename from src/limine.h rename to include/limine.h diff --git a/src/mem/gdt/gdt.h b/include/mem/gdt.h similarity index 100% rename from src/mem/gdt/gdt.h rename to include/mem/gdt.h diff --git a/src/mem/heap/kheap.h b/include/mem/kheap.h similarity index 100% rename from src/mem/heap/kheap.h rename to include/mem/kheap.h diff --git a/src/mem/paging/paging.h b/include/mem/paging.h similarity index 98% rename from src/mem/paging/paging.h rename to include/mem/paging.h index dd55c99..91fc061 100644 --- a/src/mem/paging/paging.h +++ b/include/mem/paging.h @@ -11,7 +11,7 @@ #include #include -#include "mem/heap/kheap.h" +#include #include void paging_init(struct boot_context boot_ctx); diff --git a/src/mem/paging/pmm.h b/include/mem/pmm.h similarity index 100% rename from src/mem/paging/pmm.h rename to include/mem/pmm.h diff --git a/src/mem/misc/utils.h b/include/mem/utils.h similarity index 100% rename from src/mem/misc/utils.h rename to include/mem/utils.h diff --git a/src/mem/paging/vmm.h b/include/mem/vmm.h similarity index 100% rename from src/mem/paging/vmm.h rename to include/mem/vmm.h diff --git a/src/sched/process.h b/include/sched/process.h similarity index 97% rename from src/sched/process.h rename to include/sched/process.h index c6b6ecf..02a313a 100644 --- a/src/sched/process.h +++ b/include/sched/process.h @@ -8,7 +8,7 @@ #define PROCESS_H #include -#include "config.h" +#include #include typedef enum { diff --git a/src/sched/scheduler.h b/include/sched/scheduler.h similarity index 100% rename from src/sched/scheduler.h rename to include/sched/scheduler.h diff --git a/src/sched/spinlock.h b/include/sched/spinlock.h similarity index 100% rename from src/sched/spinlock.h rename to include/sched/spinlock.h diff --git a/src/string/string.h b/include/string/string.h similarity index 100% rename from src/string/string.h rename to include/string/string.h diff --git a/src/time/timer.h b/include/time/timer.h similarity index 100% rename from src/time/timer.h rename to include/time/timer.h diff --git a/limine.conf b/limine.conf index 3849b94..71825ed 100644 --- a/limine.conf +++ b/limine.conf @@ -1,6 +1,8 @@ timeout: 3 +interface_branding: Welcome to the PepperOS disk! /PepperOS protocol: limine - + + comment: Default configuration (warning: spicy) path: boot():/boot/pepperk diff --git a/src/debug/misc.c b/src/debug/misc.c index 36f8d88..044e63f 100644 --- a/src/debug/misc.c +++ b/src/debug/misc.c @@ -5,8 +5,8 @@ */ #include -#include "limine.h" -#include "string/string.h" +#include +#include #include extern struct boot_context boot_ctx; diff --git a/src/debug/panic.c b/src/debug/panic.c index 2915cf7..5fc2069 100644 --- a/src/debug/panic.c +++ b/src/debug/panic.c @@ -5,9 +5,9 @@ */ #include -#include "idt/idt.h" -#include "io/serial/serial.h" -#include "kernel.h" +#include +#include +#include extern struct init_status init; extern int panic_count; diff --git a/src/debug/stacktrace.c b/src/debug/stacktrace.c index 91910e8..696d5b6 100644 --- a/src/debug/stacktrace.c +++ b/src/debug/stacktrace.c @@ -5,7 +5,7 @@ */ #include -#include "kernel.h" +#include #include extern struct init_status init; diff --git a/src/idt/idt.c b/src/idt/idt.c index f70959f..51b0eca 100644 --- a/src/idt/idt.c +++ b/src/idt/idt.c @@ -4,16 +4,16 @@ * @license GPL-3.0-only */ -#include "idt.h" +#include #include #include -#include "io/serial/serial.h" -#include "io/kbd/ps2.h" +#include +#include #include #include -#include "sched/scheduler.h" -#include "config.h" -#include "sched/process.h" +#include +#include +#include struct interrupt_descriptor idt[256]; struct idtr idt_reg; diff --git a/src/io/kbd/ps2.c b/src/io/kbd/ps2.c index 25b18b2..e47d8a8 100644 --- a/src/io/kbd/ps2.c +++ b/src/io/kbd/ps2.c @@ -4,10 +4,10 @@ * @license GPL-3.0-only */ -#include "io/serial/serial.h" -#include "ps2.h" +#include +#include #include -#include "io/term/term.h" +#include #include #include diff --git a/src/io/serial/serial.c b/src/io/serial/serial.c index 0b37f9c..95ea78f 100644 --- a/src/io/serial/serial.c +++ b/src/io/serial/serial.c @@ -5,7 +5,7 @@ */ #include -#include "serial.h" +#include extern struct init_status init; diff --git a/src/io/term/flanterm.c b/src/io/term/flanterm.c index 0b9a31b..647af64 100644 --- a/src/io/term/flanterm.c +++ b/src/io/term/flanterm.c @@ -41,7 +41,7 @@ #define FLANTERM_IN_FLANTERM #endif -#include "flanterm.h" +#include // Tries to implement this standard for terminfo // https://man7.org/linux/man-pages/man4/console_codes.4.html diff --git a/src/io/term/flanterm_backends/fb.c b/src/io/term/flanterm_backends/fb.c index 5f05b82..775981c 100644 --- a/src/io/term/flanterm_backends/fb.c +++ b/src/io/term/flanterm_backends/fb.c @@ -51,8 +51,8 @@ #define FLANTERM_IN_FLANTERM #endif -#include "../flanterm.h" -#include "fb.h" +#include +#include void *memset(void *, int, size_t); void *memcpy(void *, const void *, size_t); diff --git a/src/io/term/term.c b/src/io/term/term.c index 8367a51..785151d 100644 --- a/src/io/term/term.c +++ b/src/io/term/term.c @@ -13,18 +13,18 @@ because this shitty implementation will be replaced one day by Flanterm #include #include -#include "term.h" -#include "config.h" -#include "flanterm.h" -#include "flanterm_backends/fb.h" -#include "mem/heap/kheap.h" -#include "limine.h" +#include +#include +#include +#include +#include +#include #include -#include "sched/spinlock.h" -#include "io/serial/serial.h" +#include +#include #define NANOPRINTF_IMPLEMENTATION -#include "nanoprintf.h" +#include extern struct flanterm_context* ft_ctx; extern struct init_status init; diff --git a/src/kmain.c b/src/kmain.c index d76801c..37daa7f 100644 --- a/src/kmain.c +++ b/src/kmain.c @@ -4,27 +4,26 @@ * @license GPL-3.0-only */ -#include +#include #include #include -#include "io/term/term.h" -#include "io/term/term.h" -#include "io/serial/serial.h" -#include "mem/gdt/gdt.h" -#include "mem/misc/utils.h" -#include "idt/idt.h" -#include "kernel.h" -#include "time/timer.h" -#include "io/kbd/ps2.h" -#include "mem/paging/pmm.h" -#include "mem/paging/paging.h" -#include "mem/paging/vmm.h" -#include "mem/heap/kheap.h" -#include "sched/process.h" -#include "sched/scheduler.h" -#include "config.h" -#include "io/term/flanterm.h" -#include "io/term/flanterm_backends/fb.h" +#include +#include +#include +#include +#include +#include +#include