source: opengl-game/makefile@ 15c7ed9

feature/imgui-sdl points-test
Last change on this file since 15c7ed9 was 15c7ed9, checked in by Dmitry Portnoy <dmp1488@…>, 8 years ago

Change the makefile to fully support mac and linux and add preprocessor driectives to detect the OS in the C++ code

  • Property mode set to 100644
File size: 378 bytes
Line 
1OS = $(shell uname)
2CC = g++
3CFLAGS = -std=c++0x -Wall -pedantic #-Wextra
4
5ifeq ($(OS),Darwin)
6 DEP = -framework Cocoa -framework OpenGL -framework IOKit -framework CoreVideo -lglfw3 -lglew
7endif
8ifeq ($(OS),Linux)
9 DEP = -lglfw3 -lGLEW -lGL -ldl -lX11 -lXrandr -lXxf86vm -lXinerama -lXcursor -pthread
10endif
11
12game: game.cpp
13 $(CC) $? $(DEP) $(CFLAGS) -o $@
14
15clean:
16 rm -f game
Note: See TracBrowser for help on using the repository browser.