clray
annotate Makefile @ 47:30bf84881553
added interactive controls for turning shadows/reflections on and off as well as selecting maximum ray tracing iterations
author | John Tsiombikas <nuclear@member.fsf.org> |
---|---|
date | Tue, 31 Aug 2010 01:47:27 +0100 |
parents | 1169f3d04135 |
children | 9c0867942612 |
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@45 | 6 opt = -O3 -ffast-math |
nuclear@45 | 7 dbg = -g |
nuclear@45 | 8 |
nuclear@0 | 9 CXX = g++ |
nuclear@45 | 10 CXXFLAGS = -pedantic -Wall $(dbg) $(opt) $(def) |
nuclear@13 | 11 LDFLAGS = $(libgl) $(libcl) -lpthread |
nuclear@8 | 12 |
nuclear@8 | 13 ifeq ($(shell uname -s), Darwin) |
nuclear@8 | 14 libgl = -framework OpenGL -framework GLUT |
nuclear@8 | 15 libcl = -framework OpenCL |
nuclear@8 | 16 else |
nuclear@45 | 17 libgl = -lGL -lGLU -lglut |
nuclear@8 | 18 libcl = -lOpenCL |
nuclear@40 | 19 def = -DCLGL_INTEROP |
nuclear@8 | 20 endif |
nuclear@0 | 21 |
nuclear@0 | 22 $(bin): $(obj) |
nuclear@0 | 23 $(CXX) -o $@ $(obj) $(LDFLAGS) |
nuclear@0 | 24 |
nuclear@12 | 25 -include $(dep) |
nuclear@12 | 26 |
nuclear@12 | 27 %.d: %.cc |
nuclear@12 | 28 @$(CPP) $(CXXFLAGS) -MM -MT $(@:.d=.o) $< >$@ |
nuclear@12 | 29 |
nuclear@0 | 30 .PHONY: clean |
nuclear@0 | 31 clean: |
nuclear@12 | 32 rm -f $(obj) $(bin) $(dep) |