diff --git a/res/dpiaware.manifest b/res/dpiaware.manifest new file mode 100644 index 00000000..743e3369 --- /dev/null +++ b/res/dpiaware.manifest @@ -0,0 +1,15 @@ + + + + + + + + + + + true + + + + diff --git a/src/cmd/synergyc/CMakeLists.txt b/src/cmd/synergyc/CMakeLists.txt index 22bbe257..653cf374 100644 --- a/src/cmd/synergyc/CMakeLists.txt +++ b/src/cmd/synergyc/CMakeLists.txt @@ -60,6 +60,15 @@ add_executable(synergyc ${sources}) target_link_libraries(synergyc arch base client common io mt net ipc platform server synergy ${libs} ${OPENSSL_LIBS}) +if (WIN32) + ADD_CUSTOM_COMMAND( + TARGET synergyc + POST_BUILD + COMMAND "mt.exe" -manifest \"${CMAKE_SOURCE_DIR}\\res\\dpiaware.manifest\" -inputresource:\"$\"\;\#1 -outputresource:\"$\"\;\#1 + COMMENT "Adding display aware manifest..." + ) +endif() + if (CONF_CPACK) install(TARGETS synergyc diff --git a/src/cmd/synergyd/CMakeLists.txt b/src/cmd/synergyd/CMakeLists.txt index 005648f3..4ee859fc 100644 --- a/src/cmd/synergyd/CMakeLists.txt +++ b/src/cmd/synergyd/CMakeLists.txt @@ -37,6 +37,15 @@ endif() target_link_libraries(synergyd arch base common io ipc mt net platform synergy ${libs} ${OPENSSL_LIBS}) +if (WIN32) + ADD_CUSTOM_COMMAND( + TARGET synergyd + POST_BUILD + COMMAND "mt.exe" -manifest \"${CMAKE_SOURCE_DIR}\\res\\dpiaware.manifest\" -inputresource:\"$\"\;\#1 -outputresource:\"$\"\;\#1 + COMMENT "Adding display aware manifest..." + ) +endif() + if (CONF_CPACK) install(TARGETS synergyd diff --git a/src/cmd/synergys/CMakeLists.txt b/src/cmd/synergys/CMakeLists.txt index 2474bcc6..023574b1 100644 --- a/src/cmd/synergys/CMakeLists.txt +++ b/src/cmd/synergys/CMakeLists.txt @@ -60,6 +60,15 @@ add_executable(synergys ${sources}) target_link_libraries(synergys arch base client common io mt net ipc platform server synergy ${libs} ${OPENSSL_LIBS}) +if (WIN32) + ADD_CUSTOM_COMMAND( + TARGET synergys + POST_BUILD + COMMAND "mt.exe" -manifest \"${CMAKE_SOURCE_DIR}\\res\\dpiaware.manifest\" -inputresource:\"$\"\;\#1 -outputresource:\"$\"\;\#1 + COMMENT "Adding display aware manifest..." + ) +endif() + if (CONF_CPACK) install(TARGETS synergys