mirror of
https://github.com/CLIUtils/CLI11.git
synced 2025-05-08 15:53:51 +00:00
fix: only use CPack if this is the main project (#902)
Alternative fix to, and closes #900. Signed-off-by: Henry Schreiner <henryschreineriii@gmail.com>
This commit is contained in:
parent
f0e405545c
commit
826415f8ba
@ -198,6 +198,7 @@ if(CMAKE_PROJECT_NAME STREQUAL PROJECT_NAME AND EXISTS "${CMAKE_CURRENT_SOURCE_D
|
||||
endif()
|
||||
|
||||
# Packaging support
|
||||
if(CMAKE_PROJECT_NAME STREQUAL PROJECT_NAME)
|
||||
set(CPACK_PACKAGE_VENDOR "github.com/CLIUtils/CLI11")
|
||||
set(CPACK_PACKAGE_CONTACT "https://${CPACK_PACKAGE_VENDOR}")
|
||||
set(CPACK_PACKAGE_VERSION_MAJOR ${PROJECT_VERSION_MAJOR}) # Automatic in CMake 3.12+
|
||||
@ -234,3 +235,4 @@ set(CPACK_DEBIAN_COMPRESSION_TYPE "xz")
|
||||
set(CPACK_DEBIAN_PACKAGE_NAME "libcli11-dev")
|
||||
|
||||
include(CPack)
|
||||
endif()
|
||||
|
Loading…
x
Reference in New Issue
Block a user