From 883fe27aed32535034b950995b46ea337a891d01 Mon Sep 17 00:00:00 2001 From: Ryan Pavlik Date: Wed, 18 Nov 2020 16:47:41 -0600 Subject: [PATCH] t/gui: Fix linking on Windows --- src/xrt/targets/gui/CMakeLists.txt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/xrt/targets/gui/CMakeLists.txt b/src/xrt/targets/gui/CMakeLists.txt index 2cc5c774c..42ad3f9fa 100644 --- a/src/xrt/targets/gui/CMakeLists.txt +++ b/src/xrt/targets/gui/CMakeLists.txt @@ -29,6 +29,10 @@ target_link_libraries(gui PRIVATE imgui_impl_sdl ${SDL2_LIBRARIES} ) +if(WIN32) + target_link_libraries(gui PRIVATE SDL2::SDL2main) +endif() + target_include_directories(gui PRIVATE ${CMAKE_CURRENT_SOURCE_DIR}/.. ${SDL2_INCLUDE_DIRS}