KERNEL_OBJ = kernel/entry.o kernel/arch/x86/tty/tty.o kernel/drivers/irq/i8259a.o kernel/arch/x86/irq/idt.o kernel/arch/x86/irq/sample_handler.o kernel/kernel.o
all: boot.img kernel/kernel.elf
KERNEL_OBJ = kernel/entry.o kernel/arch/x86/tty/tty.o kernel/drivers/irq/i8259a.o kernel/arch/x86/irq/idt.o kernel/arch/x86/irq/sample_handler.o kernel/kernel.o
all: boot.img kernel/kernel.elf
kernel/entry.o: kernel/entry.s
$(AS) -f elf kernel/entry.s -o $@
kernel/arch/x86/tty/tty.o: kernel/arch/x86/tty/tty.c
kernel/entry.o: kernel/entry.s
$(AS) -f elf kernel/entry.s -o $@
kernel/arch/x86/tty/tty.o: kernel/arch/x86/tty/tty.c
kernel/kernel.elf: kernel/kernel.bin
$(LD) -o $@ -T kernel/linker.ld ${KERNEL_OBJ} --oformat=elf32-i386
kernel/kernel.elf: kernel/kernel.bin
$(LD) -o $@ -T kernel/linker.ld ${KERNEL_OBJ} --oformat=elf32-i386