source: opengl-game/makefile@ 4762301

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

Make CrashLogger work for Debian-based systems

  • Property mode set to 100644
File size: 1.0 KB
Line 
1OS = $(shell uname)
2CC = g++
3CFLAGS = -std=c++0x -Wall -pedantic -rdynamic
4#-Wextra -fno-inline
5
6ifeq ($(OS),Darwin)
7 DEP = -framework Cocoa -framework OpenGL -framework IOKit -framework CoreVideo -lglfw -lglew
8endif
9ifeq ($(OS),Linux)
10 DEP = -lglfw3 -lGLEW -lGL -ldl -lX11 -lXrandr -lXxf86vm -lXinerama -lXcursor -pthread
11endif
12
13IMGUI_FILES = IMGUI/imgui_demo.cpp IMGUI/imgui_draw.cpp IMGUI/imgui.cpp
14
15# If I were generating .o files as well, I should use $? instead of $^
16# as this well prevent regenerating .o files for unchanged .cpp files
17
18newgame: new-game.cpp logger.cpp utils.cpp CrashLogger.cpp stb_image.cpp imgui_impl_glfw_gl3.cpp $(IMGUI_FILES)
19 $(CC) $^ $(DEP) $(CFLAGS) -o $@
20
21pong: pong.cpp logger.cpp
22 $(CC) $^ $(DEP) $(CFLAGS) -o $@
23
24mygame: mygame.cpp common/shader.cpp common/texture.cpp common/controls-new.cpp
25 $(CC) $^ $(DEP) $(CFLAGS) -o $@
26
27demo: game06.cpp common/shader.cpp common/texture.cpp common/controls.cpp
28 $(CC) $^ $(DEP) $(CFLAGS) -o $@
29
30clean:
31 rm -f newgame
32 rm -f pong
33 rm -f mygame
34 rm -f demo
Note: See TracBrowser for help on using the repository browser.