[CMake] CPack NSIS no branding image

David Cole david.cole at kitware.com
Mon Jun 2 11:46:07 EDT 2008


Try:
  SET(CPACK_PACKAGE_ICON "${CMAKE_SOURCE_DIR}\\\\test.bmp")

There is a "bug" in the NSIS installer that refuses to extract the file name
properly when there are only "/" forward slashes in the file name...


HTH,
David


On Sun, Jun 1, 2008 at 5:48 PM, Torsten Grote <Torsten.Grote at gmx.de> wrote:

> Hi all,
>
> it seems impossible to build a NSIS installer using CMake. I tried v2.6.0
> and the latest CVS version.
> After a "make package" I get a CPack Error. The log file NSISOutput.log
> gives me:
>
> [snip]
> !insertmacro: MUI_LANGUAGE
>
> Error: no branding image found in chosen UI!
> Error in macro MUI_HEADERIMAGE_INIT on macroline 27
> Error in macro MUI_GUIINIT on macroline 3
> Error in macro MUI_FUNCTION_GUIINIT on macroline 4
> Error in macro MUI_INSERT on macroline 11
> Error in macro MUI_LANGUAGE on macroline 7
> Error in script
> "/home/xyz/tmp/cmake/build/_CPack_Packages/win32/NSIS/project.nsi" on line
> 438 -- aborting creation process
> [/snip]
>
> I am on a 64bit GNU/Linux, crosscompiling my project for Windows with
> mingw32. I managed to reproduce the error with a minimal(! enough to trigger
> the error) test project. The CMakeLists.txt file follows.
>
> ADD_EXECUTABLE(hello wintest.c)
>
> INCLUDE(InstallRequiredSystemLibraries)
>
> SET(CPACK_PACKAGE_DESCRIPTION_SUMMARY "My funky project")
> SET(CPACK_PACKAGE_VENDOR "Me, myself, and I")
> SET(CPACK_PACKAGE_VERSION_MAJOR "1")
> SET(CPACK_PACKAGE_VERSION_MINOR "3")
> SET(CPACK_PACKAGE_VERSION_PATCH "2")
> SET(CPACK_PACKAGE_INSTALL_DIRECTORY "CMake
> ${CMake_VERSION_MAJOR}.${CMake_VERSION_MINOR}")
>
> IF(WIN32 AND NOT UNIX)
>  SET(CPACK_GENERATOR "NSIS")
>  SET(CPACK_PACKAGE_ICON "${CMAKE_SOURCE_DIR}/test.bmp")
> ENDIF(WIN32 AND NOT UNIX)
>
> INCLUDE(CPack)
>
> The image test.bmp exists and is a Windows bmp file. I checked the wiki and
> the sparse documentation, but was unable to find any clue.
> If you have any ideas, please let me now!
>
> Thanks and Regards,
> Torsten
> _______________________________________________
> CMake mailing list
> CMake at cmake.org
> http://www.cmake.org/mailman/listinfo/cmake
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20080602/622236b1/attachment-0001.htm>


More information about the CMake mailing list