#
# Vane Operating System Makefile by VOSystems
#--------------------------------------------//
TARGET = Kernel.vsb
#宣言
CC = gcc
RM = /bin/rm
MV = /bin/mv
LD = /usr/bin/ld
LN_S = ln -s
AR = /usr/bin/ar
RANLIB = ranlib
INCLUDES = -I../include
FLAGS = -m32 -ffreestanding -fno-common -fno-builtin -fomit-frame-pointer -O2 -c
FLAGSC = -m32 -ffreestanding -fno-common -masm=intel -fno-builtin -fomit-frame-pointer -O2 -c
LD = ld -melf_i386 -Ttext=0x100000 --oformat elf32-i386 -o
#LDAPP = ld -melf_i386 -Ttext=0x280000 --oformat elf32-i386 -o
export
#サフィックス
.S.o:
	${CC} ${INCLUDES} ${FLAGS} $<
.c.o:
	${CC} ${INCLUDES} ${FLAGSC} $<
#STDIO_C=stdio.c
BIN=Kernel.vsb
#処理
copy:
	cp /media/DATA/OS/OS/Kernel.vsb /media/VaneOS/Vane/Kernel.vsb
all:
	${MAKE} -C Kernel
	${MAKE} -C Drivers
	@echo "Make is finish successfully!!"
clean:
	-${RM} -f *~ *.lo *.o make.log *.bak .a.out .core .*.core
	cd Kernel
	-${RM} -f *~ *.lo *.o make.log *.bak .a.out .core .*.core
	cd ..
	cd Drivers
	-${RM} -f *~ *.lo *.o make.log *.bak .a.out .core .*.core
	cd ..
