better folders structures

This commit is contained in:
rick 2023-09-13 16:31:15 +02:00
parent c6922febc1
commit 9415a40263
Signed by: Rick
GPG key ID: 5CBE8779CD27BCBA
6 changed files with 10 additions and 3 deletions

View file

@ -2,7 +2,8 @@ OBJECTS = loader.o framebuffer.o io.o kmain.o
CC = gcc
CFLAGS = -m32 -nostdlib -nostdinc -fno-builtin -fno-stack-protector \
-nostartfiles -nodefaultlibs -c #-Wall -Wextra -Werror -c
-nostartfiles -nodefaultlibs -Iinclude -Wall -Wextra -Werror -c \
-ansi -pedantic
LDFLAGS = -T link.ld -melf_i386
@ -17,9 +18,15 @@ kernel.elf: $(OBJECTS)
%.o: %.c
$(CC) $(CFLAGS) $< -o $@
%.o: src/%.c
$(CC) $(CFLAGS) $< -o $@
%.o: %.s
$(AS) $(ASFLAGS) $< -o $@
%.o: src/%.s
$(AS) $(ASFLAGS) $< -o $@
os.iso: kernel.elf
cp kernel.elf iso/boot/kernel.elf
mkisofs -R \

View file

View file

@ -1,8 +1,8 @@
#include "framebuffer.h"
int write(char *buf, unsigned int len)
unsigned int write(char *buf, unsigned int len)
{
int ret = 0;
unsigned int ret = 0;
int pos = 0;
fb_move_cursor(ret);

View file