Folder reorg
This commit is contained in:
parent
228d2a15c8
commit
95850e0581
13
Makefile
13
Makefile
@ -6,10 +6,13 @@ LDFLAGS += -m32 -nostdlib -static -fno-common -fno-use-cxa-atexit -fno-exception
|
||||
CFLAGS += -m32 -Wall -Wextra -Werror -ffreestanding -fno-exceptions -fno-pie -fno-stack-protector
|
||||
CXXFLAGS += -m32 -Wall -Wextra -Werror -ffreestanding -fno-exceptions -fno-rtti -fno-pie
|
||||
|
||||
SUBDIRS := core drivers
|
||||
|
||||
CPPFLAGS += $(foreach dir, $(SUBDIRS), -I$(dir))
|
||||
|
||||
asmsrc=$(wildcard *.asm)
|
||||
asmobj=$(asmsrc:%.asm=%.o)
|
||||
csrc=$(wildcard *.c)
|
||||
csrc=$(shell find $(SUBDIRS) -type f -name "*.c")# $(wildcard *.c)
|
||||
cobj=$(csrc:%.c=%.o)
|
||||
deps = $(csrc:%.c=%.d)
|
||||
|
||||
@ -21,10 +24,10 @@ fd.img: kernel
|
||||
dd if=$< of=$@ conv=notrunc
|
||||
|
||||
#https://gcc.gnu.org/onlinedocs/gcc/x86-Function-Attributes.html#x86-Function-Attributes
|
||||
exception_handler.o:exception_handler.c
|
||||
$(CC) $(CPPFLAGS) $(CFLAGS) -mgeneral-regs-only -c $<
|
||||
irq_handler.o:irq_handler.c
|
||||
$(CC) $(CPPFLAGS) $(CFLAGS) -mgeneral-regs-only -c $<
|
||||
core/exception_handler.o:core/exception_handler.c
|
||||
$(CC) $(CPPFLAGS) $(CFLAGS) -mgeneral-regs-only -c $< -o $@
|
||||
core/irq_handler.o:core/irq_handler.c
|
||||
$(CC) $(CPPFLAGS) $(CFLAGS) -mgeneral-regs-only -c $< -o $@
|
||||
|
||||
%.o:%.asm
|
||||
$(AS) $(ASFLAGS) -o $@ $<
|
||||
|
2
core/exception.d
Normal file
2
core/exception.d
Normal file
@ -0,0 +1,2 @@
|
||||
core/exception.o: core/exception.c core/exception.h core/interrupt.h \
|
||||
core/types.h core/idt.h core/irq.h
|
BIN
core/exception.o
Normal file
BIN
core/exception.o
Normal file
Binary file not shown.
2
core/exception_handler.d
Normal file
2
core/exception_handler.d
Normal file
@ -0,0 +1,2 @@
|
||||
core/exception_handler.o: core/exception_handler.c core/exception.h \
|
||||
core/interrupt.h core/types.h drivers/vga.h
|
BIN
core/exception_handler.o
Normal file
BIN
core/exception_handler.o
Normal file
Binary file not shown.
1
core/gdt.d
Normal file
1
core/gdt.d
Normal file
@ -0,0 +1 @@
|
||||
core/gdt.o: core/gdt.c core/segment.h core/types.h core/gdt.h
|
BIN
core/gdt.o
Normal file
BIN
core/gdt.o
Normal file
Binary file not shown.
1
core/idt.d
Normal file
1
core/idt.d
Normal file
@ -0,0 +1 @@
|
||||
core/idt.o: core/idt.c core/idt.h core/types.h
|
BIN
core/idt.o
Normal file
BIN
core/idt.o
Normal file
Binary file not shown.
2
core/irq.d
Normal file
2
core/irq.d
Normal file
@ -0,0 +1,2 @@
|
||||
core/irq.o: core/irq.c core/irq.h core/interrupt.h core/types.h \
|
||||
core/idt.h drivers/pic.h
|
BIN
core/irq.o
Normal file
BIN
core/irq.o
Normal file
Binary file not shown.
2
core/irq_handler.d
Normal file
2
core/irq_handler.d
Normal file
@ -0,0 +1,2 @@
|
||||
core/irq_handler.o: core/irq_handler.c core/interrupt.h core/types.h \
|
||||
core/io.h core/irq.h drivers/pic.h drivers/vga.h
|
BIN
core/irq_handler.o
Normal file
BIN
core/irq_handler.o
Normal file
Binary file not shown.
1
core/klibc.d
Normal file
1
core/klibc.d
Normal file
@ -0,0 +1 @@
|
||||
core/klibc.o: core/klibc.c core/klibc.h core/types.h
|
BIN
core/klibc.o
Normal file
BIN
core/klibc.o
Normal file
Binary file not shown.
2
core/main.d
Normal file
2
core/main.d
Normal file
@ -0,0 +1,2 @@
|
||||
core/main.o: core/main.c core/exception.h core/interrupt.h core/types.h \
|
||||
core/gdt.h core/idt.h core/io.h core/irq.h drivers/pit.h drivers/vga.h
|
BIN
core/main.o
Normal file
BIN
core/main.o
Normal file
Binary file not shown.
2
drivers/pic.d
Normal file
2
drivers/pic.d
Normal file
@ -0,0 +1,2 @@
|
||||
drivers/pic.o: drivers/pic.c drivers/pic.h core/io.h core/types.h \
|
||||
core/irq.h core/interrupt.h
|
BIN
drivers/pic.o
Normal file
BIN
drivers/pic.o
Normal file
Binary file not shown.
1
drivers/pit.d
Normal file
1
drivers/pit.d
Normal file
@ -0,0 +1 @@
|
||||
drivers/pit.o: drivers/pit.c drivers/pit.h core/io.h core/types.h
|
BIN
drivers/pit.o
Normal file
BIN
drivers/pit.o
Normal file
Binary file not shown.
2
drivers/vga.d
Normal file
2
drivers/vga.d
Normal file
@ -0,0 +1,2 @@
|
||||
drivers/vga.o: drivers/vga.c drivers/vga.h core/types.h core/io.h \
|
||||
core/klibc.h
|
BIN
drivers/vga.o
Normal file
BIN
drivers/vga.o
Normal file
Binary file not shown.
Loading…
Reference in New Issue
Block a user