summaryrefslogtreecommitdiffstats
path: root/Tests
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2020-04-15 13:50:30 (GMT)
committerKitware Robot <kwrobot@kitware.com>2020-04-15 13:50:49 (GMT)
commit4f7d16c68fd4825edbee6193c7dec7a3c93651b6 (patch)
tree2002cace0a70bdbf43ef30aff6a665fe235b971f /Tests
parent156196938c5e03e881592dd3247021063167abc0 (diff)
parentd6840a4f3cee501aa910035bb7fa2dad3c8d7f73 (diff)
downloadCMake-4f7d16c68fd4825edbee6193c7dec7a3c93651b6.zip
CMake-4f7d16c68fd4825edbee6193c7dec7a3c93651b6.tar.gz
CMake-4f7d16c68fd4825edbee6193c7dec7a3c93651b6.tar.bz2
Merge topic 'cpack-nsis-dpi-aware'
d6840a4f3c CPack/NSIS: Add option for setting DPI-aware Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !4607
Diffstat (limited to 'Tests')
-rw-r--r--Tests/CPackNSISGenerator/CMakeLists.txt1
-rw-r--r--Tests/CPackNSISGenerator/RunCPackVerifyResult.cmake8
2 files changed, 9 insertions, 0 deletions
diff --git a/Tests/CPackNSISGenerator/CMakeLists.txt b/Tests/CPackNSISGenerator/CMakeLists.txt
index b8b2ed6..8ed4d59 100644
--- a/Tests/CPackNSISGenerator/CMakeLists.txt
+++ b/Tests/CPackNSISGenerator/CMakeLists.txt
@@ -16,5 +16,6 @@ set(CPACK_NSIS_MUI_ICON "${PROJECT_SOURCE_DIR}\\\\install.ico")
set(CPACK_NSIS_MUI_UNIICON "${PROJECT_SOURCE_DIR}\\\\uninstall.ico")
set(CPACK_GENERATOR "NSIS")
set(CPACK_NSIS_ENABLE_UNINSTALL_BEFORE_INSTALL ON)
+set(CPACK_NSIS_MANIFEST_DPI_AWARE ON)
include(CPack)
diff --git a/Tests/CPackNSISGenerator/RunCPackVerifyResult.cmake b/Tests/CPackNSISGenerator/RunCPackVerifyResult.cmake
index 01b37c5..bfbcf9c 100644
--- a/Tests/CPackNSISGenerator/RunCPackVerifyResult.cmake
+++ b/Tests/CPackNSISGenerator/RunCPackVerifyResult.cmake
@@ -44,3 +44,11 @@ message(STATUS "Found the bitmap at index ${output_index}")
if("${output_index}" EQUAL "-1")
message(FATAL_ERROR "MUI_HEADERIMAGE_BITMAP not found in the project")
endif()
+
+file(STRINGS "${project_file}" line REGEX "^ManifestDPIAware true")
+string(FIND "${line}" "true" output_index)
+if("${output_index}" EQUAL "-1")
+ message(FATAL_ERROR "ManifestDPIAware true not found in the project")
+else()
+ message(STATUS "Found DPI-aware")
+endif()