Makefile dependencies update

This commit is contained in:
Adrien Bourmault 2019-05-11 10:04:36 +02:00
parent cef3c37b89
commit 99a9bbaf5d
2 changed files with 16 additions and 13 deletions

View File

@ -222,6 +222,16 @@ install_mbr: $(BINDIR)/disk.img $(MBRDIR)/grub.cfg
@rmdir $(BINDIR)/disk @rmdir $(BINDIR)/disk
@echo ${CL2}[$@] ${CL}Success.${CL3} @echo ${CL2}[$@] ${CL}Success.${CL3}
copy_kernel:
@mkdir -p $(BINDIR)/disk
@echo ${CL2}[$@] ${NC}Integrating kernel${CL3}
-@$(MBRDIR)/umount.sh $(BINDIR)/disk || /bin/true
@$(MBRDIR)/mount.sh $(BINDIR)/disk.img $(BINDIR)/disk
@cp $(BINDIR)/kaleid $(BINDIR)/disk/boot/kaleid
@$(MBRDIR)/umount.sh $(BINDIR)/disk
@echo ${CL2}[$@] ${CL}Success.${CL3}
@rmdir $(BINDIR)/disk
dust: dust:
-@$(MBRDIR)/umount.sh $(BINDIR)/disk || /bin/true -@$(MBRDIR)/umount.sh $(BINDIR)/disk || /bin/true
@rm -Rf $(OBJDIR)/* @rm -Rf $(OBJDIR)/*
@ -235,6 +245,7 @@ clean:
$(BINDIR)/kaleid: $(LOBJDIR)/kaleid.x86_64 $(BINDIR)/kaleid: $(LOBJDIR)/kaleid.x86_64
@echo ${CL2}[$@] ${NC}Objcopy...${CL3} @echo ${CL2}[$@] ${NC}Objcopy...${CL3}
@$(OBJCOPY) -I elf64-x86-64 -O elf32-i386 $(LOBJDIR)/kaleid.x86_64 $(BINDIR)/kaleid @$(OBJCOPY) -I elf64-x86-64 -O elf32-i386 $(LOBJDIR)/kaleid.x86_64 $(BINDIR)/kaleid
@make copy_kernel
@echo ${CL2}[$@] ${CL}Success.${CL3} @echo ${CL2}[$@] ${CL}Success.${CL3}
$(LOBJDIR)/kaleid.x86_64: $(LibCObj) $(KernObj) $(LOBJDIR)/loader.o $(LOBJDIR)/kaleid.x86_64: $(LibCObj) $(KernObj) $(LOBJDIR)/loader.o
@ -257,12 +268,5 @@ $(BINDIR)/disk.img: $(MBRDIR)/create_disk.sh
@make install_mbr @make install_mbr
@echo ${CL2}[$@]${NC} Constructing disk image...${CL3} @echo ${CL2}[$@]${NC} Constructing disk image...${CL3}
OS/K: $(BINDIR)/kaleid $(BINDIR)/disk.img ./ProjectTree OS/K: $(BINDIR)/disk.img $(BINDIR)/kaleid ./ProjectTree
@mkdir -p $(BINDIR)/disk @echo ${CL2}[[$@]] ${NC} OS/K successfully made, $(mode) mode.${CL3}
@echo ${CL2}[[$@]] ${NC}Integrating kernel, $(mode) mode.${CL3}
-@$(MBRDIR)/umount.sh $(BINDIR)/disk || /bin/true
@$(MBRDIR)/mount.sh $(BINDIR)/disk.img $(BINDIR)/disk
@cp $(BINDIR)/kaleid $(BINDIR)/disk/boot/kaleid
@$(MBRDIR)/umount.sh $(BINDIR)/disk
@echo ${CL2}[[$@]] ${CL}Success.${CL3}
@rmdir $(BINDIR)/disk

View File

@ -152,9 +152,8 @@
│   │   ├── strtol.d │   │   ├── strtol.d
│   │   └── strtol.o │   │   └── strtol.o
│   ├── grub.log │   ├── grub.log
│   ├── kaleid32_disasm.asm │   ├── kernel.ld
│   ├── kaleid64_disasm.asm │   └── qemu.log
│   └── kernel.ld
├── include ├── include
│   ├── base │   ├── base
│   │   ├── assert.h │   │   ├── assert.h
@ -259,4 +258,4 @@
├── ProjectTree ├── ProjectTree
└── README.md └── README.md
41 directories, 193 files 41 directories, 192 files