metasurf
annotate examples/volume/Makefile @ 9:1fd80c90d566
added website in the readme file
author | John Tsiombikas <nuclear@member.fsf.org> |
---|---|
date | Thu, 17 Apr 2014 13:46:04 +0300 |
parents | dedd153d2ceb |
children | 430d8dde62aa |
rev | line source |
---|---|
nuclear@3 | 1 src = $(wildcard src/*.c) |
nuclear@3 | 2 obj = $(src:.c=.o) |
nuclear@3 | 3 dep = $(obj:.o=.d) |
nuclear@3 | 4 bin = volume |
nuclear@3 | 5 |
nuclear@3 | 6 # uncomment the following line to disable shaders (for old systems like SGI or whatever) |
nuclear@3 | 7 #nosdr = -DNO_SHADERS |
nuclear@3 | 8 |
nuclear@3 | 9 CC = gcc |
nuclear@5 | 10 CFLAGS = -pedantic -Wall -g -I../../src $(inc) $(nosdr) |
nuclear@8 | 11 LDFLAGS = -L../.. -lmetasurf $(libgl) -limago -lm |
nuclear@3 | 12 |
nuclear@3 | 13 ifeq ($(shell uname -s), Darwin) |
nuclear@5 | 14 inc = -I/opt/local/include |
nuclear@5 | 15 libgl = -L/opt/local/lib -framework OpenGL -framework GLUT -lGLEW |
nuclear@3 | 16 else |
nuclear@3 | 17 libgl = -lGL -lGLU -lglut -lGLEW |
nuclear@3 | 18 endif |
nuclear@3 | 19 |
nuclear@3 | 20 $(bin): $(obj) |
nuclear@3 | 21 $(CC) -o $@ $(obj) $(LDFLAGS) |
nuclear@3 | 22 |
nuclear@3 | 23 -include $(dep) |
nuclear@3 | 24 |
nuclear@3 | 25 %.d: %.c |
nuclear@3 | 26 @$(CPP) $(CFLAGS) $< -MM -MT $(@:.d=.o) >$@ |
nuclear@3 | 27 |
nuclear@3 | 28 .PHONY: clean |
nuclear@3 | 29 clean: |
nuclear@3 | 30 rm -f $(obj) $(bin) |
nuclear@3 | 31 |
nuclear@3 | 32 |
nuclear@3 | 33 .PHONY: cleandep |
nuclear@3 | 34 cleandep: |
nuclear@3 | 35 rm -f $(dep) |