libgoatvr
annotate example/Makefile @ 7:6896f9cf9621
- configure now emits config.status with the current confure invocation
- now vr_init will heed the VR_MODULE env var for the name of the module to use
- more stuff on the openhmd module
author | John Tsiombikas <nuclear@member.fsf.org> |
---|---|
date | Fri, 19 Sep 2014 15:16:51 +0300 |
parents | e63cb28fc644 |
children | d12592558809 |
rev | line source |
---|---|
nuclear@5 | 1 src = $(wildcard src/*.c) |
nuclear@5 | 2 obj = $(src:.c=.o) |
nuclear@5 | 3 bin = test |
nuclear@5 | 4 |
nuclear@5 | 5 vrlib_root = .. |
nuclear@7 | 6 vrlib = $(vrlib_root)/libgoatvr.so |
nuclear@5 | 7 |
nuclear@5 | 8 CFLAGS = -pedantic -Wall -g `pkg-config --cflags sdl2` -I$(vrlib_root)/src |
nuclear@7 | 9 LDFLAGS = $(libgl) `pkg-config --libs sdl2` -L$(vrlib_root) -lgoatvr -Wl,-rpath=$(vrlib_root) |
nuclear@5 | 10 |
nuclear@5 | 11 ifeq ($(shell uname -s), Darwin) |
nuclear@5 | 12 libgl = -framework OpenGL -lGLEW |
nuclear@5 | 13 else |
nuclear@5 | 14 libgl = -lGL -lGLU -lGLEW |
nuclear@5 | 15 endif |
nuclear@5 | 16 |
nuclear@5 | 17 $(bin): $(obj) $(vrlib) |
nuclear@5 | 18 $(CC) -o $@ $(obj) $(LDFLAGS) |
nuclear@5 | 19 |
nuclear@5 | 20 .PHONY: $(vrlib) |
nuclear@5 | 21 $(vrlib): |
nuclear@5 | 22 $(MAKE) -C $(vrlib_root) |
nuclear@5 | 23 |
nuclear@5 | 24 .PHONY: clean |
nuclear@5 | 25 clean: |
nuclear@5 | 26 rm -f $(obj) $(bin) |