deepstone

annotate GNUmakefile @ 32:7c8402e27b7c

renamed Makefile.dos to Makefile
author John Tsiombikas <nuclear@member.fsf.org>
date Sun, 22 Sep 2013 18:37:46 +0300
parents 11d14f688485
children 1870c4ef8b76
rev   line source
nuclear@27 1 obj = src/main.o \
nuclear@28 2 src/mingl.o src/mglrast.o src/mglclip.o src/mglgen.o \
nuclear@3 3 src/texture.o src/palman.o \
nuclear@26 4 src/scene.o src/cvec.o src/fixedp.o \
nuclear@0 5 dosemu/dosemu.o
nuclear@0 6 dep = $(obj:.o=.d)
nuclear@25 7 bin = deepstone
nuclear@0 8
nuclear@0 9 CC = gcc
nuclear@31 10 CFLAGS = -pedantic -Wall -g `pkg-config --cflags sdl` -Isrc -Idosemu $(add_cflags) -DRAST_FLOAT -DDBG_USE_FLOAT
nuclear@25 11 LDFLAGS = `pkg-config --libs sdl` -lm
nuclear@0 12
nuclear@31 13 ifeq ($(shell uname -s), Darwin)
nuclear@31 14 add_cflags = -Dmain=SDL_main
nuclear@31 15 endif
nuclear@31 16
nuclear@0 17 $(bin): $(obj)
nuclear@0 18 $(CC) -o $@ $(obj) $(LDFLAGS)
nuclear@0 19
nuclear@0 20 -include $(dep)
nuclear@0 21
nuclear@0 22 %.d: %.c
nuclear@0 23 @$(CPP) $(CFLAGS) $< -MM -MT $(@:.d=.o) >$@
nuclear@0 24
nuclear@0 25 .PHONY: clean
nuclear@0 26 clean:
nuclear@0 27 rm -f $(obj) $(bin)
nuclear@5 28
nuclear@5 29 .PHONY: cleandep
nuclear@5 30 cleandep:
nuclear@5 31 rm -f $(dep)