clray
annotate Makefile @ 12:85fd61f374d9
fixed the bloody intersection bug
author | John Tsiombikas <nuclear@member.fsf.org> |
---|---|
date | Tue, 03 Aug 2010 13:06:59 +0100 |
parents | deaf85acf6af |
children | 407935b73af3 |
rev | line source |
---|---|
nuclear@0 | 1 src = $(wildcard src/*.cc) |
nuclear@0 | 2 obj = $(src:.cc=.o) |
nuclear@12 | 3 dep = $(obj:.o=.d) |
nuclear@0 | 4 bin = test |
nuclear@0 | 5 |
nuclear@0 | 6 CXX = g++ |
nuclear@0 | 7 CXXFLAGS = -pedantic -Wall -g |
nuclear@8 | 8 LDFLAGS = $(libgl) $(libcl) |
nuclear@8 | 9 |
nuclear@8 | 10 ifeq ($(shell uname -s), Darwin) |
nuclear@8 | 11 libgl = -framework OpenGL -framework GLUT |
nuclear@8 | 12 libcl = -framework OpenCL |
nuclear@8 | 13 else |
nuclear@8 | 14 libgl = -lGL -lglut |
nuclear@8 | 15 libcl = -lOpenCL |
nuclear@8 | 16 endif |
nuclear@0 | 17 |
nuclear@0 | 18 $(bin): $(obj) |
nuclear@0 | 19 $(CXX) -o $@ $(obj) $(LDFLAGS) |
nuclear@0 | 20 |
nuclear@12 | 21 -include $(dep) |
nuclear@12 | 22 |
nuclear@12 | 23 %.d: %.cc |
nuclear@12 | 24 @$(CPP) $(CXXFLAGS) -MM -MT $(@:.d=.o) $< >$@ |
nuclear@12 | 25 |
nuclear@0 | 26 .PHONY: clean |
nuclear@0 | 27 clean: |
nuclear@12 | 28 rm -f $(obj) $(bin) $(dep) |