labyrinth

diff Makefile @ 0:8ba79034e8a6

labyrinth example initial commit
author John Tsiombikas <nuclear@member.fsf.org>
date Thu, 15 Jan 2015 14:59:38 +0200
parents
children 45b91185b298
line diff
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/Makefile	Thu Jan 15 14:59:38 2015 +0200
     1.3 @@ -0,0 +1,18 @@
     1.4 +src = $(wildcard src/*.c)
     1.5 +obj = $(src:.c=.o)
     1.6 +bin = lab
     1.7 +
     1.8 +sys = $(shell uname -s)
     1.9 +
    1.10 +libgl_Linux = -lGL -lGLU -lglut
    1.11 +libgl_Darwin = -framework OpenGL -framework GLUT
    1.12 +
    1.13 +CFLAGS = -pedantic -Wall -g
    1.14 +LDFLAGS = $(libgl_$(sys)) -lm
    1.15 +
    1.16 +$(bin): $(obj)
    1.17 +	$(CC) -o $@ $(obj) $(LDFLAGS)
    1.18 +
    1.19 +.PHONY: clean
    1.20 +clean:
    1.21 +	rm -f $(obj) $(bin)