ENH: fix bitmap escapes

This commit is contained in:
Bill Hoffman 2007-10-22 17:16:33 -04:00
parent b6f1cb4edf
commit 617e6082fa
1 changed files with 9 additions and 3 deletions

View File

@ -183,15 +183,21 @@ cpack_set_if_not_set(CPACK_SOURCE_OUTPUT_CONFIG_FILE
cpack_set_if_not_set(CPACK_USE_DESTDIR ON)
cpack_set_if_not_set(CPACK_INSTALL_PREFIX "${CMAKE_INSTALL_PREFIX}")
cpack_encode_variables()
cpack_set_if_not_set(CPACK_NSIS_INSTALLER_ICON_CODE "")
# if CPACK_PACKAGE_ICON is set, then create a
# cpack variable that contains the NSIS code to define
# the CPACK_PACKAGE_ICON and MUI_HEADERIMAGE_BITMAP, this is used
# as an icon in the install wizard
if(CPACK_PACKAGE_ICON)
set(CPACK_NSIS_INSTALLER_ICON_CODE "
!define CPACK_PACKAGE_ICON "@CPACK_PACKAGE_ICON@
!define MUI_HEADERIMAGE_BITMAP "@CPACK_PACKAGE_ICON@
!define CPACK_PACKAGE_ICON \\\"@CPACK_PACKAGE_ICON@\\\"
!define MUI_HEADERIMAGE_BITMAP \\\"@CPACK_PACKAGE_ICON@\\\"
")
endif(CPACK_PACKAGE_ICON)
cpack_encode_variables()
configure_file("${cpack_input_file}" "${CPACK_OUTPUT_CONFIG_FILE}" @ONLY IMMEDIATE)