tavli
view Makefile @ 5:e48b40a3c82a
foo
author | John Tsiombikas <nuclear@member.fsf.org> |
---|---|
date | Thu, 25 Jun 2015 20:43:34 +0300 |
parents | 52e0dd47753b |
children | a0d30f6f20d4 |
line source
1 PREFIX ?= /usr/local
3 src = $(wildcard src/*.cc)
4 obj = $(src:.cc=.o)
6 bin = tavli
8 CXXFLAGS = -pedantic -Wall -g
9 LDFLAGS = $(libgl) -lvmath -limago -lm -lpthread
11 ifeq ($(shell uname -s), Darwin)
12 libgl = -framework OpenGL -framework GLUT -lGLEW
13 else
14 libgl = -lGL -lGLU -lglut -lGLEW
15 endif
17 $(bin): $(obj)
18 $(CXX) -o $@ $(obj) $(LDFLAGS)
20 .PHONY: clean
21 clean:
22 rm -f $(obj) $(bin)
24 .PHONY: install
25 install: $(bin)
26 mkdir -p $(PREFIX)/bin
27 cp $(bin) $(PREFIX)/bin/$(bin)
29 .PHONY: uninstall
30 uninstall:
31 rm -f $(PREFIX)/bin/$(bin)