dungeon_crawler
view prototype/Makefile.in @ 43:3fef65352b0b
- added mipmap generation
author | John Tsiombikas <nuclear@member.fsf.org> |
---|---|
date | Thu, 30 Aug 2012 05:58:09 +0300 |
parents | f5fb04fe12cd |
children | d52711f2b9a1 |
line source
1 csrc = $(wildcard src/*.c) $(wildcard vmath/*.c) $(wildcard drawtext/*.c)
2 ccsrc = $(wildcard src/*.cc) $(wildcard vmath/*.cc)
3 obj = $(csrc:.c=.o) $(ccsrc:.cc=.o)
4 dep = $(obj:.o=.d)
5 bin = proto
7 warn = -Wall -Wno-format-extra-args -Wno-char-subscripts
9 inc = -I. -Ivmath -Idrawtext `pkg-config --cflags freetype2`
11 CFLAGS = -pedantic $(warn) $(dbg) $(opt) $(inc)
12 CXXFLAGS = $(CFLAGS) $(cxx11_cflags)
13 LDFLAGS = $(cxx11_ldflags) $(libgl) -lm -lassimp -limago -lpsys `pkg-config --libs freetype2`
15 ifeq ($(shell uname -s), Darwin)
16 libgl = -framework OpenGL -framework GLUT -lglew
17 else
18 libgl = -lGL -lGLU -lglut -lGLEW
19 endif
21 $(bin): $(obj) Makefile
22 $(CXX) -o $@ $(obj) $(LDFLAGS)
24 -include $(dep)
26 %.d: %.c
27 @$(CPP) $(CFLAGS) $< -MM -MT $(@:.d=.o) >$@
29 %.d: %.cc
30 @$(CPP) $(CXXFLAGS) $< -MM -MT $(@:.d=.o) >$@
32 .PHONY: clean
33 clean:
34 rm -f $(obj) $(bin) $(dep)
36 include build/macapp.mk