mirror of
https://github.com/gelldur/EventBus.git
synced 2024-12-27 12:21:02 +08:00
Update and fix CPack
This commit is contained in:
parent
1146cebc55
commit
afc8cea23c
@ -8,16 +8,12 @@ project(EventBusDev)
|
||||
option(ENABLE_TEST "Enable test" ON)
|
||||
option(ENABLE_PERFORMANCE "Enable performance subproject" OFF)
|
||||
option(ENABLE_CPACK "Enable CPack packaging" ON)
|
||||
set(CPACK_GENERATOR "" CACHE STRING "Set packages CPack should build")
|
||||
|
||||
set(CMAKE_CXX_STANDARD 14)
|
||||
|
||||
add_subdirectory(lib/)
|
||||
|
||||
if(ENABLE_CPACK)
|
||||
include("lib/cmake/EventBus_CPack.cmake")
|
||||
enable_cpack("RPM;DEB;TGZ")
|
||||
endif()
|
||||
|
||||
if(ENABLE_TEST)
|
||||
enable_testing()
|
||||
add_subdirectory(test/)
|
||||
|
@ -109,3 +109,9 @@ install(EXPORT "${TARGETS_EXPORT_NAME}"
|
||||
DESTINATION "${config_install_dir}"
|
||||
NAMESPACE "${namespace}"
|
||||
)
|
||||
|
||||
# Cpack configuration
|
||||
if(ENABLE_CPACK)
|
||||
include("cmake/EventBus_CPack.cmake")
|
||||
enable_cpack()
|
||||
endif()
|
||||
|
@ -1,7 +1,6 @@
|
||||
# CPack Configuration
|
||||
function(enable_cpack generator)
|
||||
function(enable_cpack)
|
||||
set(CPACK_PACKAGE_VERSION ${PROJECT_VERSION})
|
||||
set(CPACK_GENERATOR ${generator})
|
||||
set(CPACK_PACKAGE_NAME ${PROJECT_NAME})
|
||||
set(CPACK_PACKAGE_RELEASE 1)
|
||||
set(CPACK_PACKAGE_CONTACT "gelldur")
|
||||
|
Loading…
x
Reference in New Issue
Block a user