cloth

view Makefile @ 3:28a31079dcdf

disc
author John Tsiombikas <nuclear@member.fsf.org>
date Mon, 04 Jan 2016 10:52:15 +0200
parents 92983e143a03
children
line source
1 src = $(wildcard src/*.cc)
2 obj = $(src:.cc=.o)
3 dep = $(obj:.o=.d)
4 bin = cloth
6 CXXFLAGS = -std=c++11 -pedantic -Wall -g
7 LDFLAGS = $(libgl) -limago -lvmath
9 ifeq ($(shell uname -s), Darwin)
10 libgl = -framework OpenGL -framework GLUT -lGLEW
11 else
12 libgl = -lGL -lGLU -lglut -lGLEW
13 endif
15 $(bin): $(obj)
16 $(CXX) -o $@ $(obj) $(LDFLAGS)
18 -include $(dep)
20 %.d: %.cc
21 @$(CPP) $(CXXFLAGS) $< -MM -MT $(@:.d=.o) >$@
23 .PHONY: clean
24 clean:
25 rm -f $(obj) $(bin)