From 75c3e30404537d0b3438a8ac40880f74bb6af3b4 Mon Sep 17 00:00:00 2001 From: Arseniy Shestakov Date: Tue, 31 Oct 2017 09:28:35 +0300 Subject: [PATCH] CMake: further improvements for generated VS solutions * Set vcmiclient as VS_STARTUP_PROJECT so it's will be default debug target instead of ALL_BUILD. * Add AIs and server as dependencies for client so VS will suggest to rebuild them before debugging. --- client/CMakeLists.txt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/client/CMakeLists.txt b/client/CMakeLists.txt index 692924f9e..1bc884315 100644 --- a/client/CMakeLists.txt +++ b/client/CMakeLists.txt @@ -130,6 +130,7 @@ if(ENABLE_DEBUG_CONSOLE) else() add_executable(vcmiclient WIN32 ${client_SRCS} ${client_HEADERS} ${client_ICON}) endif(ENABLE_DEBUG_CONSOLE) +add_dependencies(vcmiclient vcmiserver BattleAI StupidAI VCAI) if(WIN32) set_target_properties(vcmiclient @@ -137,6 +138,7 @@ if(WIN32) OUTPUT_NAME "VCMI_client" PROJECT_LABEL "VCMI_client" ) + set_property(DIRECTORY ${CMAKE_SOURCE_DIR} PROPERTY VS_STARTUP_PROJECT vcmiclient) if(NOT ENABLE_DEBUG_CONSOLE) target_link_libraries(vcmiclient ${SDLMAIN_LIBRARY}) endif()