CMakeCPackOptions.cmake.in 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990
  1. # This file is configured at cmake time, and loaded at cpack time.
  2. # To pass variables to cpack from cmake, they must be configured
  3. # in this file.
  4. if(CPACK_GENERATOR MATCHES "NSIS")
  5. set(CPACK_NSIS_INSTALL_ROOT "@CPACK_NSIS_INSTALL_ROOT@")
  6. # set the install/unistall icon used for the installer itself
  7. # There is a bug in NSI that does not handle full unix paths properly.
  8. set(CPACK_NSIS_MUI_ICON "@CMake_SOURCE_DIR@/Utilities/Release\\CMakeLogo.ico")
  9. set(CPACK_NSIS_MUI_UNIICON "@CMake_SOURCE_DIR@/Utilities/Release\\CMakeLogo.ico")
  10. # set the package header icon for MUI
  11. set(CPACK_PACKAGE_ICON "@CMake_SOURCE_DIR@/Utilities/Release\\CMakeInstall.bmp")
  12. # tell cpack to create links to the doc files
  13. set(CPACK_NSIS_MENU_LINKS
  14. "@CMAKE_DOC_DIR@/html/index.html" "CMake Documentation"
  15. "http://www.cmake.org" "CMake Web Site"
  16. )
  17. # Use the icon from cmake-gui for add-remove programs
  18. set(CPACK_NSIS_INSTALLED_ICON_NAME "bin\\cmake-gui.exe")
  19. set(CPACK_NSIS_PACKAGE_NAME "@CPACK_NSIS_PACKAGE_NAME@")
  20. set(CPACK_NSIS_DISPLAY_NAME "@CPACK_NSIS_PACKAGE_NAME@, a cross-platform, open-source build system")
  21. set(CPACK_NSIS_HELP_LINK "http://www.cmake.org")
  22. set(CPACK_NSIS_URL_INFO_ABOUT "http://www.kitware.com")
  23. set(CPACK_NSIS_CONTACT @CPACK_PACKAGE_CONTACT@)
  24. set(CPACK_NSIS_MODIFY_PATH ON)
  25. endif()
  26. # include the cpack options for qt dialog if they exist
  27. # they might not if qt was not enabled for the build
  28. include("@QT_DIALOG_CPACK_OPTIONS_FILE@" OPTIONAL)
  29. if(CPACK_GENERATOR MATCHES "IFW")
  30. # Installer configuration
  31. set(CPACK_IFW_PACKAGE_TITLE "CMake Build Tool")
  32. set(CPACK_IFW_PRODUCT_URL "http://www.cmake.org")
  33. @_CPACK_IFW_PACKAGE_ICON@
  34. set(CPACK_IFW_PACKAGE_WINDOW_ICON
  35. "@CMake_SOURCE_DIR@/Source/QtDialog/CMakeSetup128.png")
  36. # Package configuration group
  37. set(CPACK_IFW_PACKAGE_GROUP CMake)
  38. # Group configuration
  39. set(CPACK_COMPONENT_GROUP_CMAKE_DISPLAY_NAME
  40. "@CPACK_PACKAGE_NAME@")
  41. set(CPACK_COMPONENT_GROUP_CMAKE_DESCRIPTION
  42. "@CPACK_PACKAGE_DESCRIPTION_SUMMARY@")
  43. # IFW group configuration
  44. set(CPACK_IFW_COMPONENT_GROUP_CMAKE_VERSION
  45. "@_CPACK_IFW_PACKAGE_VERSION@")
  46. set(CPACK_IFW_COMPONENT_GROUP_CMAKE_LICENSES
  47. "@CPACK_PACKAGE_NAME@ Copyright" "@CPACK_RESOURCE_FILE_LICENSE@")
  48. @_CPACK_IFW_PACKAGE_SCRIPT@
  49. endif()
  50. if(CPACK_GENERATOR MATCHES "CygwinSource")
  51. # when packaging source make sure the .build directory is not included
  52. set(CPACK_SOURCE_IGNORE_FILES
  53. "/CVS/" "/\\.build/" "/\\.svn/" "\\.swp$" "\\.#" "/#" "~$")
  54. endif()
  55. if("${CPACK_GENERATOR}" STREQUAL "PackageMaker")
  56. if(CMAKE_PACKAGE_QTGUI)
  57. set(CPACK_PACKAGE_DEFAULT_LOCATION "/Applications")
  58. else()
  59. set(CPACK_PACKAGE_DEFAULT_LOCATION "/usr")
  60. endif()
  61. endif()
  62. if("${CPACK_GENERATOR}" STREQUAL "WIX")
  63. # Reset CPACK_PACKAGE_VERSION to deal with WiX restriction.
  64. # But the file names still use the full CMake_VERSION value:
  65. set(CPACK_PACKAGE_FILE_NAME
  66. "${CPACK_PACKAGE_NAME}-@CMake_VERSION@-${CPACK_SYSTEM_NAME}")
  67. set(CPACK_SOURCE_PACKAGE_FILE_NAME
  68. "${CPACK_PACKAGE_NAME}-@CMake_VERSION@-Source")
  69. if(NOT CPACK_WIX_SIZEOF_VOID_P)
  70. set(CPACK_WIX_SIZEOF_VOID_P "@CMAKE_SIZEOF_VOID_P@")
  71. endif()
  72. set(CPACK_PACKAGE_VERSION
  73. "@CMake_VERSION_MAJOR@.@CMake_VERSION_MINOR@")
  74. # WIX installers require at most a 4 component version number, where
  75. # each component is an integer between 0 and 65534 inclusive
  76. set(patch "@CMake_VERSION_PATCH@")
  77. if(patch MATCHES "^[0-9]+$" AND patch LESS 65535)
  78. set(CPACK_PACKAGE_VERSION "${CPACK_PACKAGE_VERSION}.${patch}")
  79. endif()
  80. endif()