oculus1

annotate Makefile @ 15:402cbb6d9ce3

added the shader as a separate header file
author John Tsiombikas <nuclear@member.fsf.org>
date Sat, 21 Sep 2013 04:15:20 +0300
parents 59fc487ba58e
children f3672317e5c2
rev   line source
nuclear@0 1 src = $(wildcard src/*.cc)
nuclear@1 2 ovr_src = $(wildcard libovr/Src/*.cpp) \
nuclear@1 3 $(wildcard libovr/Src/Kernel/*.cpp) \
nuclear@1 4 $(wildcard libovr/Src/Util/*.cpp)
nuclear@1 5
nuclear@1 6 obj = $(src:.cc=.o) $(ovr_src:.cpp=.o) $(ovr_sys_src:.cpp=.o)
nuclear@0 7 bin = oculus1
nuclear@0 8
nuclear@1 9
nuclear@1 10 CXXFLAGS = -Wall -g -I/usr/local/include $(ovr_include) -DUSE_OVR
nuclear@5 11 LDFLAGS = -L/usr/local/lib $(libgl) $(ovrlibs) -lvmath -lm
nuclear@0 12
nuclear@0 13 ifeq ($(shell uname -s), Darwin)
nuclear@0 14 libgl = -framework OpenGL -framework GLUT -lGLEW
nuclear@1 15 ovrlibs = -framework CoreFoundation -framework ApplicationServices -framework IOKit
nuclear@1 16
nuclear@2 17 ovr_include = -Ilibovr/Include -Ilibovr/Src -Ilibovr/Src/osx -Ilibovr/Src/Kernel
nuclear@1 18 ovr_sys_src = $(wildcard libovr/Src/osx/*.cpp)
nuclear@0 19 else
nuclear@0 20 libgl = -lGL -lGLU -lglut -lGLEW
nuclear@2 21 ovrlibs = -lX11 -lXinerama -ludev -lpthread
nuclear@1 22
nuclear@2 23 ovr_include = -Ilibovr/Include -Ilibovr/Src -Ilibovr/Src/linux -Ilibovr/Src/Kernel
nuclear@1 24 ovr_sys_src = $(wildcard libovr/Src/linux/*.cpp)
nuclear@0 25 endif
nuclear@0 26
nuclear@0 27 $(bin): $(obj)
nuclear@0 28 $(CXX) -o $@ $(obj) $(LDFLAGS)
nuclear@0 29
nuclear@0 30 .PHONY: clean
nuclear@0 31 clean:
nuclear@0 32 rm -f $(obj) $(bin)