summaryrefslogtreecommitdiffstats
path: root/Source/CPack/cmCPackNSISGenerator.cxx
diff options
context:
space:
mode:
authorDavid Golub <golubdr@gmail.com>2012-05-09 19:33:44 (GMT)
committerDavid Cole <david.cole@kitware.com>2012-11-20 01:08:31 (GMT)
commit6ff730a4983d15f3e115a919eb18d866f8c65507 (patch)
tree794fb247cc13601800b312228dbf72872e79bbbb /Source/CPack/cmCPackNSISGenerator.cxx
parent51da766a6d85397f9244f5ec426091848d9318ff (diff)
downloadCMake-6ff730a4983d15f3e115a919eb18d866f8c65507.zip
CMake-6ff730a4983d15f3e115a919eb18d866f8c65507.tar.gz
CMake-6ff730a4983d15f3e115a919eb18d866f8c65507.tar.bz2
CPack/NSIS: Add support for 64-bit NSIS (#13203)
Diffstat (limited to 'Source/CPack/cmCPackNSISGenerator.cxx')
-rw-r--r--Source/CPack/cmCPackNSISGenerator.cxx18
1 files changed, 17 insertions, 1 deletions
diff --git a/Source/CPack/cmCPackNSISGenerator.cxx b/Source/CPack/cmCPackNSISGenerator.cxx
index fdbae35..9f86ea2 100644
--- a/Source/CPack/cmCPackNSISGenerator.cxx
+++ b/Source/CPack/cmCPackNSISGenerator.cxx
@@ -33,8 +33,9 @@
#endif
//----------------------------------------------------------------------
-cmCPackNSISGenerator::cmCPackNSISGenerator()
+cmCPackNSISGenerator::cmCPackNSISGenerator(bool nsis64)
{
+ Nsis64 = nsis64;
}
//----------------------------------------------------------------------
@@ -359,6 +360,21 @@ int cmCPackNSISGenerator::InitializeInternal()
bool gotRegValue = false;
#ifdef _WIN32
+ if (Nsis64)
+ {
+ if ( !gotRegValue && cmsys::SystemTools::ReadRegistryValue(
+ "HKEY_LOCAL_MACHINE\\SOFTWARE\\NSIS\\Unicode", nsisPath,
+ cmsys::SystemTools::KeyWOW64_64) )
+ {
+ gotRegValue = true;
+ }
+ if ( !gotRegValue && cmsys::SystemTools::ReadRegistryValue(
+ "HKEY_LOCAL_MACHINE\\SOFTWARE\\NSIS", nsisPath,
+ cmsys::SystemTools::KeyWOW64_64) )
+ {
+ gotRegValue = true;
+ }
+ }
if ( !gotRegValue && cmsys::SystemTools::ReadRegistryValue(
"HKEY_LOCAL_MACHINE\\SOFTWARE\\NSIS\\Unicode", nsisPath,
cmsys::SystemTools::KeyWOW64_32) )