[CMake] smarter shortcuts with NSIS

Andrea Crotti andrea.crotti.0 at gmail.com
Mon Feb 27 14:12:02 EST 2012


On 02/27/2012 05:51 PM, Eric Noulard wrote:
> 2012/2/27 John Drescher<drescherjm at gmail.com>:
>>> Ah yes you're right, last time I checked I didn't see them..
>>> Anyway my extra_commands don't appear anywhere in the nsi file, is that
>>> normal?
> No i'ts not.
> Did you set(CPACK_NSIS_EXTRA_INSTALL_COMMANDS ...)
>
> BEFORE

Actually I didn't.. Some time ago it was failing when including after, 
so I moved all the includes on top.
I'll change it again tomorrow then..
>
> include(CPack) ?
>
> The process is relatively simple.
>
> 0) Your CPACK_xxx vars are set and processed by the inclusion
>      of CPack.cmake (the include(CPack) of your CMakeLists.txt)
>
> 1) CPack NSIS generator "configures" the  NSIS.template.in
>      file by replacing occurences of CPACK_NSIS_... specific vars in there.
>
> 2) makensis is launched using the generated project.nsi
>
> CPack private installation of your project in a _CPackPackage subdir
> is done somewhere between 0) and 1).
>
> You need awkward extra escape in CPACK_NSIS_xxx because of the double
> CMake script processing 0) and 1).
>
> Is it clearer?

Ok now is clear thanks



More information about the CMake mailing list