include config.mk TOBJ = ui.o canvas.o user.o palette.o tools.o debug.o OBJ = $(addprefix build/, ${TOBJ}) build: prep config.h ${OBJ} src/cdraw.c ${CC} ${CFLAGS} ${LIBS} ${OBJ} src/cdraw.c -o build/cdraw config.h: cp config.def.h config.h prep: mkdir -p build run: ./build/cdraw build/%.o: src/%.c ${CC} ${CFLAGS} $< -c -o $@ clean: rm $(OBJ) rm build/cdraw .PHONY: build clean run prep