- Timestamp:
- Mar 11, 2021, 2:44:43 AM (4 years ago)
- Branches:
- feature/imgui-sdl
- Children:
- 301c90a
- Parents:
- 20e4c2b
- git-author:
- Dmitry Portnoy <dportnoy@…> (03/11/21 02:39:25)
- git-committer:
- Dmitry Portnoy <dportnoy@…> (03/11/21 02:44:43)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
makefile
r20e4c2b r187b0f5 1 # C FLAGS arecompiler flags and LIBFLAGS could be renamed LINKER_FLAGS1 # CXX_FLAGS are C++ compiler flags and LIBFLAGS could be renamed LINKER_FLAGS 2 2 OS = $(shell uname) 3 3 CC = g++ 4 CFLAGS = -std=c++17 -Wall -pedantic -rdynamic 4 #CXX_FLAGS = -std=c++17 -Wall -pedantic -g3 -rdynamic 5 CXX_FLAGS = -std=c++17 -Wall -pedantic -O3 5 6 # -rdynamic is to generate debug info for dynamic symbols on debian-based 6 7 # systems (tested on Linux Mint) … … 24 25 25 26 openglref: new-game.cpp logger.cpp utils.cpp crash-logger.cpp IMGUI/imgui_impl_glfw.cpp IMGUI/imgui_impl_opengl3.cpp $(IMGUI_FILES) 26 $(CC) $^ $(DEP) $(C FLAGS) -o $@ -DGLEW_STATIC27 $(CC) $^ $(DEP) $(CXX_FLAGS) -o $@ -DGLEW_STATIC 27 28 28 29 openglgame: main-opengl.cpp opengl-game.cpp crash-logger.cpp logger.cpp game-gui-glfw.cpp graphics-pipeline_opengl.cpp IMGUI/imgui_impl_glfw.cpp IMGUI/imgui_impl_opengl3.cpp $(IMGUI_FILES) 29 $(CC) $^ $(DEP) $(CFLAGS) -o $@ -DGLEW_STATIC 30 31 CXX_FLAGS = -std=c++17 -Wall -pedantic# -O3 -rdynamic 30 $(CC) $^ $(DEP) $(CXX_FLAGS) -o $@ -DGLEW_STATIC 32 31 33 32 ifeq ($(OS),Darwin) … … 46 45 endif 47 46 48 LIBS = `pkg-config --static --libs sdl2 sdl2_image sdl2_ttf sdl2_gfx`47 LIBS = `pkg-config --static --libs sdl2 sdl2_image sdl2_ttf` 49 48 ifeq ($(OS),Darwin) 50 49 LIBS := $(VULKAN_SDK_PATH)/lib/libvulkan.dylib $(LIBS) 51 50 endif 52 51 ifeq ($(OS),Linux) 53 LIBS = `pkg-config --static --libs sdl2` 54 LIBS := -lvulkan $(LIBS) -lSDL2_image -lSDL2_ttf -lSDL2_gfx # TODO: figure out how to statically link these, ideally using pkg-config 52 #LIBS = `pkg-config --static --libs sdl2` 53 LIBS = 54 LIBS := -lvulkan $(LIBS) -lSDL2 -lSDL2_image -lSDL2_ttf # TODO: figure out how to statically link these, ideally using pkg-config 55 55 endif 56 56 … … 63 63 GUI_HEADER_FILES = gui/screen.hpp gui/main-screen.hpp gui/game-screen.hpp gui/ui-element.hpp gui/button.hpp gui/panel.hpp gui/ui-value.hpp 64 64 65 SRC_FILES = main-vulkan.cpp vulkan-game.cpp crash-logger.cpp logger.cpp vulkan-utils.cpp utils.cpp game-gui-sdl.cpp $(GUI_SRC_FILES)66 HEADER_FILES = vulkan-game.hpp crash-logger.hpp logger.hpp vulkan-utils.hpp utils.hpp game-gui-sdl.hpp game-gui.hpp graphics-pipeline_vulkan.hpp $(GUI_HEADER_FILES) 65 vulkangame: SRC_FILES = main-vulkan.cpp vulkan-game.cpp crash-logger.cpp logger.cpp vulkan-utils.cpp utils.cpp game-gui-sdl.cpp IMGUI/imgui_impl_sdl.cpp IMGUI/imgui_impl_vulkan.cpp $(IMGUI_FILES) 66 vulkangame: HEADER_FILES = vulkan-game.hpp crash-logger.hpp logger.hpp vulkan-utils.hpp utils.hpp game-gui-sdl.hpp game-gui.hpp graphics-pipeline_vulkan.hpp IMGUI/imgui_impl_sdl.h IMGUI/imgui_impl_vulkan.h 67 67 68 68 vulkangame: $(SRC_FILES) $(HEADER_FILES) 69 69 $(CC) $(CXX_FLAGS) -o $@ $(SRC_FILES) $(LIB_FLAGS) -DGAMEGUI_INCLUDE_VULKAN 70 70 71 SRC_FILES = main-vulkan.cpp sdl-game.cpp crash-logger.cpp logger.cpp vulkan-utils.cpp game-gui-sdl.cpp IMGUI/imgui_impl_sdl.cpp IMGUI/imgui_impl_vulkan.cpp $(IMGUI_FILES)72 HEADER_FILES = sdl-game.hpp crash-logger.hpp logger.hpp vulkan-utils.hpp game-gui.hpp game-gui-sdl.hpp IMGUI/imgui_impl_sdl.h IMGUI/imgui_impl_vulkan.h71 sdlgame: SRC_FILES = main-vulkan.cpp sdl-game.cpp crash-logger.cpp logger.cpp vulkan-utils.cpp game-gui-sdl.cpp IMGUI/imgui_impl_sdl.cpp IMGUI/imgui_impl_vulkan.cpp $(IMGUI_FILES) 72 sdlgame: HEADER_FILES = sdl-game.hpp crash-logger.hpp logger.hpp vulkan-utils.hpp game-gui.hpp game-gui-sdl.hpp IMGUI/imgui_impl_sdl.h IMGUI/imgui_impl_vulkan.h 73 73 74 74 sdlgame: $(SRC_FILES) $(HEADER_FILES)
Note:
See TracChangeset
for help on using the changeset viewer.