2019-02-28 12:17:11 +08:00
|
|
|
# RPM specifics
|
|
|
|
if(CPACK_GENERATOR MATCHES "RPM")
|
2019-03-02 06:13:16 +08:00
|
|
|
set(CPACK_PACKAGING_INSTALL_PREFIX "/")
|
2020-10-29 03:10:59 +08:00
|
|
|
set(CPACK_COMPONENTS_ALL clients-el7 server-el7 clients-versioned server-versioned)
|
2019-03-01 06:05:24 +08:00
|
|
|
set(CPACK_RESOURCE_FILE_README ${CMAKE_SOURCE_DIR}/README.md)
|
|
|
|
set(CPACK_RESOURCE_FILE_LICENSE ${CMAKE_SOURCE_DIR}/LICENSE)
|
2019-02-28 12:17:11 +08:00
|
|
|
elseif(CPACK_GENERATOR MATCHES "DEB")
|
2019-03-02 06:13:16 +08:00
|
|
|
set(CPACK_PACKAGING_INSTALL_PREFIX "/")
|
2020-10-29 02:55:15 +08:00
|
|
|
set(CPACK_COMPONENTS_ALL clients-deb server-deb clients-versioned server-versioned)
|
2019-03-01 06:05:24 +08:00
|
|
|
set(CPACK_RESOURCE_FILE_README ${CMAKE_SOURCE_DIR}/README.md)
|
|
|
|
set(CPACK_RESOURCE_FILE_LICENSE ${CMAKE_SOURCE_DIR}/LICENSE)
|
2019-02-28 12:17:11 +08:00
|
|
|
elseif(CPACK_GENERATOR MATCHES "TGZ")
|
|
|
|
set(CPACK_STRIP_FILES TRUE)
|
|
|
|
set(CPACK_COMPONENTS_ALL clients-tgz server-tgz)
|
2019-03-01 06:05:24 +08:00
|
|
|
set(CPACK_RESOURCE_FILE_README ${CMAKE_SOURCE_DIR}/README.md)
|
|
|
|
set(CPACK_RESOURCE_FILE_LICENSE ${CMAKE_SOURCE_DIR}/LICENSE)
|
2019-02-28 12:17:11 +08:00
|
|
|
else()
|
|
|
|
message(FATAL_ERROR "Unsupported package format ${CPACK_GENERATOR}")
|
|
|
|
endif()
|