Include file restructure!

- include/ now has subdirs
- standard C headers will be in 'include/c'. Any program can include these
- all other header shall only be used by the kernel
This commit is contained in:
2024-05-07 21:01:50 +02:00
parent 41e0b93f52
commit 7826b9b7d4
20 changed files with 33 additions and 83 deletions
+2 -2
View File
@@ -3,7 +3,7 @@ CC = i386-elf-gcc
LD = i386-elf-ld
AS = nasm
CFLAGS = -ffreestanding -fno-builtin -fno-stack-protector -nostdinc -mgeneral-regs-only -m32 -march=i386 -Iinclude -Wall
CFLAGS = -ffreestanding -fno-builtin -fno-stack-protector -nostdinc -mgeneral-regs-only -m32 -march=i386 -Wall -Iinclude/c
SRC = ./src
BUILD = ./build
@@ -47,7 +47,7 @@ kernel: $(SRC)/kernel.c $(SRC)/entry.asm
@echo "Assembling $(SRC)/entry.asm..."
@$(AS) -felf32 -o $(BUILD)/entry.o $(SRC)/entry.asm
@echo "Compiling $(SRC)/kernel.c..."
@$(CC) $(CFLAGS) -o $(BUILD)/kernel.o -c $(SRC)/kernel.c
@$(CC) $(CFLAGS) -Iinclude -o $(BUILD)/kernel.o -c $(SRC)/kernel.c
@$(LD) -T$(SRC)/kernel.ld --oformat binary -o $(BUILD)/kernel.bin $(BUILD)/*.o
@rm $(BUILD)/*.o