source: opengl-game/makefile@ 98f06d9

feature/imgui-sdl points-test
Last change on this file since 98f06d9 was d9b6a1c, checked in by Dmitry Portnoy <dmitry.portnoy@…>, 6 years ago

Print a stack trace in the event of a crash. Currently, the code for this on Windows outputs the stack trace to stderr, not to a log file.

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