# HG changeset patch # User John Tsiombikas # Date 1398393806 -10800 # Node ID cd7755e4663a4dcfba599b3d31e0b29876f4ba97 # Parent b326d53321f7528af1ad1e0b988bcf9896ca3c58 added makefile commented out ovr 0.3.1 header file until it actually works diff -r b326d53321f7 -r cd7755e4663a .hgignore --- a/.hgignore Fri Apr 25 05:20:53 2014 +0300 +++ b/.hgignore Fri Apr 25 05:43:26 2014 +0300 @@ -1,4 +1,6 @@ \.o$ +\.d$ +^vrchess$ \.swp$ \.sln$ \.vcxproj$ diff -r b326d53321f7 -r cd7755e4663a Makefile --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Makefile Fri Apr 25 05:43:26 2014 +0300 @@ -0,0 +1,38 @@ +csrc = $(wildcard src/*.c) +ccsrc = $(wildcard src/*.cc) +obj = $(csrc:.c=.o) $(ccsrc:.cc=.o) +dep = $(obj:.o=.d) +bin = vrchess + +CFLAGS = -pedantic -Wall -g +CXXFLAGS = -std=c++11 $(CFLAGS) +LDFLAGS = $(libgl_$(sys)) -lm -lvmath -limago + +libgl_unix = -lGL -lGLU -lglut -lGLEW +libgl_mac = -framework OpenGL -framework GLUT -lGLEW +libgl_win = -lopengl32 -lglu32 -lglut32 -lglew32 + +$(bin): $(obj) + $(CXX) -o $@ $(obj) $(LDFLAGS) + +-include $(dep) + +%.d: %.c + @$(CPP) $(CFLAGS) $< -MM -MT $(@:.d=.o) >$@ + +%.d: %.cc + @$(CPP) $(CXXFLAGS) $< -MM -MT $(@:.d=.o) >$@ + +.PHONY: clean +clean: + rm -f $(obj) $(bin) + +# os detection +uname = $(shell uname -s) +ifeq ($(sys), Darwin) + sys = mac +else ifeq ($(findstring MINGW, $(sys)), MINGW) + sys = win +else + sys = unix +endif diff -r b326d53321f7 -r cd7755e4663a src/game.cc --- a/src/game.cc Fri Apr 25 05:20:53 2014 +0300 +++ b/src/game.cc Fri Apr 25 05:43:26 2014 +0300 @@ -2,7 +2,7 @@ #include "opengl.h" #include "camera.h" #include "texture.h" -#include "OVR_CAPI_GL.h" +//#include "OVR_CAPI_GL.h" static void draw_scene(); @@ -177,4 +177,4 @@ glFrontFace(GL_CCW); glPopMatrix(); -} \ No newline at end of file +}