diff --git a/cmake/platforms/windows.cmake b/cmake/platforms/windows.cmake index a7ed7c7c..481809ec 100644 --- a/cmake/platforms/windows.cmake +++ b/cmake/platforms/windows.cmake @@ -101,14 +101,12 @@ endif() if(WINELIB) enable_language(RC) - set(LFLAG_MANIFEST_NO "") elseif(CMAKE_C_COMPILER_ID MATCHES "MSVC" OR CMAKE_C_COMPILER_FRONTEND_VARIANT MATCHES "MSVC") set(CMAKE_RC_FLAGS "${CMAKE_RC_FLAGS} /nologo /C1252") - set(LFLAG_MANIFEST_NO "/manifest:no") + set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} /manifest:no") else() set(CMAKE_RC_FLAGS "${CMAKE_RC_FLAGS} -c1252") - set(LFLAG_MANIFEST_NO "") endif() if(STRICT) diff --git a/windows/CMakeLists.txt b/windows/CMakeLists.txt index 7e16b0f4..aefcb9d2 100644 --- a/windows/CMakeLists.txt +++ b/windows/CMakeLists.txt @@ -83,9 +83,7 @@ add_dependencies(pageant generated_licence_h) target_link_libraries(pageant guimisc eventloop agent network crypto utils ${platform_libraries}) -set_target_properties(pageant PROPERTIES - WIN32_EXECUTABLE ON - LINK_FLAGS "${LFLAG_MANIFEST_NO}") +set_target_properties(pageant PROPERTIES WIN32_EXECUTABLE ON) installed_program(pageant) add_sources_from_current_dir(plink no-jump-list.c nohelp.c plink.rc) @@ -111,9 +109,7 @@ target_link_libraries(putty guiterminal guimisc eventloop sshclient otherbackends settings network crypto utils ${platform_libraries}) -set_target_properties(putty PROPERTIES - WIN32_EXECUTABLE ON - LINK_FLAGS "${LFLAG_MANIFEST_NO}") +set_target_properties(putty PROPERTIES WIN32_EXECUTABLE ON) installed_program(putty) add_executable(puttytel @@ -132,9 +128,7 @@ add_dependencies(puttytel generated_licence_h) target_link_libraries(puttytel guiterminal guimisc eventloop otherbackends settings network utils ${platform_libraries}) -set_target_properties(puttytel PROPERTIES - WIN32_EXECUTABLE ON - LINK_FLAGS "${LFLAG_MANIFEST_NO}") +set_target_properties(puttytel PROPERTIES WIN32_EXECUTABLE ON) installed_program(puttytel) add_executable(puttygen @@ -152,9 +146,7 @@ add_dependencies(puttygen generated_licence_h) target_link_libraries(puttygen keygen guimisc crypto utils ${platform_libraries}) -set_target_properties(puttygen PROPERTIES - WIN32_EXECUTABLE ON - LINK_FLAGS "${LFLAG_MANIFEST_NO}") +set_target_properties(puttygen PROPERTIES WIN32_EXECUTABLE ON) installed_program(puttygen) if(HAVE_CONPTY) @@ -174,9 +166,7 @@ if(HAVE_CONPTY) target_link_libraries(pterm guiterminal guimisc eventloop settings network utils ${platform_libraries}) - set_target_properties(pterm PROPERTIES - WIN32_EXECUTABLE ON - LINK_FLAGS "${LFLAG_MANIFEST_NO}") + set_target_properties(pterm PROPERTIES WIN32_EXECUTABLE ON) installed_program(pterm) else() message("ConPTY not available; cannot build Windows pterm")