# Project: Project1
# Makefile created by Dev-C++ 4.9.9.2

CPP  = mipsel-linux-g++
CC   = mipsel-linux-gcc
OBJ  = dingux/drill.o dingux/CBmps.o dingux/Cffont.o dingux/CInput.o dingux/CTime.o dingux/CWavs.o
LINKOBJ  = dingux/drill.o dingux/CBmps.o dingux/Cffont.o dingux/CInput.o dingux/CTime.o dingux/CWavs.o
LIBS =  -L/opt/dingoo-uclibc-toolchain-06-17/lib -lSDL_image -lSDL_mixer -lSDL_ttf -lSDL
INCS =  -I"/opt/dingoo-uclibc-toolchain-06-17/usr/include" -I"/opt/dingoo-uclibc-toolchain-06-17/usr/include/SDL" 

BIN  = MrDrillux

CFLAGS = $(INCS) -D_REENTRANT  -Ddingux
RM = rm -f
MKDIR = mkdir -p

.PHONY: all all-before all-after clean clean-custom

all: all-before $(BIN) all-after

all-before:
	$(MKDIR) "dingux"


clean: clean-custom
	${RM} $(OBJ) $(BIN)

$(BIN): $(OBJ)
	$(CC) $(LINKOBJ) -o $@ $(LIBS)

dingux/drill.o: drill.c
	$(CC) -c drill.c -o dingux/drill.o $(CFLAGS)

dingux/CBmps.o: CBmps.c
	$(CC) -c CBmps.c -o dingux/CBmps.o $(CFLAGS)

dingux/Cffont.o: Cffont.c
	$(CC) -c Cffont.c -o dingux/Cffont.o $(CFLAGS)

dingux/CInput.o: CInput.c
	$(CC) -c CInput.c -o dingux/CInput.o $(CFLAGS)

dingux/CTime.o: CTime.c
	$(CC) -c CTime.c -o dingux/CTime.o $(CFLAGS)

dingux/CWavs.o: CWavs.c
	$(CC) -c CWavs.c -o dingux/CWavs.o $(CFLAGS)
