[CMake] SET (CPACK_PACKAGE_INSTALL_REGISTRY_KEY)
David Cole
david.cole at kitware.com
Sat Sep 18 08:10:17 EDT 2010
On Sat, Sep 18, 2010 at 3:02 AM, J Decker <d3ck0r at gmail.com> wrote:
> On Fri, Sep 17, 2010 at 10:59 AM, Nicky Perian <nickyperian at yahoo.com>
> wrote:
> > I have tried many variations to the HKEY_LOCAL_MACHINE setting and am
> unable
> > to get a run through of Cpack.
> > I know it must be something simple I am missing.
> > I need help with this.
> > I am on a windows 7 / 64bit machine. NSIS is unicode and installed in the
> 32
> > bit program files directory.
> > Thanks,
> > CMakeLists.txt:
> > if (WINDOWS)
> > # build a CPack driven installer package
> > SET (CPACK_GENERATOR "NSIS")
> > SET (CPACK_PACKAGE_INSTALL_REGISTRY_KEY
> > HKEY_LOCAL_MACHINE"/SOFTWARE/Wow6432Node/NSIS/Unicode")
>
> I really think you shouldn't include wow6432node - that is
> automaically applied when a 32 bit process writes values to the
> registry.
>
> > include (InstallRequiredSystemLibraries)
> > include (CPack)
> > endif (WINDOWS)
> > CPackConfig.cmake: (snip)
> > SET(CPACK_BINARY_NSIS "")
> > .
> > .
> > SET(CPACK_CMAKE_GENERATOR "Visual Studio 8 2005")
> > .
> > .
> > SET(CPACK_PACKAGE_INSTALL_REGISTRY_KEY
> > "HKEY_LOCAL_MACHINE"/SOFTWARE/Wow6432Node/NSIS/Unicode"")
> > Output:
> > C:\Phoenix\phoenix-work\indra\build-vc80>cpack cpackconfig.cmake
> > CPack Error: Cannot find NSIS registry value. This is usually caused by
> NSIS
> > not
> > being installed. Please install NSIS from http://nsis.sourceforge.net
> > CPack Error: Cannot initialize the generator NSIS
> >
> > _______________________________________________
> > Powered by www.kitware.com
> >
> > Visit other Kitware open-source projects at
> > http://www.kitware.com/opensource/opensource.html
> >
> > Please keep messages on-topic and check the CMake FAQ at:
> > http://www.cmake.org/Wiki/CMake_FAQ
> >
> > Follow this link to subscribe/unsubscribe:
> > http://www.cmake.org/mailman/listinfo/cmake
> >
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the CMake FAQ at:
> http://www.cmake.org/Wiki/CMake_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.cmake.org/mailman/listinfo/cmake
>
Do NOT set CPACK_PACKAGE_INSTALL_REGISTRY_KEY unless you really need a value
for it different than the default.
Please look at the definition of this variable in Modules/CPack.cmake. Its
default value is set like this:
cpack_set_if_not_set(CPACK_PACKAGE_INSTALL_REGISTRY_KEY
"${CPACK_PACKAGE_NAME} ${CPACK_PACKAGE_VERSION}")
The value is supposed to be a simple string, not a full reg key path. In the
NSIS template file, it's used to save some information about the
installation into the registry when the end user runs the installer. But the
usage of the value @CPACK_PACKAGE_INSTALL_REGISTRY_KEY@ in the NSIS template
file assumes that value may be used as a sub-key *already* under the "blah
blah/SOFTWARE/this/that" root key.
Do not try to use a full registry key path as the
CPACK_PACKAGE_INSTALL_REGISTRY_KEY.
What are you trying to do by setting this? Let us know, maybe somebody will
have a useful suggestion.
HTH,
David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20100918/21f93a50/attachment.htm>
More information about the CMake
mailing list