From 4903b698a97fd4c0ba6273098c97bc5182c84138 Mon Sep 17 00:00:00 2001 From: KOLANICH Date: Mon, 13 Jan 2020 15:40:34 +0000 Subject: [PATCH] Enhancements in building deb packages: (#399) * Fixed building deb packages, broken because of lack contact field. * Added some missing metadata. * Set the name according to the convention. --- CLI11.CPack.Description.txt | 2 ++ CMakeLists.txt | 7 +++++++ conanfile.py | 1 + 3 files changed, 10 insertions(+) create mode 100644 CLI11.CPack.Description.txt diff --git a/CLI11.CPack.Description.txt b/CLI11.CPack.Description.txt new file mode 100644 index 00000000..1fd074a4 --- /dev/null +++ b/CLI11.CPack.Description.txt @@ -0,0 +1,2 @@ +CLI11 provides all the features you expect in a powerful command line parser, with a beautiful, minimal syntax and no dependencies beyond C++11. It is header only, and comes in a single file form for easy inclusion in projects. It is easy to use for small projects, but powerful enough for complex command line projects, and can be customized for frameworks. + diff --git a/CMakeLists.txt b/CMakeLists.txt index cbb89539..e5945f93 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -271,10 +271,12 @@ endif() # Packaging support # Packaging support set(CPACK_PACKAGE_VENDOR "github.com/CLIUtils/CLI11") +set(CPACK_PACKAGE_CONTACT "https://${CPACK_PACKAGE_VENDOR}") set(CPACK_PACKAGE_VERSION ${PROJECT_VERSION}) set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "Command line parser with simple and intuitive interface") set(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_CURRENT_SOURCE_DIR}/LICENSE") set(CPACK_RESOURCE_FILE_README "${CMAKE_CURRENT_SOURCE_DIR}/README.md") +set(CPACK_PACKAGE_DESCRIPTION_FILE "${CMAKE_CURRENT_SOURCE_DIR}/CLI11.CPack.Description.txt") set(CPACK_SOURCE_GENERATOR "TGZ;ZIP") # CPack collects *everything* except what's listed here. set(CPACK_SOURCE_IGNORE_FILES @@ -286,5 +288,10 @@ set(CPACK_SOURCE_IGNORE_FILES /var /Pipfile.*$ ) + +set(CPACK_PACKAGE_VERSION ${PROJECT_VERSION}) +set(CPACK_DEBIAN_PACKAGE_ARCHITECTURE "all") +set(CPACK_DEBIAN_COMPRESSION_TYPE "xz") +set(CPACK_DEBIAN_PACKAGE_NAME "libcli11-dev") include(CPack) diff --git a/conanfile.py b/conanfile.py index 54c1d5ad..6ce8a01e 100644 --- a/conanfile.py +++ b/conanfile.py @@ -30,6 +30,7 @@ class CLI11Conan(ConanFile): "extern/*", "cmake/*", "CMakeLists.txt", + "CLI11.CPack.Description.txt", "tests/*", )