diff --git a/client/CMakeLists.txt b/client/CMakeLists.txt index ca5cc26..b314821 100644 --- a/client/CMakeLists.txt +++ b/client/CMakeLists.txt @@ -11,4 +11,14 @@ if(WIN32) COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_SOURCE_DIR}/assets $/assets) +endif() + +set_target_properties(client PROPERTIES + WIN32_EXECUTABLE ON +) + +# https://stackoverflow.com/a/73899349/16255372 +if (WIN32) + # /ENTRY:mainCRTStartup keeps the same "main" function instead of requiring "WinMain" + target_link_options(client PRIVATE "/ENTRY:mainCRTStartup") endif() \ No newline at end of file