diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2017-05-24 17:22:59 +0200 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2017-05-24 17:22:59 +0200 |
commit | ef4f613ba0ce350c0b1c3ce236536e2a9e5afecc (patch) | |
tree | 52bbf9e1adfea1b5f85682b4c188160ae82a8a7f /cmake/opentrack-boilerplate.cmake | |
parent | 5952fe02902f3ef53a71bf7e08b24535a3003612 (diff) |
cmake: avoid rebuilds wrt win32 subsystem
Diffstat (limited to 'cmake/opentrack-boilerplate.cmake')
-rw-r--r-- | cmake/opentrack-boilerplate.cmake | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/cmake/opentrack-boilerplate.cmake b/cmake/opentrack-boilerplate.cmake index ec1946f0..7052e704 100644 --- a/cmake/opentrack-boilerplate.cmake +++ b/cmake/opentrack-boilerplate.cmake @@ -58,13 +58,12 @@ endfunction() function(otr_fixup_subsystem n) if(MSVC) - if(SDK_CONSOLE_DEBUG) + set(subsystem WINDOWS) + get_property(type TARGET "${n}" PROPERTY TYPE) + if(SDK_CONSOLE_DEBUG AND ".${type}" STREQUAL ".EXECUTABLE") set(subsystem CONSOLE) - else() - set(subsystem WINDOWS) endif() set(loc "$<TARGET_FILE:${n}>") - get_property(type TARGET "${n}" PROPERTY TYPE) if (NOT type STREQUAL "STATIC_LIBRARY") add_custom_command(TARGET "${n}" POST_BUILD |