clray
view Makefile @ 29:353d80127627
doh ... it doesn't work
author | John Tsiombikas <nuclear@member.fsf.org> |
---|---|
date | Sat, 21 Aug 2010 20:51:57 +0100 |
parents | 85fd61f374d9 |
children | 1bcbb53b3505 |
line source
1 src = $(wildcard src/*.cc)
2 obj = $(src:.cc=.o)
3 dep = $(obj:.o=.d)
4 bin = test
6 CXX = g++
7 CXXFLAGS = -pedantic -Wall -g
8 LDFLAGS = $(libgl) $(libcl) -lpthread
10 ifeq ($(shell uname -s), Darwin)
11 libgl = -framework OpenGL -framework GLUT
12 libcl = -framework OpenCL
13 else
14 libgl = -lGL -lglut
15 libcl = -lOpenCL
16 endif
18 $(bin): $(obj)
19 $(CXX) -o $@ $(obj) $(LDFLAGS)
21 -include $(dep)
23 %.d: %.cc
24 @$(CPP) $(CXXFLAGS) -MM -MT $(@:.d=.o) $< >$@
26 .PHONY: clean
27 clean:
28 rm -f $(obj) $(bin) $(dep)