summaryrefslogtreecommitdiff
path: root/Modules/Internal
diff options
context:
space:
mode:
authorAndras Lasso <lasso@queensu.ca>2021-09-13 19:45:46 -0400
committerBrad King <brad.king@kitware.com>2021-09-14 09:52:19 -0400
commiteb3b3bacdc93e44d942af912ac5a5b16cfa9813a (patch)
treeabfc357aa40c86d575f4b2cd0680ec29e699a7c2 /Modules/Internal
parent253f31f5efb27215049c81a0aff4c67b37a378d5 (diff)
downloadcmake-eb3b3bacdc93e44d942af912ac5a5b16cfa9813a.tar.gz
CPack/NSIS: Fix uninstall on Windows using "Apps & Features"
According to NSIS documentation [1], uninstaller executable path in UninstallString must always be quoted. Quote the uninstall executable in `NSIS.template.in` so that it works when the path has spaces. [1] https://nsis.sourceforge.io/Add_uninstall_information_to_Add/Remove_Programs
Diffstat (limited to 'Modules/Internal')
-rw-r--r--Modules/Internal/CPack/NSIS.template.in2
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/Internal/CPack/NSIS.template.in b/Modules/Internal/CPack/NSIS.template.in
index 1df8a5885f..8a0c9726c9 100644
--- a/Modules/Internal/CPack/NSIS.template.in
+++ b/Modules/Internal/CPack/NSIS.template.in
@@ -674,7 +674,7 @@ Section "-Core installation"
Push "@CPACK_PACKAGE_VENDOR@"
Call ConditionalAddToRegisty
Push "UninstallString"
- Push "$INSTDIR\@CPACK_NSIS_UNINSTALL_NAME@.exe"
+ Push "$\"$INSTDIR\@CPACK_NSIS_UNINSTALL_NAME@.exe$\""
Call ConditionalAddToRegisty
Push "NoRepair"
Push "1"