diff options
author | David Cole <david.cole@kitware.com> | 2008-10-10 21:08:00 (GMT) |
---|---|---|
committer | David Cole <david.cole@kitware.com> | 2008-10-10 21:08:00 (GMT) |
commit | c3976b0283c0594a2f1979585c03f0354b418511 (patch) | |
tree | 7a2ec3232171847bf3973a4fda0fb87ab9ee4e3a /Source/CPack | |
parent | 5a82a0b1084096b9ba0a769d3319ba804d20d227 (diff) | |
download | CMake-c3976b0283c0594a2f1979585c03f0354b418511.zip CMake-c3976b0283c0594a2f1979585c03f0354b418511.tar.gz CMake-c3976b0283c0594a2f1979585c03f0354b418511.tar.bz2 |
BUG: Fix issue #7800. Enable CPack to find the NSIS installer on Windows 2000.
Diffstat (limited to 'Source/CPack')
-rw-r--r-- | Source/CPack/cmCPackNSISGenerator.cxx | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/Source/CPack/cmCPackNSISGenerator.cxx b/Source/CPack/cmCPackNSISGenerator.cxx index 3072419..460ede9 100644 --- a/Source/CPack/cmCPackNSISGenerator.cxx +++ b/Source/CPack/cmCPackNSISGenerator.cxx @@ -348,13 +348,17 @@ int cmCPackNSISGenerator::InitializeInternal() "HKEY_LOCAL_MACHINE\\SOFTWARE\\NSIS", nsisPath, cmsys::SystemTools::KeyWOW64_32) ) { - cmCPackLogger - (cmCPackLog::LOG_ERROR, - "Cannot find NSIS registry value. This is usually caused by NSIS " - "not being installed. Please install NSIS from " - "http://nsis.sourceforge.net" - << std::endl); - return 0; + if ( !cmsys::SystemTools::ReadRegistryValue( + "HKEY_LOCAL_MACHINE\\SOFTWARE\\NSIS", nsisPath) ) + { + cmCPackLogger + (cmCPackLog::LOG_ERROR, + "Cannot find NSIS registry value. This is usually caused by NSIS " + "not being installed. Please install NSIS from " + "http://nsis.sourceforge.net" + << std::endl); + return 0; + } } path.push_back(nsisPath); #endif |