From e9499629893f71ac579210b9e8e934b9e648200a Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Sat, 5 Dec 2020 11:51:27 +0100 Subject: [PATCH 01/32] cpack: generate modular debian packages --- CMakeLists.txt | 2 +- doc/CMakeLists.txt | 24 +-- doc/help/CMakeLists.txt | 4 +- scripts/CMakeLists.txt | 24 +-- scripts/admin/CMakeLists.txt | 2 +- scripts/cmake/CMakeLists.txt | 4 +- scripts/cmake/ElektraPackaging.cmake | 168 +++++++++++++++++- scripts/cmake/Modules/LibAddLib.cmake | 3 +- scripts/cmake/Modules/LibAddMacros.cmake | 11 +- scripts/cmake/Modules/LibAddPlugin.cmake | 16 +- scripts/cmake/Modules/LibAddTest.cmake | 2 +- scripts/completion/CMakeLists.txt | 13 +- scripts/ffconfig/CMakeLists.txt | 8 +- scripts/kdb/CMakeLists.txt | 25 ++- scripts/release/package.sh | 41 +++++ src/bindings/cpp/include/CMakeLists.txt | 2 +- .../intercept/env/examples/CMakeLists.txt | 2 +- .../intercept/env/include/CMakeLists.txt | 2 +- src/bindings/intercept/env/src/CMakeLists.txt | 6 +- src/bindings/intercept/fs/CMakeLists.txt | 4 +- src/bindings/swig/lua/CMakeLists.txt | 2 +- src/bindings/swig/python/CMakeLists.txt | 1 + src/include/CMakeLists.txt | 3 +- src/include/elektra/CMakeLists.txt | 2 +- src/libs/CMakeLists.txt | 2 +- src/libs/ease/CMakeLists.txt | 2 +- src/libs/elektra/CMakeLists.txt | 11 +- src/libs/globbing/CMakeLists.txt | 2 +- src/libs/highlevel/CMakeLists.txt | 6 +- src/libs/invoke/CMakeLists.txt | 2 +- src/libs/io/CMakeLists.txt | 5 +- src/libs/merge/CMakeLists.txt | 5 +- src/libs/meta/CMakeLists.txt | 2 +- src/libs/notification/CMakeLists.txt | 5 +- src/libs/opts/CMakeLists.txt | 2 +- src/libs/plugin/CMakeLists.txt | 2 +- src/libs/pluginprocess/CMakeLists.txt | 2 +- src/libs/tools/include/CMakeLists.txt | 6 +- src/libs/tools/src/CMakeLists.txt | 6 +- src/libs/utility/CMakeLists.txt | 2 +- src/plugins/CMakeLists.txt | 6 +- src/plugins/augeas/CMakeLists.txt | 3 +- src/plugins/base64/CMakeLists.txt | 3 +- src/plugins/blockresolver/CMakeLists.txt | 3 +- src/plugins/c/CMakeLists.txt | 3 +- src/plugins/cache/CMakeLists.txt | 3 +- src/plugins/ccode/CMakeLists.txt | 3 +- src/plugins/conditionals/CMakeLists.txt | 3 +- src/plugins/constants/CMakeLists.txt | 3 +- src/plugins/counter/CMakeLists.txt | 2 +- src/plugins/cpptemplate/CMakeLists.txt | 2 +- src/plugins/crypto/CMakeLists.txt | 3 +- src/plugins/csvstorage/CMakeLists.txt | 3 +- src/plugins/curlget/CMakeLists.txt | 3 +- src/plugins/date/CMakeLists.txt | 3 +- src/plugins/dbus/CMakeLists.txt | 3 +- src/plugins/dbusrecv/CMakeLists.txt | 6 +- src/plugins/desktop/CMakeLists.txt | 2 +- src/plugins/directoryvalue/CMakeLists.txt | 3 +- src/plugins/doc/CMakeLists.txt | 3 +- src/plugins/dpkg/CMakeLists.txt | 2 +- src/plugins/dump/CMakeLists.txt | 3 +- src/plugins/error/CMakeLists.txt | 2 +- src/plugins/fcrypt/CMakeLists.txt | 3 +- src/plugins/file/CMakeLists.txt | 3 +- src/plugins/filecheck/CMakeLists.txt | 3 +- src/plugins/fstab/CMakeLists.txt | 3 +- src/plugins/glob/CMakeLists.txt | 3 +- src/plugins/gopts/CMakeLists.txt | 3 +- src/plugins/gpgme/CMakeLists.txt | 3 +- src/plugins/hexcode/CMakeLists.txt | 3 +- src/plugins/hexnumber/CMakeLists.txt | 3 +- src/plugins/hosts/CMakeLists.txt | 3 +- src/plugins/iconv/CMakeLists.txt | 3 +- .../internalnotification/CMakeLists.txt | 3 +- src/plugins/ipaddr/CMakeLists.txt | 3 +- src/plugins/iterate/CMakeLists.txt | 3 +- src/plugins/journald/CMakeLists.txt | 3 +- src/plugins/kconfig/CMakeLists.txt | 3 +- src/plugins/keytometa/CMakeLists.txt | 3 +- src/plugins/line/CMakeLists.txt | 3 +- src/plugins/lineendings/CMakeLists.txt | 3 +- src/plugins/list/CMakeLists.txt | 3 +- src/plugins/logchange/CMakeLists.txt | 2 +- src/plugins/lua/CMakeLists.txt | 3 +- src/plugins/macaddr/CMakeLists.txt | 3 +- src/plugins/mathcheck/CMakeLists.txt | 3 +- src/plugins/mini/CMakeLists.txt | 3 +- src/plugins/mmapstorage/CMakeLists.txt | 5 +- src/plugins/mozprefs/CMakeLists.txt | 3 +- src/plugins/multifile/CMakeLists.txt | 3 +- src/plugins/network/CMakeLists.txt | 3 +- src/plugins/ni/CMakeLists.txt | 3 +- src/plugins/noresolver/CMakeLists.txt | 3 +- src/plugins/passwd/CMakeLists.txt | 3 +- src/plugins/path/CMakeLists.txt | 3 +- src/plugins/process/CMakeLists.txt | 3 +- src/plugins/profile/CMakeLists.txt | 3 +- src/plugins/python/CMakeLists.txt | 5 +- src/plugins/quickdump/CMakeLists.txt | 3 +- src/plugins/range/CMakeLists.txt | 3 +- src/plugins/reference/CMakeLists.txt | 3 +- src/plugins/rename/CMakeLists.txt | 3 +- src/plugins/resolver/CMakeLists.txt | 10 +- src/plugins/rgbcolor/CMakeLists.txt | 3 +- src/plugins/shell/CMakeLists.txt | 3 +- src/plugins/simpleini/CMakeLists.txt | 1 + src/plugins/spec/CMakeLists.txt | 3 +- src/plugins/specload/CMakeLists.txt | 3 +- src/plugins/sync/CMakeLists.txt | 3 +- src/plugins/syslog/CMakeLists.txt | 2 +- src/plugins/template/CMakeLists.txt | 3 +- src/plugins/timeofday/CMakeLists.txt | 2 +- src/plugins/toml/CMakeLists.txt | 3 +- src/plugins/tracer/CMakeLists.txt | 2 +- src/plugins/type/CMakeLists.txt | 3 +- src/plugins/uname/CMakeLists.txt | 3 +- src/plugins/unit/CMakeLists.txt | 3 +- src/plugins/validation/CMakeLists.txt | 3 +- src/plugins/wresolver/CMakeLists.txt | 3 +- src/plugins/xerces/CMakeLists.txt | 3 +- src/plugins/xmltool/CMakeLists.txt | 3 +- src/plugins/yajl/CMakeLists.txt | 3 +- src/plugins/yamlsmith/CMakeLists.txt | 3 +- src/plugins/zeromqrecv/CMakeLists.txt | 3 +- src/plugins/zeromqsend/CMakeLists.txt | 3 +- src/tools/kdb/CMakeLists.txt | 6 +- src/tools/qt-gui/CMakeLists.txt | 14 +- src/tools/race/CMakeLists.txt | 2 +- tests/CMakeLists.txt | 2 +- tests/shell/CMakeLists.txt | 16 +- tests/shell/external/CMakeLists.txt | 3 +- tests/shell/gen/CMakeLists.txt | 3 +- 133 files changed, 545 insertions(+), 198 deletions(-) create mode 100644 scripts/release/package.sh diff --git a/CMakeLists.txt b/CMakeLists.txt index 240f7b3dfae..afd087c8bc1 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -125,4 +125,4 @@ if (BUILD_FULL endif (BUILD_TESTING) endif () -install (FILES LICENSE.md DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER}) +install (FILES LICENSE.md DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} COMPONENT libelektra4) diff --git a/doc/CMakeLists.txt b/doc/CMakeLists.txt index dde36f14e4b..dc9046c4d5a 100644 --- a/doc/CMakeLists.txt +++ b/doc/CMakeLists.txt @@ -10,7 +10,7 @@ find_package (Doxygen QUIET) # file is the file name to set a dependency to # install is where it should be installed # ~~~ -macro (do_doc target folder file install) +macro (do_doc target folder file install target_component) # sometimes doxygen is too slow and fails with "Could not create output directory .../doc/html" file (MAKE_DIRECTORY ${folder}) @@ -20,7 +20,7 @@ macro (do_doc target folder file install) add_custom_target (${target} ALL DEPENDS ${folder}/${file}) if (INSTALL_DOCUMENTATION) - install (DIRECTORY ${folder} DESTINATION ${install}) + install (DIRECTORY ${folder} COMPONENT ${target_component} DESTINATION ${install}) endif (INSTALL_DOCUMENTATION) endmacro (do_doc) @@ -74,8 +74,8 @@ if (DOXYGEN_FOUND) OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile INPUT ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile) - do_doc (html ${OUTPUT_DIRECTORY}/html/ index.html ${TARGET_DOCUMENTATION_HTML_FOLDER}) - do_doc (man3 ${OUTPUT_DIRECTORY}/man/man3elektra/ kdb.3elektra "${TARGET_DOCUMENTATION_MAN_FOLDER};PATTERN;_*;EXCLUDE") + do_doc (html ${OUTPUT_DIRECTORY}/html/ index.html ${TARGET_DOCUMENTATION_HTML_FOLDER} elektra-doc) + do_doc (man3 ${OUTPUT_DIRECTORY}/man/man3elektra/ kdb.3elektra "${TARGET_DOCUMENTATION_MAN_FOLDER};PATTERN;_*;EXCLUDE" elektra-doc) add_dependencies (man3 html) set (outputs ${OUTPUT_DIRECTORY}/html/index.html ${OUTPUT_DIRECTORY}/man/man3elektra/kdb.3elektra) @@ -123,12 +123,12 @@ else (DOXYGEN_FOUND) endif (DOXYGEN_FOUND) if (INSTALL_DOCUMENTATION) - install (FILES BIGPICTURE.md DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER}) - install (FILES GOALS.md DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER}) - install (FILES METADATA.ini DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER}) - install (FILES SECURITY.md DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER}) - install (FILES AUTHORS.md DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER}) - install (FILES CONTRACT.ini DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER}) + install (FILES BIGPICTURE.md DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} COMPONENT libelektra4) + install (FILES GOALS.md DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} COMPONENT libelektra4) + install (FILES METADATA.ini DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} COMPONENT libelektra4) + install (FILES SECURITY.md DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} COMPONENT libelektra4) + install (FILES AUTHORS.md DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} COMPONENT libelektra4) + install (FILES CONTRACT.ini DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} COMPONENT libelektra4) set (news ${CMAKE_CURRENT_BINARY_DIR}/NEWS.md) file (GLOB files "news/*.md") file (REMOVE ${news}) @@ -136,8 +136,8 @@ if (INSTALL_DOCUMENTATION) file (READ ${file} content) file (APPEND ${news} "\n\n\n\n\n${content}") endforeach () - install (FILES ${news} DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER}) - install (FILES WHY.md DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER}) + install (FILES ${news} DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} COMPONENT libelektra4) + install (FILES WHY.md DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} COMPONENT libelektra4) endif () diff --git a/doc/help/CMakeLists.txt b/doc/help/CMakeLists.txt index e6e3d2684bb..ca2ca580b3c 100644 --- a/doc/help/CMakeLists.txt +++ b/doc/help/CMakeLists.txt @@ -16,7 +16,7 @@ file ( kdb*.md) foreach (FULLNAME ${KDBNAMES}) get_filename_component (NAME ${FULLNAME} NAME_WE) - generate_manpage (${NAME}) + generate_manpage (${NAME} COMPONENT elektra-bin) endforeach () file ( @@ -25,5 +25,5 @@ file ( elektra*.md) foreach (FULLNAME ${KDBNAMES}) get_filename_component (NAME ${FULLNAME} NAME_WE) - generate_manpage (${NAME} SECTION 7) + generate_manpage (${NAME} SECTION 7 COMPONENT elektra-doc) endforeach () diff --git a/scripts/CMakeLists.txt b/scripts/CMakeLists.txt index ab4f97af832..857c6123a82 100644 --- a/scripts/CMakeLists.txt +++ b/scripts/CMakeLists.txt @@ -8,31 +8,31 @@ endif (PROCESSOR_COUNT EQUAL 0) set (CMAKE_MAKE_PROGRAM_BASENAME ${CMAKE_MAKE_PROGRAM}) string (REGEX REPLACE ".*/([^/]+)$" "\\1" CMAKE_MAKE_PROGRAM_BASENAME ${CMAKE_MAKE_PROGRAM_BASENAME}) -install (PROGRAMS benchmark-createtree DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) +install (PROGRAMS benchmark-createtree DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin-extra) -install (PROGRAMS upgrade-bootstrap DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) +install (PROGRAMS upgrade-bootstrap DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin-extra) -install (PROGRAMS kdb/mountpoint-info DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) -install (PROGRAMS check-env-dep DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) +install (PROGRAMS kdb/mountpoint-info DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin-extra) +install (PROGRAMS check-env-dep DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-tests) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/make-source-package.in" "${CMAKE_CURRENT_BINARY_DIR}/make-source-package" @ONLY) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/configure-firefox.in" "${CMAKE_CURRENT_BINARY_DIR}/configure-firefox" @ONLY) -install (PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/configure-firefox" DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) +install (PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/configure-firefox" DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin-extra) add_subdirectory (ffconfig) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/change-resolver-symlink.in" "${CMAKE_CURRENT_BINARY_DIR}/change-resolver-symlink" @ONLY) -install (PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/change-resolver-symlink" DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) +install (PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/change-resolver-symlink" DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/change-storage-symlink.in" "${CMAKE_CURRENT_BINARY_DIR}/change-storage-symlink" @ONLY) -install (PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/change-storage-symlink" DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) +install (PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/change-storage-symlink" DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin) -install (PROGRAMS stash DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) -install (PROGRAMS restore DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) +install (PROGRAMS stash DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin) +install (PROGRAMS restore DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin) -install (PROGRAMS reset DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) -install (PROGRAMS reset-elektra DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) -install (PROGRAMS umount-all DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) +install (PROGRAMS reset DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin) +install (PROGRAMS reset-elektra DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin) +install (PROGRAMS umount-all DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin) add_custom_target ( source-package diff --git a/scripts/admin/CMakeLists.txt b/scripts/admin/CMakeLists.txt index 95dfcc2d38a..5ed72e24f54 100644 --- a/scripts/admin/CMakeLists.txt +++ b/scripts/admin/CMakeLists.txt @@ -1 +1 @@ -install (PROGRAMS update-snippet-repository DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) +install (PROGRAMS update-snippet-repository DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin-extra) diff --git a/scripts/cmake/CMakeLists.txt b/scripts/cmake/CMakeLists.txt index 157c5f20980..690295b9cfc 100644 --- a/scripts/cmake/CMakeLists.txt +++ b/scripts/cmake/CMakeLists.txt @@ -27,7 +27,7 @@ write_basic_package_version_file ( COMPATIBILITY AnyNewerVersion) install (FILES "${CMAKE_CURRENT_BINARY_DIR}/ElektraConfig.cmake" "${CMAKE_CURRENT_BINARY_DIR}/ElektraConfigVersion.cmake" - DESTINATION ${TARGET_CMAKE_FOLDER}) + DESTINATION ${TARGET_CMAKE_FOLDER} COMPONENT libelektra-dev) # pkg-config files if (BUILD_SHARED) @@ -42,7 +42,7 @@ elseif (BUILD_STATIC) endif () configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/elektra.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/elektra.pc" @ONLY) -install (FILES "${CMAKE_CURRENT_BINARY_DIR}/elektra.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER}) +install (FILES "${CMAKE_CURRENT_BINARY_DIR}/elektra.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} COMPONENT libelektra-dev) add_custom_target ( uninstall diff --git a/scripts/cmake/ElektraPackaging.cmake b/scripts/cmake/ElektraPackaging.cmake index e9a97cd7866..e0cde75f048 100644 --- a/scripts/cmake/ElektraPackaging.cmake +++ b/scripts/cmake/ElektraPackaging.cmake @@ -7,6 +7,37 @@ set (PROJECT_VERSION "${KDB_VERSION}") set (CPACK_PACKAGE_VERSION "${PROJECT_VERSION}") set (CPACK_DEBIAN_PACKAGE_VERSION "${PROJECT_VERSION}") +set ( + CPACK_COMPONENTS_ALL + libelektra4 + libelektra4-all + libelektra4-full + libelektra4-experimental + libelektra4-extra + libelektra4-augeas + libelektra4-crypto + libelektra4-curl + libelektra4-dbus + libelektra-dev + libelektra4-journald + libelektra4-lua + libelektra4-python + libelektra4-xerces + libelektra4-xmltool + libelektra4-yajl + libelektra4-zeromq + lua-elektra + python3-elektra + elektra-bin + elektra-bin-extra + elektra-doc + elektra-qt-gui + elektra-tests) + +set (CMAKE_BUILD_WITH_INSTALL_RPATH 1) + +list(APPEND CMAKE_INSTALL_RPATH "${CMAKE_CURRENT_BINARY_DIR}") + set ( PACKAGE_DESCRIPTION "Elektra provides a universal and secure framework to store configuration parameters in a global, hierarchical key database. The core is a small library implemented in C. The plugin-based framework fulfills many configuration-related tasks to avoid any unnecessary code duplication across applications while it still allows the core to stay without any external dependency. Elektra abstracts from cross-platform-related issues with an consistent API, and allows applications to be aware of other applications' configurations, leveraging easy application integration." @@ -63,7 +94,142 @@ if (UNIX) set (CPACK_DEBIAN_PACKAGE_PRIORITY "optional") set (CPACK_DEBIAN_PACKAGE_SECTION "libs") set (CPACK_DEBIAN_PACKAGE_RECOMMENDS "") - set (CPACK_DEBIAN_PACKAGE_DEPENDS " ") # no dependencies without any PLUGINS + set (CPACK_DEBIAN_PACKAGE_DEPENDS "") # no dependencies without any PLUGINS + + set (CPACK_DEB_COMPONENT_INSTALL "ON") + set (CPACK_DEB_PACKAGE_COMPONENT "ON") + set (CPACK_DEBIAN_ENABLE_COMPONENT_DEPENDS "ON") + set (CPACK_DEBIAN_RUNTIME_DEBUGINFO_PACKAGE "ON") + + set (CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_NAME "libelektra4") + set (CPACK_COMPONENT_LIBELEKTRA4_DISPLAY_NAME "") + set (CPACK_COMPONENT_LIBELEKTRA4_DESCRIPTION "") + + set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_NAME "libelektra4-full") + set (CPACK_COMPONENT_LIBELEKTRA4-FULL_DISPLAY_NAME "") + set (CPACK_COMPONENT_LIBELEKTRA4-FULL_DESCRIPTION "") + + set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_PACKAGE_NAME "libelektra4-experimental") + set (CPACK_COMPONENT_LIBELEKTRA4-EXPERIMENTAL_DISPLAY_NAME "") + set (CPACK_COMPONENT_LIBELEKTRA4-EXPERIMENTAL_DESCRIPTION "") + + set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_PACKAGE_NAME "libelektra4-extra") + set (CPACK_COMPONENT_LIBELEKTRA4-EXTRA_DISPLAY_NAME "") + set (CPACK_COMPONENT_LIBELEKTRA4-EXTRA_DESCRIPTION "") + + set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_NAME "elektra-bin") + set (CPACK_COMPONENT_ELEKTRA-BIN_DISPLAY_NAME "") + set (CPACK_COMPONENT_ELEKTRA-BIN_DESCRIPTION "") + set (CPACK_COMPONENT_ELEKTRA-BIN_DEPENDS "libelektra4") + + set (CPACK_DEBIAN_LIBELEKTRA4-AUGEAS_PACKAGE_NAME "libelektra4-augeas") + set (CPACK_COMPONENT_LIBELEKTRA4-AUGEAS_DISPLAY_NAME "") + set (CPACK_COMPONENT_LIBELEKTRA4-AUGEAS_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-AUGEAS_DEPENDS "libelektra4") + + set (CPACK_DEBIAN_LIBELEKTRA4-DBUS_PACKAGE_NAME "libelektra4-dbus") + set (CPACK_COMPONENT_LIBELEKTRA4-DBUS_DISPLAY_NAME "") + set (CPACK_COMPONENT_LIBELEKTRA4-DBUS_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-DBUS_DEPENDS "libelektra4") + + set (CPACK_DEBIAN_LIBELEKTRA-DEV_PACKAGE_NAME "libelektra-dev") + set (CPACK_COMPONENT_LIBELEKTRA-DEV_DISPLAY_NAME "") + set (CPACK_COMPONENT_LIBELEKTRA-DEV_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-DBUS_DEPENDS "libelektra4") + + set (CPACK_DEBIAN_LIBELEKTRA4-ZEROMQ_PACKAGE_NAME "libelektra4-zeromq") + set (CPACK_COMPONENT_LIBELEKTRA4-ZEROMQ_DISPLAY_NAME "") + set (CPACK_COMPONENT_LIBELEKTRA4-ZEROMQ_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-ZEROMQ_DEPENDS "libelektra4") + + set (CPACK_DEBIAN_LIBELEKTRA4-XMLTOOL_PACKAGE_NAME "libelektra4-xmltool") + set (CPACK_COMPONENT_LIBELEKTRA4-XMLTOOL_DISPLAY_NAME "") + set (CPACK_COMPONENT_LIBELEKTRA4-XMLTOOL_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-XMLTOOL_DEPENDS "libelektra4") + + set (CPACK_DEBIAN_LIBELEKTRA4-XERCES_PACKAGE_NAME "libelektra4-xerces") + set (CPACK_COMPONENT_LIBELEKTRA4-XERCES_DISPLAY_NAME "") + set (CPACK_COMPONENT_LIBELEKTRA4-XERCES_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-XERCES_DEPENDS "libelektra4") + + set (CPACK_DEBIAN_LIBELEKTRA4-YAJL_PACKAGE_NAME "libelektra4-yajl") + set (CPACK_COMPONENT_LIBELEKTRA4-YAJL_DISPLAY_NAME "") + set (CPACK_COMPONENT_LIBELEKTRA4-YAJL_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-YAJL_DEPENDS "libelektra4") + + set (CPACK_DEBIAN_LIBELEKTRA4-CRYPTO_PACKAGE_NAME "libelektra4-crypto") + set (CPACK_COMPONENT_LIBELEKTRA4-CRYPTO_DISPLAY_NAME "") + set (CPACK_COMPONENT_LIBELEKTRA4-CRYPTO_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-CRYPTO_DEPENDS "libelektra4") + + set (CPACK_DEBIAN_LIBELEKTRA4-CURL_PACKAGE_NAME "libelektra4-curl") + set (CPACK_COMPONENT_LIBELEKTRA4-CURL_DISPLAY_NAME "") + set (CPACK_COMPONENT_LIBELEKTRA4-CURL_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-CURL_DEPENDS "libelektra4") + + set (CPACK_DEBIAN_LIBELEKTRA4-JOURNALD_PACKAGE_NAME "libelektra4-journald") + set (CPACK_COMPONENT_LIBELEKTRA4-JOURNALD_DISPLAY_NAME "") + set (CPACK_COMPONENT_LIBELEKTRA4-JOURNALD_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-JOURNALD_DEPENDS "libelektra4") + + set (CPACK_DEBIAN_LIBELEKTRA4-LUA_PACKAGE_NAME "libelektra4-lua") + set (CPACK_COMPONENT_LIBELEKTRA4-LUA_DISPLAY_NAME "") + set (CPACK_COMPONENT_LIBELEKTRA4-LUA_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-LUA_DEPENDS "libelektra4") + + set (CPACK_DEBIAN_LUA-ELEKTRA_PACKAGE_NAME "lua-elektra") + set (CPACK_COMPONENT_LUA-ELEKTRA_DISPLAY_NAME "") + set (CPACK_COMPONENT_LUA-ELEKTRA_DESCRIPTION "") + set (CPACK_COMPONENT_LUA-ELEKTRA_DEPENDS "libelektra4") + + # maybe add python3:depends? (see control file) + set (CPACK_DEBIAN_PYTHON3-ELEKTRA_PACKAGE_NAME "python3-elektra") + set (CPACK_COMPONENT_PYTHON3-ELEKTRA_DISPLAY_NAME "") + set (CPACK_COMPONENT_PYTHON3-ELEKTRA_DESCRIPTION "") + set (CPACK_COMPONENT_PYTHON3-ELEKTRA_DEPENDS "libelektra4") + + set (CPACK_DEBIAN_LIBELEKTRA4-PYTHON_PACKAGE_NAME "libelektra4-python") + set (CPACK_COMPONENT_LIBELEKTRA4-PYTHON_DISPLAY_NAME "") + set (CPACK_COMPONENT_LIBELEKTRA4-PYTHON_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-PYTHON_DEPENDS "libelektra4" "python3-elektra") + + set (CPACK_DEBIAN_ELEKTRA-BIN-EXTRA_PACKAGE_NAME "elektra-bin-extra") + set (CPACK_COMPONENT_ELEKTRA-BIN-EXTRA_DISPLAY_NAME "") + set (CPACK_COMPONENT_LEKTRA-BIN-EXTRA_DESCRIPTION "") + set (CPACK_COMPONENT_ELEKTRA-BIN-EXTRA_DEPENDS "libelektra4") + set (CPACK_DEBIAN_ELEKTRA-BIN-EXTRA_PACKAGE_DEPENDS "python-all") + + set (CPACK_DEBIAN_ELEKTRA-QT-GUI_PACKAGE_NAME "elektra-qt-gui") + set (CPACK_COMPONENT_ELEKTRA-QT-GUI_DISPLAY_NAME "") + set (CPACK_COMPONENT_ELEKTRA-QT-GUI_DESCRIPTION "") + set (CPACK_COMPONENT_ELEKTRA-QT-GUI_DEPENDS "libelektra4") + # TODO: add condition for debian and ubuntu + set (CPACK_DEBIAN_ELEKTRA-QT-GUI_PACKAGE_DEPENDS "qml-module-qtquick2, qml-module-qtquick-window2, qml-module-qtquick-dialogs, qml-module-qt-labs-folderlistmodel, qml-module-qt-labs-settings") + + set (CPACK_DEBIAN_ELEKTRA-TESTS_PACKAGE_NAME "elektra-tests") + set (CPACK_COMPONENT_ELEKTRA-TESTS_DISPLAY_NAME "") + set (CPACK_COMPONENT_ELEKTRA-TESTS_DESCRIPTION "") + set (CPACK_COMPONENT_ELEKTRA-TESTS_DEPENDS "libelektra4-full" "elektra-bin") + + set (CPACK_DEBIAN_ELEKTRA-DOC_PACKAGE_NAME "elektra-doc") + set (CPACK_COMPONENT_ELEKTRA-DOC_DISPLAY_NAME "") + set (CPACK_COMPONENT_ELEKTRA-DOC_DESCRIPTION "") + + set (CPACK_DEBIAN_LIBELEKTRA4-ALL_PACKAGE_NAME "libelektra4-all") + set (CPACK_COMPONENT_LIBELEKTRA4-ALL_DISPLAY_NAME "") + set (CPACK_COMPONENT_LIBELEKTRA4-ALL_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-ALL_DEPENDS "libelektra4" "libelektra4-experimental" "libelektra4-augeas" "libelektra4-dbus" "libelektra4-zeromq" "libelektra4-lua" "libelektra4-python" "libelektra4-xmltool" "libelektra4-xerces" "libelektra4-yajl" "lua-elektra" "elektra-bin" "elektra-qt-gui" "libelektra4-crypto" "libelektra4-curl" "libelektra4-journald" "libelektra4-extra") + + # build debug package for each component + set (CPACK_DEBIAN_DEBUGINFO_PACKAGE "ON") + + set (CPACK_DEBIAN_PACKAGE_SHLIBDEPS "ON") + set (CPACK_DEBIAN_PACKAGE_GENERATE_SHLIBS "ON") + + + + #set (CPACK_DEBIAN_PACKAGE_GENERATE_SHLIBS_POLICY ">=") # Defaults to "=" + #set (CPACK_DEBIAN_PACKAGE_GENERATE_SHLIBS "ON") # We need to alter the architecture names as per distro rules if ("${CPACK_PACKAGE_ARCHITECTURE}" MATCHES "i[3-6]86") diff --git a/scripts/cmake/Modules/LibAddLib.cmake b/scripts/cmake/Modules/LibAddLib.cmake index 6ef59b807d4..23769d6b2ff 100644 --- a/scripts/cmake/Modules/LibAddLib.cmake +++ b/scripts/cmake/Modules/LibAddLib.cmake @@ -14,7 +14,7 @@ function (add_lib name) cmake_parse_arguments ( ARG "CPP" # optional keywords - "" # one value keywords + "COMPONENT" # one value keywords "SOURCES;LINK_LIBRARIES;LINK_ELEKTRA;INCLUDE_DIRECTORIES;INCLUDE_SYSTEM_DIRECTORIES;COMPILE_DEFINITIONS" # multi value # keywords ${ARGN}) @@ -58,6 +58,7 @@ function (add_lib name) install ( TARGETS elektra-${name} DESTINATION lib${LIB_SUFFIX} + COMPONENT "${ARG_COMPONENT}" EXPORT ElektraTargetsLibelektra) endif (BUILD_SHARED) diff --git a/scripts/cmake/Modules/LibAddMacros.cmake b/scripts/cmake/Modules/LibAddMacros.cmake index d736c75c1e2..c24b5295dad 100644 --- a/scripts/cmake/Modules/LibAddMacros.cmake +++ b/scripts/cmake/Modules/LibAddMacros.cmake @@ -17,7 +17,7 @@ endmacro (copy_file) # # create_lib_symlink src dest - create a symbolic link from src -> dest # ~~~ -macro (create_lib_symlink src dest) +macro (create_lib_symlink src dest component) cmake_parse_arguments ( ARG @@ -64,8 +64,9 @@ macro (create_lib_symlink src dest) if (RET) message (WARNING \"Could not install symlink\") endif () - ") -endmacro (create_lib_symlink src dest) + " + COMPONENT "${component}") +endmacro (create_lib_symlink src dest component) # ~~~ # Make a directory @@ -561,7 +562,7 @@ function (generate_manpage NAME) cmake_parse_arguments ( ARG "" # optional keywords - "SECTION;FILENAME" # one value keywords + "SECTION;FILENAME;COMPONENT" # one value keywords "" # multi value keywords ${ARGN}) @@ -603,7 +604,7 @@ If you do not add this file, then installing Elektra will fail!\n") endif (NOT EXISTS "${OUTFILE}") if (INSTALL_DOCUMENTATION) - install (FILES ${OUTFILE} DESTINATION share/man/man${SECTION}) + install (FILES ${OUTFILE} DESTINATION share/man/man${SECTION} COMPONENT "${ARG_COMPONENT}") endif () endif (BUILD_DOCUMENTATION) endfunction () diff --git a/scripts/cmake/Modules/LibAddPlugin.cmake b/scripts/cmake/Modules/LibAddPlugin.cmake index 5680f7652d5..2f5bdaef113 100644 --- a/scripts/cmake/Modules/LibAddPlugin.cmake +++ b/scripts/cmake/Modules/LibAddPlugin.cmake @@ -175,9 +175,9 @@ function (add_plugintest testname) # ~~~ if (INSTALL_TESTING) - install (TARGETS ${testexename} DESTINATION "${TARGET_TOOL_EXEC_FOLDER}") + install (TARGETS ${testexename} DESTINATION "${TARGET_TOOL_EXEC_FOLDER}" COMPONENT elektra-tests) if (ARG_INSTALL_TEST_DATA) - install (DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/${testname}" DESTINATION "${TARGET_TEST_DATA_FOLDER}") + install (DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/${testname}" DESTINATION "${TARGET_TEST_DATA_FOLDER}" COMPONENT elektra-tests) endif () endif (INSTALL_TESTING) @@ -402,7 +402,7 @@ function (add_plugin PLUGIN_SHORT_NAME) cmake_parse_arguments ( ARG "CPP;CPP_TEST;ADD_TEST;TEST_README;INSTALL_TEST_DATA;ONLY_SHARED" # optional keywords - "" # one value keywords + "COMPONENT" # one value keywords "${MULTI_VALUE_KEYWORDS}" # multi value keywords ${ARGN}) @@ -410,6 +410,8 @@ function (add_plugin PLUGIN_SHORT_NAME) set (PLUGIN_OBJS ${PLUGIN_NAME}-objects) set (PLUGIN_TARGET_OBJS "$") + message (STATUS "add_plugin component: ${COMPONENT}") + restore_variable (${PLUGIN_NAME} ARG_LINK_LIBRARIES) restore_variable (${PLUGIN_NAME} ARG_SOURCES) restore_variable (${PLUGIN_NAME} ARG_OBJECT_SOURCES) @@ -424,6 +426,9 @@ function (add_plugin PLUGIN_SHORT_NAME) restore_variable (${PLUGIN_NAME} ARG_TEST_REQUIRED_PLUGINS) restore_variable (${PLUGIN_NAME} ARG_INSTALL_TEST_DATA) restore_variable (${PLUGIN_NAME} ARG_ONLY_SHARED) + restore_variable (${PLUGIN_NAME} ARG_COMPONENT) + + message (STATUS "add_plugin restore_variable: ${ARG_COMPONENT}") if (ARG_UNPARSED_ARGUMENTS) message (FATAL_ERROR "Parsed a wrong argument to plugin ${PLUGIN_SHORT_NAME}: ${ARG_UNPARSED_ARGUMENTS}") @@ -433,7 +438,8 @@ function (add_plugin PLUGIN_SHORT_NAME) if (ARG_INSTALL_TEST_DATA AND NOT ARG_ADD_TEST) if (INSTALL_TESTING) install (DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/${PLUGIN_SHORT_NAME}" - DESTINATION "${TARGET_TEST_DATA_FOLDER}") + DESTINATION "${TARGET_TEST_DATA_FOLDER}" + COMPONENT elektra-tests) endif (INSTALL_TESTING) endif () @@ -616,7 +622,7 @@ function (add_plugin PLUGIN_SHORT_NAME) target_link_libraries (${PLUGIN_NAME} elektra-plugin) endif () target_link_libraries (${PLUGIN_NAME} ${ARG_LINK_LIBRARIES}) - install (TARGETS ${PLUGIN_NAME} DESTINATION lib${LIB_SUFFIX}/${TARGET_PLUGIN_FOLDER}) + install (TARGETS ${PLUGIN_NAME} DESTINATION lib${LIB_SUFFIX}/${TARGET_PLUGIN_FOLDER} COMPONENT "${ARG_COMPONENT}") set_property ( TARGET ${PLUGIN_NAME} APPEND diff --git a/scripts/cmake/Modules/LibAddTest.cmake b/scripts/cmake/Modules/LibAddTest.cmake index fee3ef72f0b..f956be5b383 100644 --- a/scripts/cmake/Modules/LibAddTest.cmake +++ b/scripts/cmake/Modules/LibAddTest.cmake @@ -48,7 +48,7 @@ macro (add_gtest source) include_directories (${CMAKE_SOURCE_DIR}/tests/gtest-framework) if (INSTALL_TESTING) - install (TARGETS ${source} DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) + install (TARGETS ${source} DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-tests) endif (INSTALL_TESTING) set_target_properties (${source} PROPERTIES COMPILE_DEFINITIONS HAVE_KDBCONFIG_H) diff --git a/scripts/completion/CMakeLists.txt b/scripts/completion/CMakeLists.txt index df9000cdf46..05e894146a5 100644 --- a/scripts/completion/CMakeLists.txt +++ b/scripts/completion/CMakeLists.txt @@ -1,7 +1,7 @@ file (READ "kdb_zsh_completion" CONTENT_OF_ZSH_COMP) file (READ "kdb-bash-completion" CONTENT_OF_BASH_COMP) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/install-sh-completion.in" "${CMAKE_CURRENT_BINARY_DIR}/install-sh-completion" @ONLY) -install (PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/install-sh-completion" DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) +install (PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/install-sh-completion" DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin) if (INSTALL_SYSTEM_FILES) if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin") @@ -29,7 +29,8 @@ if (INSTALL_SYSTEM_FILES) install ( FILES kdb-bash-completion DESTINATION ${BASH_COMPLETION_COMPLETIONSDIR} - RENAME kdb) + RENAME kdb + COMPONENT elektra-bin) if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin") set (FISH_COMPLETION_COMPLETIONSDIR "/usr/local/share/fish/completions") else () @@ -42,7 +43,7 @@ if (INSTALL_SYSTEM_FILES) pkg_get_variable (FISH_COMPLETION_COMPLETIONSDIR fish completionsdir) endif () endif () - install (FILES kdb.fish DESTINATION ${FISH_COMPLETION_COMPLETIONSDIR}) + install (FILES kdb.fish DESTINATION ${FISH_COMPLETION_COMPLETIONSDIR} COMPONENT elektra-bin) if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin") @@ -51,13 +52,15 @@ if (INSTALL_SYSTEM_FILES) install ( FILES kdb_zsh_completion DESTINATION /usr/local/share/zsh/site-functions - RENAME _kdb) + RENAME _kdb + COMPONENT elektra-bin) else () # This Folder is at least the valid folder for Debian install ( FILES kdb_zsh_completion DESTINATION /usr/share/zsh/vendor-completions - RENAME _kdb) + RENAME _kdb + COMPONENT elektra-bin) endif () endif () diff --git a/scripts/ffconfig/CMakeLists.txt b/scripts/ffconfig/CMakeLists.txt index c17fca4c1e1..b0bdb48ac04 100644 --- a/scripts/ffconfig/CMakeLists.txt +++ b/scripts/ffconfig/CMakeLists.txt @@ -1,4 +1,4 @@ -install (PROGRAMS writeConfigFiles DESTINATION "${TARGET_TOOL_EXEC_FOLDER}/ffconfig/") -install (PROGRAMS setupConfig DESTINATION "${TARGET_TOOL_EXEC_FOLDER}/ffconfig/") -install (PROGRAMS setupProxy DESTINATION "${TARGET_TOOL_EXEC_FOLDER}/ffconfig/") -install (PROGRAMS setupHomepage DESTINATION "${TARGET_TOOL_EXEC_FOLDER}/ffconfig/") +install (PROGRAMS writeConfigFiles DESTINATION "${TARGET_TOOL_EXEC_FOLDER}/ffconfig/" COMPONENT elektra-bin-extra) +install (PROGRAMS setupConfig DESTINATION "${TARGET_TOOL_EXEC_FOLDER}/ffconfig/" COMPONENT elektra-bin-extra) +install (PROGRAMS setupProxy DESTINATION "${TARGET_TOOL_EXEC_FOLDER}/ffconfig/" COMPONENT elektra-bin-extra) +install (PROGRAMS setupHomepage DESTINATION "${TARGET_TOOL_EXEC_FOLDER}/ffconfig/" COMPONENT elektra-bin-extra) diff --git a/scripts/kdb/CMakeLists.txt b/scripts/kdb/CMakeLists.txt index e5292fab9d7..a32823b9fbc 100644 --- a/scripts/kdb/CMakeLists.txt +++ b/scripts/kdb/CMakeLists.txt @@ -4,12 +4,33 @@ file (GLOB IN_FILES *.in) foreach (file ${IN_FILES}) get_filename_component (file_we "${file}" NAME_WE) configure_file ("${file}" "${file_we}" @ONLY) - install (PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/${file_we}" DESTINATION "${TARGET_TOOL_EXEC_FOLDER}") + install (PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/${file_we}" DESTINATION "${TARGET_TOOL_EXEC_FOLDER}" COMPONENT elektra-bin) endforeach (file ${IN_FILES}) +set ( + COMPONENT_BIN_EXTRA_FILES + "find-tools" + "mount-list-all-files" + "mountpoint-info") + +set ( + NOT_INCLUDE + "cmerge-config-files" + "install-config-file" +) + file (GLOB ALL_FILES *) list (REMOVE_ITEM ALL_FILES ${IN_FILES}) list (REMOVE_ITEM ALL_FILES "${CMAKE_CURRENT_SOURCE_DIR}/CMakeLists.txt") foreach (file ${ALL_FILES}) - install (PROGRAMS "${file}" DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) + get_filename_component (file_we "${file}" NAME_WE) + if ("${file_we}" IN_LIST COMPONENT_BIN_EXTRA_FILES) + set(HAS_COMPONENT elektra-bin-extra) + elseif ("${file_we}" IN_LIST NOT_INCLUDE) + set(HAS_COMPONENT "") + else () + set(HAS_COMPONENT elektra-bin) + endif() + message (STATUS "HAS_COMPONENT: ${HAS_COMPONENT} FILE: ${file}") + install (PROGRAMS "${file}" DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT ${HAS_COMPONENT}) endforeach (file ${ALL_FILES}) diff --git a/scripts/release/package.sh b/scripts/release/package.sh new file mode 100644 index 00000000000..e79a404f9a1 --- /dev/null +++ b/scripts/release/package.sh @@ -0,0 +1,41 @@ +#!/bin/sh + +ELEKTRA_PLUGINS='ALL;mozprefs;multifile;-gitresolver;-jni;-ruby;-haskell;-yamlcpp;toml' +ELEKTRA_TOOLS='ALL' +ELEKTRA_BINDINGS='cpp;lua;python;INTERCEPT' + +# #workaround for hardening flags +# CPPFLAGS=$(dpkg-buildflags --get CPPFLAGS) +# CFLAGS=$(dpkg-buildflags --get CFLAGS $CPPFLAGS) +# CXXFLAGS=$(dpkg-buildflags --get CXXFLAGS) $(CPPFLAGS) +# LDFLAGS=$(dpkg-buildflags --get LDFLAGS) + +PY3VER=$(py3versions -d -v) +#DEB_HOST_MULTIARCH=$(dpkg-architecture -qDEB_HOST_MULTIARCH) + +CMAKE_ARGS="-DTARGET_PLUGIN_FOLDER='elektra4' \ + -DBUILD_STATIC=OFF \ + -DPython_ADDITIONAL_VERSIONS=$PY3VER \ + -DGTEST_ROOT='/usr/src/gtest' \ + -DPLUGINS=$ELEKTRA_PLUGINS \ + -DTOOLS=$ELEKTRA_TOOLS \ + -DBINDINGS=$ELEKTRA_BINDINGS \ + -DINSTALL_DOCUMENTATION=ON \ + -DSWIG_EXECUTABLE=/usr/bin/swig3.0 \ + -DPYTHON_EXECUTABLE:PATH=/usr/bin/python3 \ + -DENABLE_TESTING=ON \ + -DINSTALL_TESTING=ON \ + -DENABLE_KDB_TESTING=OFF \ + -DINSTALL_SYSTEM_FILES=ON \ + -DBUILD_PDF=OFF \ + -DBUILD_FULL=ON" + + # \ + #-DTARGET_TEST_DATA_FOLDER=share/libelektra-test/test-data" + +# DEBUG pls remove +cpu_count=`nproc --all` +export MAKEFLAGS="-j$(($cpu_count+2)) -l$(($cpu_count*2))" +# end debug +cmake $CMAKE_ARGS .. +LD_LIBRARY_PATH=/home/libelektra/build/lib:${LD_LIBRARY_PATH} make package diff --git a/src/bindings/cpp/include/CMakeLists.txt b/src/bindings/cpp/include/CMakeLists.txt index c4a56ed8a00..bd3d7be44be 100644 --- a/src/bindings/cpp/include/CMakeLists.txt +++ b/src/bindings/cpp/include/CMakeLists.txt @@ -1,3 +1,3 @@ file (GLOB HEADER_FILES *.hpp) -install (FILES ${HEADER_FILES} DESTINATION include/${TARGET_INCLUDE_FOLDER}) +install (FILES ${HEADER_FILES} DESTINATION include/${TARGET_INCLUDE_FOLDER} COMPONENT libelektra-dev) diff --git a/src/bindings/intercept/env/examples/CMakeLists.txt b/src/bindings/intercept/env/examples/CMakeLists.txt index c3be8b37276..8243df0a69d 100644 --- a/src/bindings/intercept/env/examples/CMakeLists.txt +++ b/src/bindings/intercept/env/examples/CMakeLists.txt @@ -9,7 +9,7 @@ macro (do_example source) set (SOURCES ${HDR_FILES} ${source}.c) add_executable (${source} ${SOURCES}) - install (TARGETS ${source} DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) + install (TARGETS ${source} DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT libelektra4) set_target_properties (${source} PROPERTIES COMPILE_DEFINITIONS HAVE_KDBCONFIG_H) endmacro (do_example) diff --git a/src/bindings/intercept/env/include/CMakeLists.txt b/src/bindings/intercept/env/include/CMakeLists.txt index d28cb5b603a..80fd5c45980 100644 --- a/src/bindings/intercept/env/include/CMakeLists.txt +++ b/src/bindings/intercept/env/include/CMakeLists.txt @@ -1,3 +1,3 @@ file (GLOB HDR_FILES *.h) -install (FILES ${HDR_FILES} DESTINATION include/${TARGET_INCLUDE_FOLDER}) +install (FILES ${HDR_FILES} DESTINATION include/${TARGET_INCLUDE_FOLDER} COMPONENT libelektra-dev) diff --git a/src/bindings/intercept/env/src/CMakeLists.txt b/src/bindings/intercept/env/src/CMakeLists.txt index 30fe83ab280..7f1c56189e7 100644 --- a/src/bindings/intercept/env/src/CMakeLists.txt +++ b/src/bindings/intercept/env/src/CMakeLists.txt @@ -18,8 +18,8 @@ set_target_properties ( LINKER_LANGUAGE CXX) -install (TARGETS elektraintercept-env DESTINATION lib${LIB_SUFFIX}) +install (TARGETS elektraintercept-env DESTINATION lib${LIB_SUFFIX} COMPONENT libelektra4) mkdir (${CMAKE_LIBRARY_OUTPUT_DIRECTORY}) -create_lib_symlink (libelektraintercept-env.so libelektragetenv.so) -create_lib_symlink (libelektraintercept-env.so libelektragetenv.so.0) +create_lib_symlink (libelektraintercept-env.so libelektragetenv.so libelektra4) +create_lib_symlink (libelektraintercept-env.so libelektragetenv.so.0 libelektra4) diff --git a/src/bindings/intercept/fs/CMakeLists.txt b/src/bindings/intercept/fs/CMakeLists.txt index 68af70537bb..ade3e7602ef 100644 --- a/src/bindings/intercept/fs/CMakeLists.txt +++ b/src/bindings/intercept/fs/CMakeLists.txt @@ -13,8 +13,8 @@ else () set_source_files_properties (intercept.c PROPERTIES COMPILE_FLAGS "-Wno-unused-result") add_library (elektraintercept-fs SHARED "intercept.c") target_link_libraries (elektraintercept-fs elektra-kdb elektra-meta) - install (TARGETS elektraintercept-fs DESTINATION lib${LIB_SUFFIX}) + install (TARGETS elektraintercept-fs DESTINATION lib${LIB_SUFFIX} COMPONENT libelektra4) mkdir (${CMAKE_LIBRARY_OUTPUT_DIRECTORY}) - create_lib_symlink (libelektraintercept-fs.so libelektraintercept.so) + create_lib_symlink (libelektraintercept-fs.so libelektraintercept.so libelektra4) endif () diff --git a/src/bindings/swig/lua/CMakeLists.txt b/src/bindings/swig/lua/CMakeLists.txt index 9380f1e9a02..1c03b0cae38 100644 --- a/src/bindings/swig/lua/CMakeLists.txt +++ b/src/bindings/swig/lua/CMakeLists.txt @@ -43,7 +43,7 @@ else () set (SWIG_COMPILE_FLAGS "${SWIG_COMPILE_FLAGS} -Wno-ignored-qualifiers") set_source_files_properties (${swig_generated_file_fullname} PROPERTIES COMPILE_FLAGS "${SWIG_COMPILE_FLAGS} -DSWIG_TYPE_TABLE=kdb") - install (TARGETS swig-lua LIBRARY DESTINATION ${TARGET_LUA_CMOD_FOLDER}) + install (TARGETS swig-lua LIBRARY DESTINATION ${TARGET_LUA_CMOD_FOLDER} COMPONENT lua-elektra) include_directories (${CMAKE_CURRENT_SOURCE_DIR}) include_directories (${CMAKE_SOURCE_DIR}/src/swig/) diff --git a/src/bindings/swig/python/CMakeLists.txt b/src/bindings/swig/python/CMakeLists.txt index c53b3bacf8b..f98b35137cc 100644 --- a/src/bindings/swig/python/CMakeLists.txt +++ b/src/bindings/swig/python/CMakeLists.txt @@ -128,6 +128,7 @@ else () install ( DIRECTORY ${CMAKE_SWIG_OUTDIR} DESTINATION ${PYTHON_SITE_PACKAGES} + COMPONENT python3-elektra FILES_MATCHING REGEX "\\.(py|so)$") diff --git a/src/include/CMakeLists.txt b/src/include/CMakeLists.txt index bca2655a555..393317aaca9 100644 --- a/src/include/CMakeLists.txt +++ b/src/include/CMakeLists.txt @@ -190,7 +190,8 @@ install ( kdbendian.h kdbmacros.h kdbmerge.h - DESTINATION include/${TARGET_INCLUDE_FOLDER}) + DESTINATION include/${TARGET_INCLUDE_FOLDER} + COMPONENT libelektra-dev) add_custom_target (elektra_config_headers ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/kdb.h ${CMAKE_CURRENT_BINARY_DIR}/kdbconfig.h ${CMAKE_CURRENT_BINARY_DIR}/kdbversion.h) diff --git a/src/include/elektra/CMakeLists.txt b/src/include/elektra/CMakeLists.txt index 15e0f85a350..84cf1b7a642 100644 --- a/src/include/elektra/CMakeLists.txt +++ b/src/include/elektra/CMakeLists.txt @@ -1 +1 @@ -install (FILES error.h conversion.h types.h DESTINATION include/${TARGET_INCLUDE_FOLDER}/elektra) +install (FILES error.h conversion.h types.h DESTINATION include/${TARGET_INCLUDE_FOLDER}/elektra COMPONENT libelektra-dev) diff --git a/src/libs/CMakeLists.txt b/src/libs/CMakeLists.txt index 60fdd695740..32a81f8fd12 100644 --- a/src/libs/CMakeLists.txt +++ b/src/libs/CMakeLists.txt @@ -41,4 +41,4 @@ foreach (subdir ${SUBDIRS}) add_subdirectory ("${subdir}") endforeach (subdir) -generate_manpage (elektra-libs FILENAME "${CMAKE_CURRENT_SOURCE_DIR}/README.md" SECTION 7) +generate_manpage (elektra-libs FILENAME "${CMAKE_CURRENT_SOURCE_DIR}/README.md" SECTION 7 COMPONENT elektra-doc) diff --git a/src/libs/ease/CMakeLists.txt b/src/libs/ease/CMakeLists.txt index 6577f0494fe..d0dc66431fc 100644 --- a/src/libs/ease/CMakeLists.txt +++ b/src/libs/ease/CMakeLists.txt @@ -1,2 +1,2 @@ file (GLOB SOURCES *.c) -add_lib (ease SOURCES ${SOURCES}) +add_lib (ease SOURCES ${SOURCES} COMPONENT libelektra4) diff --git a/src/libs/elektra/CMakeLists.txt b/src/libs/elektra/CMakeLists.txt index 4c3f55914cb..b545eb5ca7d 100644 --- a/src/libs/elektra/CMakeLists.txt +++ b/src/libs/elektra/CMakeLists.txt @@ -109,7 +109,8 @@ if (BUILD_SHARED) install ( TARGETS elektra-core elektra-kdb DESTINATION lib${LIB_SUFFIX} - EXPORT ElektraTargetsLibelektra) + EXPORT ElektraTargetsLibelektra + COMPONENT libelektra4) list (APPEND targets_built ${elektra-all_LIBRARIES}) endif (BUILD_SHARED) @@ -147,7 +148,8 @@ if (BUILD_FULL) install ( TARGETS elektra-full DESTINATION lib${LIB_SUFFIX} - EXPORT ElektraTargetsLibelektra) + EXPORT ElektraTargetsLibelektra + COMPONENT libelektra4-full) list (APPEND targets_built elektra-full) endif (BUILD_FULL) @@ -171,13 +173,14 @@ if (BUILD_STATIC) install ( TARGETS elektra-static DESTINATION lib${LIB_SUFFIX} - EXPORT ElektraTargetsLibelektra) + EXPORT ElektraTargetsLibelektra + COMPONENT libelektra4) list (APPEND targets_built elektra-static) endif (BUILD_STATIC) export (TARGETS ${targets_built} FILE "${CMAKE_CURRENT_BINARY_DIR}/ElektraTargetsLibelektra.cmake") -install (EXPORT ElektraTargetsLibelektra DESTINATION "${TARGET_CMAKE_FOLDER}") +install (EXPORT ElektraTargetsLibelektra DESTINATION "${TARGET_CMAKE_FOLDER}" COMPONENT libelektra-dev) # if you want the same name for those 3 libraries, here is how to do it: # http://www.itk.org/Wiki/CMake_FAQ#How_do_I_make_my_shared_and_static_libraries_have_the_same_root_name.2C_but_different_suffixes.3F diff --git a/src/libs/globbing/CMakeLists.txt b/src/libs/globbing/CMakeLists.txt index 88cf0f88854..20df7ff1be0 100644 --- a/src/libs/globbing/CMakeLists.txt +++ b/src/libs/globbing/CMakeLists.txt @@ -3,7 +3,7 @@ file (GLOB SOURCES *.c) safe_check_symbol_exists ("fnmatch" "fnmatch.h" HAVE_FNMATCH) if (HAVE_FNMATCH) - add_lib (globbing SOURCES ${SOURCES} LINK_ELEKTRA elektra-ease) + add_lib (globbing SOURCES ${SOURCES} LINK_ELEKTRA elektra-ease COMPONENT libelektra4) else () message ("Excluding lib-globbing, because fnmatch was not found.") endif () diff --git a/src/libs/highlevel/CMakeLists.txt b/src/libs/highlevel/CMakeLists.txt index 0cf67170cc5..367ecbf1aeb 100644 --- a/src/libs/highlevel/CMakeLists.txt +++ b/src/libs/highlevel/CMakeLists.txt @@ -1,6 +1,6 @@ file (GLOB SOURCES *.c) -add_lib (highlevel SOURCES ${SOURCES} LINK_ELEKTRA elektra-kdb elektra-ease) +add_lib (highlevel SOURCES ${SOURCES} LINK_ELEKTRA elektra-kdb elektra-ease COMPONENT libelektra4) if (BUILD_SHARED) set (LIBRARIES "-lelektra-highlevel -lelektra-kdb -lelektra-ease -lelektra-core") @@ -14,7 +14,7 @@ else (BUILD_STATIC) endif () configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/elektra-highlevel.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/elektra-highlevel.pc" @ONLY) -install (FILES "${CMAKE_CURRENT_BINARY_DIR}/elektra-highlevel.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER}) +install (FILES "${CMAKE_CURRENT_BINARY_DIR}/elektra-highlevel.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} COMPONENT libelektra-dev) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/elektra-codegen.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/elektra-codegen.pc" @ONLY) -install (FILES "${CMAKE_CURRENT_BINARY_DIR}/elektra-codegen.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER}) +install (FILES "${CMAKE_CURRENT_BINARY_DIR}/elektra-codegen.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} COMPONENT libelektra-dev) diff --git a/src/libs/invoke/CMakeLists.txt b/src/libs/invoke/CMakeLists.txt index 2ae4e842a35..733920d4da5 100644 --- a/src/libs/invoke/CMakeLists.txt +++ b/src/libs/invoke/CMakeLists.txt @@ -1,2 +1,2 @@ file (GLOB SOURCES *.c) -add_lib (invoke SOURCES ${SOURCES} LINK_ELEKTRA elektra-kdb) +add_lib (invoke SOURCES ${SOURCES} LINK_ELEKTRA elektra-kdb COMPONENT libelektra4) diff --git a/src/libs/io/CMakeLists.txt b/src/libs/io/CMakeLists.txt index 110d9a77a50..26a44fc4321 100644 --- a/src/libs/io/CMakeLists.txt +++ b/src/libs/io/CMakeLists.txt @@ -2,10 +2,11 @@ set (SOURCES "${CMAKE_CURRENT_SOURCE_DIR}/io.c") set (LIBRARY_NAME elektra-io) -add_lib (io SOURCES ${SOURCES} LINK_ELEKTRA elektra-kdb elektra-invoke) +add_lib (io SOURCES ${SOURCES} LINK_ELEKTRA elektra-kdb elektra-invoke + COMPONENT libelektra4) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/${LIBRARY_NAME}.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/${LIBRARY_NAME}.pc" @ONLY) -install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${LIBRARY_NAME}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER}) +install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${LIBRARY_NAME}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} COMPONENT libelektra-dev) add_subdirectory (adapter) diff --git a/src/libs/merge/CMakeLists.txt b/src/libs/merge/CMakeLists.txt index 3d58bc7d537..2cf5ea46a66 100644 --- a/src/libs/merge/CMakeLists.txt +++ b/src/libs/merge/CMakeLists.txt @@ -24,10 +24,11 @@ add_lib ( LINK_ELEKTRA elektra-ease LINK_LIBRARIES - ${CMERGE_LIBRARY_DIRS}) + ${CMERGE_LIBRARY_DIRS} + COMPONENT elektra-bin) set (LIBRARY_NAME elektra-merge) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/${LIBRARY_NAME}.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/${LIBRARY_NAME}.pc" @ONLY) -install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${LIBRARY_NAME}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER}) +install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${LIBRARY_NAME}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} COMPONENT libelektra4) diff --git a/src/libs/meta/CMakeLists.txt b/src/libs/meta/CMakeLists.txt index 80c1cac1830..0d12edb5837 100644 --- a/src/libs/meta/CMakeLists.txt +++ b/src/libs/meta/CMakeLists.txt @@ -1,2 +1,2 @@ file (GLOB SOURCES *.c) -add_lib (meta SOURCES ${SOURCES} LINK_ELEKTRA elektra-ease) +add_lib (meta SOURCES ${SOURCES} LINK_ELEKTRA elektra-ease COMPONENT libelektra4) diff --git a/src/libs/notification/CMakeLists.txt b/src/libs/notification/CMakeLists.txt index 041fc48627f..0df0c692c8a 100644 --- a/src/libs/notification/CMakeLists.txt +++ b/src/libs/notification/CMakeLists.txt @@ -15,11 +15,12 @@ else () LINK_ELEKTRA elektra-kdb elektra-ease - elektra-invoke) + elektra-invoke + COMPONENT libelektra4) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/${LIBRARY_NAME}.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/${LIBRARY_NAME}.pc" @ONLY) - install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${LIBRARY_NAME}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER}) + install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${LIBRARY_NAME}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} COMPONENT libelektra-dev) if (ENABLE_TESTING) add_subdirectory (tests) diff --git a/src/libs/opts/CMakeLists.txt b/src/libs/opts/CMakeLists.txt index 8218ee64a76..f38f3d8a702 100644 --- a/src/libs/opts/CMakeLists.txt +++ b/src/libs/opts/CMakeLists.txt @@ -1,3 +1,3 @@ file (GLOB SOURCES *.c) -add_lib (opts SOURCES ${SOURCES} LINK_ELEKTRA elektra-meta) +add_lib (opts SOURCES ${SOURCES} LINK_ELEKTRA elektra-meta COMPONENT libelektra4) diff --git a/src/libs/plugin/CMakeLists.txt b/src/libs/plugin/CMakeLists.txt index 4d69d99825b..4e7ebd5b11b 100644 --- a/src/libs/plugin/CMakeLists.txt +++ b/src/libs/plugin/CMakeLists.txt @@ -1,2 +1,2 @@ file (GLOB SOURCES *.c) -add_lib (plugin SOURCES ${SOURCES}) +add_lib (plugin SOURCES ${SOURCES} COMPONENT libelektra4) diff --git a/src/libs/pluginprocess/CMakeLists.txt b/src/libs/pluginprocess/CMakeLists.txt index 5587467ccce..0743efd9cb3 100644 --- a/src/libs/pluginprocess/CMakeLists.txt +++ b/src/libs/pluginprocess/CMakeLists.txt @@ -3,7 +3,7 @@ find_package (Pluginprocess) file (GLOB SOURCES *.c) if (PLUGINPROCESS_FOUND) - add_lib (pluginprocess SOURCES ${SOURCES} LINK_ELEKTRA elektra-invoke elektra-plugin) + add_lib (pluginprocess SOURCES ${SOURCES} LINK_ELEKTRA elektra-invoke elektra-plugin COMPONENT libelektra4) if (ENABLE_TESTING) add_subdirectory (tests) diff --git a/src/libs/tools/include/CMakeLists.txt b/src/libs/tools/include/CMakeLists.txt index 5d573ff7ad5..3615452b062 100644 --- a/src/libs/tools/include/CMakeLists.txt +++ b/src/libs/tools/include/CMakeLists.txt @@ -1,11 +1,11 @@ file (GLOB HDR_FILES *.hpp) -install (FILES ${HDR_FILES} DESTINATION include/${TARGET_INCLUDE_FOLDER}) +install (FILES ${HDR_FILES} DESTINATION include/${TARGET_INCLUDE_FOLDER} COMPONENT libelektra-dev) file (GLOB HELPER_HDR_FILES helper/*.hpp) -install (FILES ${HELPER_HDR_FILES} DESTINATION include/${TARGET_INCLUDE_FOLDER}/helper) +install (FILES ${HELPER_HDR_FILES} DESTINATION include/${TARGET_INCLUDE_FOLDER}/helper COMPONENT libelektra-dev) file (GLOB MERGING_HDR_FILES merging/*.hpp) -install (FILES ${MERGING_HDR_FILES} DESTINATION include/${TARGET_INCLUDE_FOLDER}/merging) +install (FILES ${MERGING_HDR_FILES} DESTINATION include/${TARGET_INCLUDE_FOLDER}/merging COMPONENT libelektra-dev) diff --git a/src/libs/tools/src/CMakeLists.txt b/src/libs/tools/src/CMakeLists.txt index e616aa9f337..dd8348d7bdd 100644 --- a/src/libs/tools/src/CMakeLists.txt +++ b/src/libs/tools/src/CMakeLists.txt @@ -35,7 +35,7 @@ if (BUILD_SHARED) set_target_properties (elektratools PROPERTIES LINK_FLAGS "-Wl,--version-script='${__symbols_file}'") endif () - install (TARGETS elektratools DESTINATION lib${LIB_SUFFIX}) + install (TARGETS elektratools DESTINATION lib${LIB_SUFFIX} COMPONENT elektra-bin) endif (BUILD_SHARED) if (BUILD_FULL) @@ -53,7 +53,7 @@ if (BUILD_FULL) set_target_properties (elektratools-full PROPERTIES LINK_FLAGS "-Wl,--version-script='${__symbols_file}'") endif () - install (TARGETS elektratools-full DESTINATION lib${LIB_SUFFIX}) + install (TARGETS elektratools-full DESTINATION lib${LIB_SUFFIX} COMPONENT libelektra4-full) endif (BUILD_FULL) if (BUILD_STATIC) @@ -72,5 +72,5 @@ if (BUILD_STATIC) set_target_properties (elektratools-static PROPERTIES LINK_FLAGS "-Wl,--version-script='${__symbols_file}'") endif () - install (TARGETS elektratools-static DESTINATION lib${LIB_SUFFIX}) + install (TARGETS elektratools-static DESTINATION lib${LIB_SUFFIX} COMPONENT elektra-bin) endif (BUILD_STATIC) diff --git a/src/libs/utility/CMakeLists.txt b/src/libs/utility/CMakeLists.txt index 80f4133b745..78aabe3fbb4 100644 --- a/src/libs/utility/CMakeLists.txt +++ b/src/libs/utility/CMakeLists.txt @@ -1,2 +1,2 @@ file (GLOB SOURCES *.c) -add_lib (utility SOURCES ${SOURCES}) +add_lib (utility SOURCES ${SOURCES} COMPONENT libelektra4) diff --git a/src/plugins/CMakeLists.txt b/src/plugins/CMakeLists.txt index c6261f9e145..bf81a375ac5 100644 --- a/src/plugins/CMakeLists.txt +++ b/src/plugins/CMakeLists.txt @@ -18,7 +18,7 @@ if (ADDTESTING_PHASE) return () endif () -generate_manpage (elektra-plugins FILENAME ${CMAKE_CURRENT_SOURCE_DIR}/README.md SECTION 7) +generate_manpage (elektra-plugins FILENAME ${CMAKE_CURRENT_SOURCE_DIR}/README.md SECTION 7 COMPONENT elektra-doc) set (COLLECTION_PHASE ON) set (DEPENDENCY_PHASE OFF) @@ -94,7 +94,7 @@ endif () if (BUILD_SHARED) mkdir (${CMAKE_LIBRARY_OUTPUT_DIRECTORY}) - create_lib_symlink (libelektra-${KDB_DEFAULT_STORAGE}.so libelektra-storage.so PLUGIN) + create_lib_symlink (libelektra-${KDB_DEFAULT_STORAGE}.so libelektra-storage.so libelektra4 PLUGIN) - create_lib_symlink (libelektra-${KDB_DEFAULT_RESOLVER}.so libelektra-resolver.so PLUGIN) + create_lib_symlink (libelektra-${KDB_DEFAULT_RESOLVER}.so libelektra-resolver.so libelektra4 PLUGIN) endif (BUILD_SHARED) diff --git a/src/plugins/augeas/CMakeLists.txt b/src/plugins/augeas/CMakeLists.txt index 4003f37943b..d939c9e9564 100644 --- a/src/plugins/augeas/CMakeLists.txt +++ b/src/plugins/augeas/CMakeLists.txt @@ -45,4 +45,5 @@ add_plugin ( COMPILE_DEFINITIONS "${LIBAUGEAS_COMPILE_DEFINITIONS}" LINK_ELEKTRA elektra-meta LINK_LIBRARIES ${AUGEAS_PLUGIN_LIBRARIES} - TEST_ENVIRONMENT "ASAN_OPTIONS=detect_container_overflow=0") + TEST_ENVIRONMENT "ASAN_OPTIONS=detect_container_overflow=0" + COMPONENT libelektra4-augeas) diff --git a/src/plugins/base64/CMakeLists.txt b/src/plugins/base64/CMakeLists.txt index 1eb480f1a8e..26c12f88b23 100644 --- a/src/plugins/base64/CMakeLists.txt +++ b/src/plugins/base64/CMakeLists.txt @@ -4,4 +4,5 @@ add_plugin ( base64 SOURCES base64_functions.h base64_functions.c base64.h base64.c ADD_TEST TEST_README - TEST_REQUIRED_PLUGINS toml) + TEST_REQUIRED_PLUGINS toml + COMPONENT libelektra4) diff --git a/src/plugins/blockresolver/CMakeLists.txt b/src/plugins/blockresolver/CMakeLists.txt index cc1c9d8e938..1aa27c29171 100644 --- a/src/plugins/blockresolver/CMakeLists.txt +++ b/src/plugins/blockresolver/CMakeLists.txt @@ -3,4 +3,5 @@ add_plugin ( SOURCES blockresolver.h blockresolver.c LINK_ELEKTRA elektra-invoke ADD_TEST INSTALL_TEST_DATA TEST_README - TEST_REQUIRED_PLUGINS mini) + TEST_REQUIRED_PLUGINS mini + COMPONENT libelektra4-experimental) diff --git a/src/plugins/c/CMakeLists.txt b/src/plugins/c/CMakeLists.txt index 700238cc76a..786e1a2b9aa 100644 --- a/src/plugins/c/CMakeLists.txt +++ b/src/plugins/c/CMakeLists.txt @@ -1,3 +1,4 @@ include (LibAddMacros) -add_plugin (c SOURCES c.h c.c) +add_plugin (c SOURCES c.h c.c + COMPONENT libelektra4) diff --git a/src/plugins/cache/CMakeLists.txt b/src/plugins/cache/CMakeLists.txt index d7ceffde1a9..ecfb196bd0c 100644 --- a/src/plugins/cache/CMakeLists.txt +++ b/src/plugins/cache/CMakeLists.txt @@ -28,7 +28,8 @@ add_plugin ( cache SOURCES cache.h cache.c LINK_ELEKTRA elektra-kdb - ADD_TEST TEST_README) + ADD_TEST TEST_README + COMPONENT libelektra4) if (CACHE_DEPENDENCIES_OK AND BUILD_SHARED) add_dependencies (elektra-cache elektra-resolver_fm_hpu_b elektra-mmapstorage) diff --git a/src/plugins/ccode/CMakeLists.txt b/src/plugins/ccode/CMakeLists.txt index 8a98c41f11b..6c3cbf28ff0 100644 --- a/src/plugins/ccode/CMakeLists.txt +++ b/src/plugins/ccode/CMakeLists.txt @@ -2,4 +2,5 @@ add_plugin ( ccode CPP ADD_TEST CPP_TEST SOURCES ccode.hpp ccode.cpp coder.hpp coder.cpp TEST_README - TEST_REQUIRED_PLUGINS tcl base64) + TEST_REQUIRED_PLUGINS tcl base64 + COMPONENT libelektra4-extra) diff --git a/src/plugins/conditionals/CMakeLists.txt b/src/plugins/conditionals/CMakeLists.txt index f7a2a54bc04..f8ff928413a 100644 --- a/src/plugins/conditionals/CMakeLists.txt +++ b/src/plugins/conditionals/CMakeLists.txt @@ -10,4 +10,5 @@ add_plugin ( SOURCES conditionals.h conditionals.c LINK_ELEKTRA elektra-meta ADD_TEST TEST_README - TEST_REQUIRED_PLUGINS dump ini ni) + TEST_REQUIRED_PLUGINS dump ini ni + COMPONENT libelektra4-extra) diff --git a/src/plugins/constants/CMakeLists.txt b/src/plugins/constants/CMakeLists.txt index b207b76d09c..bc6ad810c68 100644 --- a/src/plugins/constants/CMakeLists.txt +++ b/src/plugins/constants/CMakeLists.txt @@ -10,4 +10,5 @@ add_plugin ( constants SOURCES ${CMAKE_CURRENT_BINARY_DIR}/constants.c TEST_README - TEST_REQUIRED_PLUGINS noresolver) + TEST_REQUIRED_PLUGINS noresolver + COMPONENT libelektra4) diff --git a/src/plugins/counter/CMakeLists.txt b/src/plugins/counter/CMakeLists.txt index ba7a42fc609..531ed4c4982 100644 --- a/src/plugins/counter/CMakeLists.txt +++ b/src/plugins/counter/CMakeLists.txt @@ -1,3 +1,3 @@ include (LibAddMacros) -add_plugin (counter SOURCES counter.h counter.c) +add_plugin (counter SOURCES counter.h counter.c COMPONENT libelektra4-extra) diff --git a/src/plugins/cpptemplate/CMakeLists.txt b/src/plugins/cpptemplate/CMakeLists.txt index fb49f1875d7..5908cdbe2d1 100644 --- a/src/plugins/cpptemplate/CMakeLists.txt +++ b/src/plugins/cpptemplate/CMakeLists.txt @@ -1,4 +1,4 @@ include (LibAddMacros) add_plugin (cpptemplate CPP ADD_TEST CPP_TEST TEST_README SOURCES cpptemplate.hpp cpptemplate.cpp cpptemplate_delegate.hpp - cpptemplate_delegate.cpp) + cpptemplate_delegate.cpp COMPONENT libelektra4-experimental) diff --git a/src/plugins/crypto/CMakeLists.txt b/src/plugins/crypto/CMakeLists.txt index 1fdec7f0e08..d2cb8ca1689 100644 --- a/src/plugins/crypto/CMakeLists.txt +++ b/src/plugins/crypto/CMakeLists.txt @@ -23,7 +23,8 @@ add_plugin ( INCLUDE_DIRECTORIES ${Libgcrypt_INCLUDE_DIRS} LINK_LIBRARIES ${Libgcrypt_LIBRARIES} LINK_ELEKTRA elektra-invoke - ADD_TEST) + ADD_TEST + COMPONENT libelektra4-crypto) if (ADDTESTING_PHASE) set_property (TEST "testmod_crypto" PROPERTY LABELS memleak) diff --git a/src/plugins/csvstorage/CMakeLists.txt b/src/plugins/csvstorage/CMakeLists.txt index 02ed5b6a6ba..d2326ed6270 100644 --- a/src/plugins/csvstorage/CMakeLists.txt +++ b/src/plugins/csvstorage/CMakeLists.txt @@ -7,4 +7,5 @@ add_plugin ( SOURCES csvstorage.h csvstorage.c LINK_ELEKTRA elektra-ease elektra-kdb ADD_TEST INSTALL_TEST_DATA TEST_README - TEST_REQUIRED_PLUGINS directoryvalue) + TEST_REQUIRED_PLUGINS directoryvalue + COMPONENT libelektra4) \ No newline at end of file diff --git a/src/plugins/curlget/CMakeLists.txt b/src/plugins/curlget/CMakeLists.txt index b3914eaa4fe..787bef72472 100644 --- a/src/plugins/curlget/CMakeLists.txt +++ b/src/plugins/curlget/CMakeLists.txt @@ -22,4 +22,5 @@ add_plugin ( SOURCES curlget.h curlget.c LINK_ELEKTRA elektra-invoke INCLUDE_DIRECTORIES ${CURLGET_INCLUDE_DIRS} - LINK_LIBRARIES ${CURLGET_LIBRARY_DIRS}) + LINK_LIBRARIES ${CURLGET_LIBRARY_DIRS} + COMPONENT libelektra4-curl) diff --git a/src/plugins/date/CMakeLists.txt b/src/plugins/date/CMakeLists.txt index bc184834d09..c1fdeb63716 100644 --- a/src/plugins/date/CMakeLists.txt +++ b/src/plugins/date/CMakeLists.txt @@ -11,4 +11,5 @@ endif (DEPENDENCY_PHASE) add_plugin ( date SOURCES date.h date.c - ADD_TEST) + ADD_TEST + COMPONENT libelektra4-extra) diff --git a/src/plugins/dbus/CMakeLists.txt b/src/plugins/dbus/CMakeLists.txt index 19e78ac1184..2d0f73030ce 100644 --- a/src/plugins/dbus/CMakeLists.txt +++ b/src/plugins/dbus/CMakeLists.txt @@ -10,7 +10,8 @@ add_plugin ( dbus SOURCES dbus.h dbus.c sendmessage.c INCLUDE_DIRECTORIES ${DBUS_INCLUDE_DIR} ${DBUS_ARCH_INCLUDE_DIR} - LINK_LIBRARIES ${DBUS_LIBRARIES}) + LINK_LIBRARIES ${DBUS_LIBRARIES} + COMPONENT libelektra4-dbus) add_plugintest (dbus testmod_dbus.c receivemessage.c INCLUDE_DIRECTORIES ${DBUS_INCLUDE_DIR} ${DBUS_ARCH_INCLUDE_DIR}) diff --git a/src/plugins/dbusrecv/CMakeLists.txt b/src/plugins/dbusrecv/CMakeLists.txt index 2cdc999f5ae..01f0999b7b2 100644 --- a/src/plugins/dbusrecv/CMakeLists.txt +++ b/src/plugins/dbusrecv/CMakeLists.txt @@ -14,7 +14,8 @@ add_plugin ( OBJECT_SOURCES $ INCLUDE_DIRECTORIES ${DBUS_INCLUDE_DIR} ${DBUS_ARCH_INCLUDE_DIR} LINK_ELEKTRA elektra-io elektra-invoke - LINK_LIBRARIES ${DBUS_LIBRARIES}) + LINK_LIBRARIES ${DBUS_LIBRARIES} + COMPONENT libelektra4-dbus) set (NOT_INCLUDED "") plugin_check_if_included ("${PLUGIN_SHORT_NAME}") @@ -51,7 +52,8 @@ if (ADDTESTING_PHASE) dbusrecv TEST_LINK_LIBRARIES ${STATIC_LIBRARIES} TEST_LINK_ELEKTRA elektra-io-uv - INCLUDE_SYSTEM_DIRECTORIES ${libuv_INCLUDE_DIRS}) + INCLUDE_SYSTEM_DIRECTORIES ${libuv_INCLUDE_DIRS} + COMPONENT libelektra4-dbus) # add sources manually because add_plugintest does not support generator expressions for additional source files if (BUILD_FULL OR BUILD_STATIC) diff --git a/src/plugins/desktop/CMakeLists.txt b/src/plugins/desktop/CMakeLists.txt index 025bfb90069..4956610f0cf 100644 --- a/src/plugins/desktop/CMakeLists.txt +++ b/src/plugins/desktop/CMakeLists.txt @@ -1,3 +1,3 @@ include (LibAddMacros) -add_plugin (desktop SOURCES desktop.h desktop.c) +add_plugin (desktop SOURCES desktop.h desktop.c COMPONENT libelektra4-extra) diff --git a/src/plugins/directoryvalue/CMakeLists.txt b/src/plugins/directoryvalue/CMakeLists.txt index a035749ac1a..7d4e7287756 100644 --- a/src/plugins/directoryvalue/CMakeLists.txt +++ b/src/plugins/directoryvalue/CMakeLists.txt @@ -1,4 +1,5 @@ add_plugin ( directoryvalue CPP ADD_TEST CPP_TEST TEST_README SOURCES directoryvalue.hpp directoryvalue.cpp directoryvalue_delegate.hpp directoryvalue_delegate.cpp log.hpp - LINK_ELEKTRA elektra-ease) + LINK_ELEKTRA elektra-ease + COMPONENT libelektra4) \ No newline at end of file diff --git a/src/plugins/doc/CMakeLists.txt b/src/plugins/doc/CMakeLists.txt index d2257d63b6e..f5155c139ba 100644 --- a/src/plugins/doc/CMakeLists.txt +++ b/src/plugins/doc/CMakeLists.txt @@ -3,4 +3,5 @@ include (LibAddMacros) add_plugin ( doc SOURCES doc.h doc.c - LINK_ELEKTRA elektra-kdb) + LINK_ELEKTRA elektra-kdb + COMPONENT libelektra4-experimental) diff --git a/src/plugins/dpkg/CMakeLists.txt b/src/plugins/dpkg/CMakeLists.txt index 78d03596e6f..c0931eb3e0e 100644 --- a/src/plugins/dpkg/CMakeLists.txt +++ b/src/plugins/dpkg/CMakeLists.txt @@ -1,3 +1,3 @@ include (LibAddMacros) -add_plugin (dpkg SOURCES dpkg.h dpkg.c) +add_plugin (dpkg SOURCES dpkg.h dpkg.c COMPONENT libelektra4-extra) diff --git a/src/plugins/dump/CMakeLists.txt b/src/plugins/dump/CMakeLists.txt index d6b6c25c905..1fbf745cf96 100644 --- a/src/plugins/dump/CMakeLists.txt +++ b/src/plugins/dump/CMakeLists.txt @@ -1,6 +1,7 @@ include (LibAddPlugin) -add_plugin (dump SOURCES dump.hpp dump.cpp) +add_plugin (dump SOURCES dump.hpp dump.cpp + COMPONENT libelektra4) if (ADDTESTING_PHASE) add_plugintest (dump INSTALL_TEST_DATA INCLUDE_DIRECTORIES ${CMAKE_CURRENT_BINARY_DIR}) diff --git a/src/plugins/error/CMakeLists.txt b/src/plugins/error/CMakeLists.txt index 17f2cfe141a..1f9b2c22d02 100644 --- a/src/plugins/error/CMakeLists.txt +++ b/src/plugins/error/CMakeLists.txt @@ -1,3 +1,3 @@ include (LibAddMacros) -add_plugin (error SOURCES error.h error.c) +add_plugin (error SOURCES error.h error.c COMPONENT libelektra4-extra) diff --git a/src/plugins/fcrypt/CMakeLists.txt b/src/plugins/fcrypt/CMakeLists.txt index 6d8a32621d2..897aa6c28ad 100644 --- a/src/plugins/fcrypt/CMakeLists.txt +++ b/src/plugins/fcrypt/CMakeLists.txt @@ -4,7 +4,8 @@ add_plugin ( fcrypt SOURCES ../crypto/gpg.h ../crypto/gpg.c fcrypt.h fcrypt.c INCLUDE_DIRECTORIES ${CMAKE_SOURCE_DIR}/src/plugins/crypto/ - ADD_TEST) + ADD_TEST + COMPONENT libelektra4-experimental) if (ADDTESTING_PHASE) set_property (TEST "testmod_fcrypt" PROPERTY LABELS memleak) diff --git a/src/plugins/file/CMakeLists.txt b/src/plugins/file/CMakeLists.txt index 6019085b2c4..42ce6f8d6ac 100644 --- a/src/plugins/file/CMakeLists.txt +++ b/src/plugins/file/CMakeLists.txt @@ -3,4 +3,5 @@ include (LibAddMacros) add_plugin ( file SOURCES file.h file.c - ADD_TEST INSTALL_TEST_DATA TEST_README) + ADD_TEST INSTALL_TEST_DATA TEST_README + COMPONENT libelektra4-experimental) diff --git a/src/plugins/filecheck/CMakeLists.txt b/src/plugins/filecheck/CMakeLists.txt index 039d4474d0d..4dfecf62ab7 100644 --- a/src/plugins/filecheck/CMakeLists.txt +++ b/src/plugins/filecheck/CMakeLists.txt @@ -17,4 +17,5 @@ add_plugin ( SOURCES filecheck.h filecheck.c INCLUDE_DIRECTORIES ${Iconv_INCLUDE_DIRS} LINK_LIBRARIES ${Iconv_LIBRARIES} - ADD_TEST INSTALL_TEST_DATA) + ADD_TEST INSTALL_TEST_DATA + COMPONENT libelektra4-extra) diff --git a/src/plugins/fstab/CMakeLists.txt b/src/plugins/fstab/CMakeLists.txt index 490e93ccf19..f3bc5a88932 100644 --- a/src/plugins/fstab/CMakeLists.txt +++ b/src/plugins/fstab/CMakeLists.txt @@ -10,4 +10,5 @@ add_plugin ( fstab SOURCES fstab.c fstab.h LINK_ELEKTRA elektra-meta - ADD_TEST INSTALL_TEST_DATA) + ADD_TEST INSTALL_TEST_DATA + COMPONENT libelektra4-extra) diff --git a/src/plugins/glob/CMakeLists.txt b/src/plugins/glob/CMakeLists.txt index 5caf1a19f19..a4481b74d12 100644 --- a/src/plugins/glob/CMakeLists.txt +++ b/src/plugins/glob/CMakeLists.txt @@ -3,4 +3,5 @@ include (LibAddMacros) add_plugin ( glob SOURCES glob.h glob.c - ADD_TEST) + ADD_TEST + COMPONENT libelektra4) diff --git a/src/plugins/gopts/CMakeLists.txt b/src/plugins/gopts/CMakeLists.txt index 5c81e9797ca..32ee0b46bc0 100644 --- a/src/plugins/gopts/CMakeLists.txt +++ b/src/plugins/gopts/CMakeLists.txt @@ -33,7 +33,8 @@ if (gopts_source) gopts SOURCES gopts.h gopts.c ${gopts_source} LINK_ELEKTRA elektra-opts - TEST_README) + TEST_README + COMPONENT libelektra4-experimental) if (ADDTESTING_PHASE) set (TEST_SOURCES $ ${ARG_OBJECT_SOURCES}) diff --git a/src/plugins/gpgme/CMakeLists.txt b/src/plugins/gpgme/CMakeLists.txt index d97e171d334..52520bb0a7e 100644 --- a/src/plugins/gpgme/CMakeLists.txt +++ b/src/plugins/gpgme/CMakeLists.txt @@ -16,7 +16,8 @@ add_plugin ( SOURCES ${GPGME_SOURCE_FILES} INCLUDE_DIRECTORIES ${LIBGPGME_INCLUDE_DIRS} LINK_LIBRARIES ${LIBGPGME_LIBRARIES} - ADD_TEST) + ADD_TEST + COMPONENT libelektra4-experimental) if (ADDTESTING_PHASE) set_property (TEST "testmod_gpgme" PROPERTY LABELS memleak) diff --git a/src/plugins/hexcode/CMakeLists.txt b/src/plugins/hexcode/CMakeLists.txt index 8dd565770ff..7f5cd454f86 100644 --- a/src/plugins/hexcode/CMakeLists.txt +++ b/src/plugins/hexcode/CMakeLists.txt @@ -3,4 +3,5 @@ include (LibAddMacros) add_plugin ( hexcode SOURCES hexcode.h hexcode.c - ADD_TEST) + ADD_TEST + COMPONENT libelektra4-extra) diff --git a/src/plugins/hexnumber/CMakeLists.txt b/src/plugins/hexnumber/CMakeLists.txt index 132bee868e7..f0987abd7b4 100644 --- a/src/plugins/hexnumber/CMakeLists.txt +++ b/src/plugins/hexnumber/CMakeLists.txt @@ -4,4 +4,5 @@ add_plugin ( hexnumber SOURCES hexnumber.h hexnumber.c LINK_ELEKTRA elektra-ease - ADD_TEST TEST_README) + ADD_TEST TEST_README + COMPONENT libelektra4-extra) diff --git a/src/plugins/hosts/CMakeLists.txt b/src/plugins/hosts/CMakeLists.txt index 86b4ab94201..308b1b05f62 100644 --- a/src/plugins/hosts/CMakeLists.txt +++ b/src/plugins/hosts/CMakeLists.txt @@ -6,4 +6,5 @@ add_plugin ( LINK_ELEKTRA elektra-ease elektra-meta ADD_TEST TEST_README TEST_REQUIRED_PLUGINS network - INSTALL_TEST_DATA) + INSTALL_TEST_DATA + COMPONENT libelektra4) diff --git a/src/plugins/iconv/CMakeLists.txt b/src/plugins/iconv/CMakeLists.txt index e2b71569e35..13d8f20f98d 100644 --- a/src/plugins/iconv/CMakeLists.txt +++ b/src/plugins/iconv/CMakeLists.txt @@ -16,4 +16,5 @@ add_plugin ( SOURCES conv.h iconv.c INCLUDE_DIRECTORIES ${Iconv_INCLUDE_DIRS} LINK_LIBRARIES ${Iconv_LIBRARIES} - ADD_TEST TEST_README) + ADD_TEST TEST_README + COMPONENT libelektra4-extra) diff --git a/src/plugins/internalnotification/CMakeLists.txt b/src/plugins/internalnotification/CMakeLists.txt index c9817469566..0beb3435a9e 100644 --- a/src/plugins/internalnotification/CMakeLists.txt +++ b/src/plugins/internalnotification/CMakeLists.txt @@ -4,4 +4,5 @@ add_plugin ( internalnotification SOURCES internalnotification.h internalnotification.c ADD_TEST - LINK_ELEKTRA elektra-kdb) + LINK_ELEKTRA elektra-kdb + COMPONENT libelektra4) diff --git a/src/plugins/ipaddr/CMakeLists.txt b/src/plugins/ipaddr/CMakeLists.txt index 55993712e59..4db64b149c8 100644 --- a/src/plugins/ipaddr/CMakeLists.txt +++ b/src/plugins/ipaddr/CMakeLists.txt @@ -3,4 +3,5 @@ include (LibAddMacros) add_plugin ( ipaddr SOURCES ipaddr.h ipaddr.c test_ipaddr.h - ADD_TEST TEST_README) + ADD_TEST TEST_README + COMPONENT libelektra4-experimental) diff --git a/src/plugins/iterate/CMakeLists.txt b/src/plugins/iterate/CMakeLists.txt index 88144a38a77..01623aa5b2c 100644 --- a/src/plugins/iterate/CMakeLists.txt +++ b/src/plugins/iterate/CMakeLists.txt @@ -3,4 +3,5 @@ include (LibAddMacros) add_plugin ( iterate SOURCES iterate.h iterate.c - ADD_TEST) + ADD_TEST + COMPONENT libelektra4-experimental) diff --git a/src/plugins/journald/CMakeLists.txt b/src/plugins/journald/CMakeLists.txt index 73993001260..68f691f23cf 100644 --- a/src/plugins/journald/CMakeLists.txt +++ b/src/plugins/journald/CMakeLists.txt @@ -12,4 +12,5 @@ add_plugin ( journald SOURCES journald.h journald.c INCLUDE_DIRECTORIES ${LIBSYSTEMD_JOURNAL_INCLUDE_DIR} - LINK_LIBRARIES ${LIBSYSTEMD_JOURNAL_LIBRARIES}) + LINK_LIBRARIES ${LIBSYSTEMD_JOURNAL_LIBRARIES} + COMPONENT libelektra4-journald) diff --git a/src/plugins/kconfig/CMakeLists.txt b/src/plugins/kconfig/CMakeLists.txt index 9ac648560ea..98890b16e7e 100644 --- a/src/plugins/kconfig/CMakeLists.txt +++ b/src/plugins/kconfig/CMakeLists.txt @@ -7,4 +7,5 @@ add_plugin ( kconfig_parser.cpp kconfig_parser_exception.cpp kconfig_serializer.cpp - file_utility.cpp) + file_utility.cpp + COMPONENT libelektra4) diff --git a/src/plugins/keytometa/CMakeLists.txt b/src/plugins/keytometa/CMakeLists.txt index 9cfab19386d..26df3589185 100644 --- a/src/plugins/keytometa/CMakeLists.txt +++ b/src/plugins/keytometa/CMakeLists.txt @@ -4,4 +4,5 @@ add_plugin ( keytometa SOURCES keytometa.h keytometa.c LINK_ELEKTRA elektra-meta - ADD_TEST) + ADD_TEST + COMPONENT libelektra4-extra) diff --git a/src/plugins/line/CMakeLists.txt b/src/plugins/line/CMakeLists.txt index 6f20a835233..a74c6a64358 100644 --- a/src/plugins/line/CMakeLists.txt +++ b/src/plugins/line/CMakeLists.txt @@ -10,7 +10,8 @@ add_plugin ( line SOURCES line.h line.c LINK_ELEKTRA elektra-ease - INSTALL_TEST_DATA TEST_README) + INSTALL_TEST_DATA TEST_README + COMPONENT libelektra4) if (ADDTESTING_PHASE) add_plugintest (line INSTALL_TEST_DATA) diff --git a/src/plugins/lineendings/CMakeLists.txt b/src/plugins/lineendings/CMakeLists.txt index ba5047648eb..ca4d4fb8941 100644 --- a/src/plugins/lineendings/CMakeLists.txt +++ b/src/plugins/lineendings/CMakeLists.txt @@ -5,4 +5,5 @@ set_source_files_properties (lineendings.c PROPERTIES COMPILE_FLAGS "-Wno-unused add_plugin ( lineendings SOURCES lineendings.h lineendings.c - ADD_TEST INSTALL_TEST_DATA) + ADD_TEST INSTALL_TEST_DATA + COMPONENT libelektra4-extra) diff --git a/src/plugins/list/CMakeLists.txt b/src/plugins/list/CMakeLists.txt index 1a8ed55aca7..8a502540830 100644 --- a/src/plugins/list/CMakeLists.txt +++ b/src/plugins/list/CMakeLists.txt @@ -4,4 +4,5 @@ add_plugin ( list SOURCES list.h list.c LINK_ELEKTRA elektra-kdb elektra-invoke elektra-ease - ADD_TEST) + ADD_TEST + COMPONENT libelektra4) diff --git a/src/plugins/logchange/CMakeLists.txt b/src/plugins/logchange/CMakeLists.txt index 45e149a9423..f1f51cffe45 100644 --- a/src/plugins/logchange/CMakeLists.txt +++ b/src/plugins/logchange/CMakeLists.txt @@ -1,3 +1,3 @@ include (LibAddMacros) -add_plugin (logchange SOURCES logchange.h logchange.c) +add_plugin (logchange SOURCES logchange.h logchange.c COMPONENT libelektra4-extra) diff --git a/src/plugins/lua/CMakeLists.txt b/src/plugins/lua/CMakeLists.txt index 13c945d4c7f..8d82dd2ce4e 100644 --- a/src/plugins/lua/CMakeLists.txt +++ b/src/plugins/lua/CMakeLists.txt @@ -31,7 +31,8 @@ add_plugin ( INCLUDE_DIRECTORIES ${LUA_INCLUDE_DIR} LINK_LIBRARIES ${LUA_LIBRARIES} COMPILE_DEFINITIONS SWIG_TYPE_TABLE=kdb - INSTALL_TEST_DATA) + INSTALL_TEST_DATA + COMPONENT libelektra4-lua) if (ADDTESTING_PHASE) diff --git a/src/plugins/macaddr/CMakeLists.txt b/src/plugins/macaddr/CMakeLists.txt index e4745dc39e9..3617ae64150 100644 --- a/src/plugins/macaddr/CMakeLists.txt +++ b/src/plugins/macaddr/CMakeLists.txt @@ -3,4 +3,5 @@ include (LibAddMacros) add_plugin ( macaddr SOURCES macaddr.h macaddr.c - ADD_TEST TEST_README) + ADD_TEST TEST_README + COMPONENT libelektra4-extra) diff --git a/src/plugins/mathcheck/CMakeLists.txt b/src/plugins/mathcheck/CMakeLists.txt index 2f19395d50c..26ba662bbb9 100644 --- a/src/plugins/mathcheck/CMakeLists.txt +++ b/src/plugins/mathcheck/CMakeLists.txt @@ -3,5 +3,6 @@ include (LibAddMacros) add_plugin ( mathcheck SOURCES mathcheck.h mathcheck.c floathelper.h floathelper.c - TEST_README) + TEST_README + COMPONENT libelektra4-extra) add_plugintest (mathcheck) diff --git a/src/plugins/mini/CMakeLists.txt b/src/plugins/mini/CMakeLists.txt index d96febc4e13..ae044b15c2f 100644 --- a/src/plugins/mini/CMakeLists.txt +++ b/src/plugins/mini/CMakeLists.txt @@ -5,4 +5,5 @@ add_plugin ( SOURCES mini.h mini.c LINK_ELEKTRA elektra-ease elektra-utility ADD_TEST INSTALL_TEST_DATA TEST_README - TEST_REQUIRED_PLUGINS ccode) + TEST_REQUIRED_PLUGINS ccode + COMPONENT libelektra4) diff --git a/src/plugins/mmapstorage/CMakeLists.txt b/src/plugins/mmapstorage/CMakeLists.txt index 994f0feb6ff..2a881bc95fa 100644 --- a/src/plugins/mmapstorage/CMakeLists.txt +++ b/src/plugins/mmapstorage/CMakeLists.txt @@ -9,7 +9,6 @@ endif (DEPENDENCY_PHASE) set (MMAPSTORAGE_SOURCES dynarray.h dynarray.c mmapstorage.h mmapstorage.c) -# Plugin variant: mmapstorage_crc add_plugin ( mmapstorage_crc SOURCES ${MMAPSTORAGE_SOURCES} @@ -17,6 +16,7 @@ add_plugin ( LINK_LIBRARIES ${ZLIB_LIBRARIES} LINK_ELEKTRA elektra-core ADD_TEST + COMPONENT libelektra4-extra COMPILE_DEFINITIONS ELEKTRA_VARIANT=crc ELEKTRA_MMAP_CHECKSUM) # Plugin variant: mmapstorage @@ -24,4 +24,5 @@ add_plugin ( mmapstorage SOURCES ${MMAPSTORAGE_SOURCES} LINK_ELEKTRA elektra-core - ADD_TEST TEST_README) + ADD_TEST TEST_README + COMPONENT libelektra4) diff --git a/src/plugins/mozprefs/CMakeLists.txt b/src/plugins/mozprefs/CMakeLists.txt index 7857f266b1d..3869ad7dfec 100644 --- a/src/plugins/mozprefs/CMakeLists.txt +++ b/src/plugins/mozprefs/CMakeLists.txt @@ -4,4 +4,5 @@ add_plugin ( mozprefs SOURCES mozprefs.h mozprefs.c LINK_ELEKTRA elektra-utility - ADD_TEST INSTALL_TEST_DATA TEST_README) + ADD_TEST INSTALL_TEST_DATA TEST_README + COMPONENT libelektra4-extra) diff --git a/src/plugins/multifile/CMakeLists.txt b/src/plugins/multifile/CMakeLists.txt index 464ca073e78..50051cfdd4a 100644 --- a/src/plugins/multifile/CMakeLists.txt +++ b/src/plugins/multifile/CMakeLists.txt @@ -5,4 +5,5 @@ add_plugin ( SOURCES multifile.h multifile.c LINK_ELEKTRA elektra-kdb elektra-invoke TEST_README - TEST_REQUIRED_PLUGINS toml) + TEST_REQUIRED_PLUGINS toml + COMPONENT libelektra4) diff --git a/src/plugins/network/CMakeLists.txt b/src/plugins/network/CMakeLists.txt index d79fa23c94a..ceba1731e82 100644 --- a/src/plugins/network/CMakeLists.txt +++ b/src/plugins/network/CMakeLists.txt @@ -3,6 +3,7 @@ include (LibAddMacros) add_plugin ( network SOURCES network.h network.c - TEST_README) + TEST_README + COMPONENT libelektra4) add_plugintest (network ../ipaddr/test_ipaddr.h) diff --git a/src/plugins/ni/CMakeLists.txt b/src/plugins/ni/CMakeLists.txt index 9f8e0b5e2ea..e68486d5f90 100644 --- a/src/plugins/ni/CMakeLists.txt +++ b/src/plugins/ni/CMakeLists.txt @@ -9,7 +9,8 @@ add_plugin ( SOURCES ni.h ni.c ${NI_FILES} INCLUDE_DIRECTORIES ${NI}/include ${NI}/src/include LINK_ELEKTRA elektra-ease - ADD_TEST TEST_README) + ADD_TEST TEST_README + COMPONENT libelektra4) if (ADDTESTING_PHASE) file (GLOB NI_INI_FILES ${NI}/src/tests/*.ini) diff --git a/src/plugins/noresolver/CMakeLists.txt b/src/plugins/noresolver/CMakeLists.txt index af63bb3accb..202cbc7f6ec 100644 --- a/src/plugins/noresolver/CMakeLists.txt +++ b/src/plugins/noresolver/CMakeLists.txt @@ -1,3 +1,4 @@ include (LibAddMacros) -add_plugin (noresolver SOURCES noresolver.h noresolver.c) +add_plugin (noresolver SOURCES noresolver.h noresolver.c + COMPONENT libelektra4) diff --git a/src/plugins/passwd/CMakeLists.txt b/src/plugins/passwd/CMakeLists.txt index 3c7c7bb1251..f5334ab3d55 100644 --- a/src/plugins/passwd/CMakeLists.txt +++ b/src/plugins/passwd/CMakeLists.txt @@ -27,4 +27,5 @@ add_plugin ( passwd SOURCES passwd.h passwd.c COMPILE_DEFINITIONS ${PASSWD_COMPILE_DEFS} - ADD_TEST INSTALL_TEST_DATA) + ADD_TEST INSTALL_TEST_DATA + COMPONENT libelektra4-experimental) diff --git a/src/plugins/path/CMakeLists.txt b/src/plugins/path/CMakeLists.txt index 042b997a915..818484f9b00 100644 --- a/src/plugins/path/CMakeLists.txt +++ b/src/plugins/path/CMakeLists.txt @@ -42,4 +42,5 @@ endif () add_plugin ( path SOURCES path.h path.c - TEST_README) + TEST_README + COMPONENT libelektra4-extra) diff --git a/src/plugins/process/CMakeLists.txt b/src/plugins/process/CMakeLists.txt index 7d8cf338166..9232e805b7f 100644 --- a/src/plugins/process/CMakeLists.txt +++ b/src/plugins/process/CMakeLists.txt @@ -14,7 +14,8 @@ if (PLUGINPROCESS_FOUND) SOURCES process.h process.c ADD_TEST TEST_README TEST_REQUIRED_PLUGINS "dump" - LINK_ELEKTRA elektra-pluginprocess elektra-invoke) + LINK_ELEKTRA elektra-pluginprocess elektra-invoke + COMPONENT libelektra4-experimental) else (PLUGINPROCESS_FOUND) remove_plugin (process "${PLUGINPROCESS_NOTFOUND_INFO}, pluginprocess library excluded, thus also excluding the process plugin") endif (PLUGINPROCESS_FOUND) diff --git a/src/plugins/profile/CMakeLists.txt b/src/plugins/profile/CMakeLists.txt index dd5bd8872d9..f760418c9a9 100644 --- a/src/plugins/profile/CMakeLists.txt +++ b/src/plugins/profile/CMakeLists.txt @@ -3,4 +3,5 @@ include (LibAddMacros) add_plugin ( profile SOURCES profile.h profile.c - LINK_ELEKTRA elektra-ease) + LINK_ELEKTRA elektra-ease + COMPONENT libelektra4-extra) diff --git a/src/plugins/python/CMakeLists.txt b/src/plugins/python/CMakeLists.txt index 18cce0c0bbe..883ae05de68 100644 --- a/src/plugins/python/CMakeLists.txt +++ b/src/plugins/python/CMakeLists.txt @@ -51,7 +51,8 @@ add_plugin ( INCLUDE_DIRECTORIES ${PYTHON_INCLUDE_DIRS} LINK_LIBRARIES ${PYTHON_LIBRARIES} LINK_ELEKTRA elektra-pluginprocess - COMPILE_DEFINITIONS SWIG_TYPE_TABLE=kdb SWIG_RUNTIME=\"runtime.h\" PYTHON_PLUGIN_NAME=python PYTHON_PLUGIN_SYMBOL_NAME=Python) + COMPILE_DEFINITIONS SWIG_TYPE_TABLE=kdb SWIG_RUNTIME=\"runtime.h\" PYTHON_PLUGIN_NAME=python PYTHON_PLUGIN_SYMBOL_NAME=Python + COMPONENT libelektra4-python) if (ADDTESTING_PHASE) # bindings are required for tests @@ -64,7 +65,7 @@ if (ADDTESTING_PHASE) if (INSTALL_TESTING) - install (DIRECTORY ${CMAKE_SOURCE_DIR}/src/plugins/python/python/ DESTINATION "${TARGET_TEST_DATA_FOLDER}/python") + install (DIRECTORY ${CMAKE_SOURCE_DIR}/src/plugins/python/python/ DESTINATION "${TARGET_TEST_DATA_FOLDER}/python" COMPONENT elektra-tests) endif () else () diff --git a/src/plugins/quickdump/CMakeLists.txt b/src/plugins/quickdump/CMakeLists.txt index 7b761bc021a..c3301d85b8f 100644 --- a/src/plugins/quickdump/CMakeLists.txt +++ b/src/plugins/quickdump/CMakeLists.txt @@ -3,7 +3,8 @@ include (LibAddMacros) add_plugin ( quickdump SOURCES quickdump.h quickdump.c - TEST_README) + TEST_README + COMPONENT libelektra4) if (ADDTESTING_PHASE) add_plugintest (quickdump INSTALL_TEST_DATA INCLUDE_DIRECTORIES ${CMAKE_CURRENT_BINARY_DIR}) diff --git a/src/plugins/range/CMakeLists.txt b/src/plugins/range/CMakeLists.txt index e4426e8b3ae..28b8d1d5863 100644 --- a/src/plugins/range/CMakeLists.txt +++ b/src/plugins/range/CMakeLists.txt @@ -8,7 +8,8 @@ add_plugin ( range SOURCES range.h range.c LINK_LIBRARIES m - ADD_TEST TEST_README) + ADD_TEST TEST_README + COMPONENT libelektra4-experimental) if (ADDTESTING_PHASE) if (CMAKE_C_COMPILER_ID STREQUAL "Clang" OR CMAKE_CXX_COMPILER_ID STREQUAL "Clang") diff --git a/src/plugins/reference/CMakeLists.txt b/src/plugins/reference/CMakeLists.txt index 47b334a458b..5b065bdc3a1 100644 --- a/src/plugins/reference/CMakeLists.txt +++ b/src/plugins/reference/CMakeLists.txt @@ -5,4 +5,5 @@ add_plugin ( SOURCES reference.h reference.c referencegraph.c referencegraph.h LINK_ELEKTRA elektra-ease elektra-globbing ADD_TEST TEST_README - TEST_REQUIRED_PLUGINS dump sync) + TEST_REQUIRED_PLUGINS dump sync + COMPONENT libelektra4-experimental) diff --git a/src/plugins/rename/CMakeLists.txt b/src/plugins/rename/CMakeLists.txt index ac27405b88d..f248187e04d 100644 --- a/src/plugins/rename/CMakeLists.txt +++ b/src/plugins/rename/CMakeLists.txt @@ -2,4 +2,5 @@ add_plugin ( rename SOURCES rename.h rename.c ADD_TEST TEST_README - TEST_REQUIRED_PLUGINS mini) + TEST_REQUIRED_PLUGINS mini + COMPONENT libelektra4) diff --git a/src/plugins/resolver/CMakeLists.txt b/src/plugins/resolver/CMakeLists.txt index 0a3adc36e99..e7bf317e86a 100644 --- a/src/plugins/resolver/CMakeLists.txt +++ b/src/plugins/resolver/CMakeLists.txt @@ -60,6 +60,13 @@ foreach (plugin ${RESOLVERS}) set (SOURCES resolver.h resolver.c filename.c) + set (HAS_COMPONENT "") + if (plugin MATCHES "resolver_fm_hpu_b") + set (HAS_COMPONENT "libelektra4") + else() + set (HAS_COMPONENT "libelektra4-extra") + endif() + add_plugin ( ${plugin} SOURCES ${SOURCES} @@ -67,7 +74,8 @@ foreach (plugin ${RESOLVERS}) COMPILE_DEFINITIONS ELEKTRA_VARIANT_BASE=\"${variant_base}\" ELEKTRA_VARIANT_USER=\"${variant_user}\" ELEKTRA_VARIANT_SYSTEM=\"${variant_system}\" ELEKTRA_VARIANT=${variant} ELEKTRA_PLUGIN_NAME=\"${plugin}\" - ${FURTHER_DEFINITIONS}) + ${FURTHER_DEFINITIONS} + COMPONENT "${HAS_COMPONENT}") if (variant MATCHES "fm_hpu_b") add_plugintest ( diff --git a/src/plugins/rgbcolor/CMakeLists.txt b/src/plugins/rgbcolor/CMakeLists.txt index 4276eae5cfd..7f6557530d4 100644 --- a/src/plugins/rgbcolor/CMakeLists.txt +++ b/src/plugins/rgbcolor/CMakeLists.txt @@ -3,4 +3,5 @@ include (LibAddMacros) add_plugin ( rgbcolor SOURCES rgbcolor.h rgbcolor.c - ADD_TEST TEST_README) + ADD_TEST TEST_README + COMPONENT libelektra4-extra) diff --git a/src/plugins/shell/CMakeLists.txt b/src/plugins/shell/CMakeLists.txt index fbbf6613cfa..68f594e47c2 100644 --- a/src/plugins/shell/CMakeLists.txt +++ b/src/plugins/shell/CMakeLists.txt @@ -1,3 +1,4 @@ include (LibAddMacros) -add_plugin (shell TEST_README SOURCES shell.h shell.c) +add_plugin (shell TEST_README SOURCES shell.h shell.c + COMPONENT libelektra4) diff --git a/src/plugins/simpleini/CMakeLists.txt b/src/plugins/simpleini/CMakeLists.txt index 9671eb2c96f..960075b277c 100644 --- a/src/plugins/simpleini/CMakeLists.txt +++ b/src/plugins/simpleini/CMakeLists.txt @@ -8,6 +8,7 @@ if (HAVE_GLIBC) simpleini SOURCES simpleini.h simpleini.c LINK_ELEKTRA elektra-ease elektra-utility + COMPONENT libelektra4 ADD_TEST) else () remove_plugin (simpleini "simpleini needs glibc to work, use the mini plugin instead") diff --git a/src/plugins/spec/CMakeLists.txt b/src/plugins/spec/CMakeLists.txt index ae7dc8f0fea..d78dbb85e65 100644 --- a/src/plugins/spec/CMakeLists.txt +++ b/src/plugins/spec/CMakeLists.txt @@ -4,4 +4,5 @@ add_plugin ( spec SOURCES spec.h spec.c LINK_ELEKTRA elektra-ease elektra-meta elektra-globbing - ADD_TEST) + ADD_TEST + COMPONENT libelektra4) diff --git a/src/plugins/specload/CMakeLists.txt b/src/plugins/specload/CMakeLists.txt index b03b95b52a3..27981dcf6de 100644 --- a/src/plugins/specload/CMakeLists.txt +++ b/src/plugins/specload/CMakeLists.txt @@ -4,7 +4,8 @@ add_plugin ( specload SOURCES specload.h specload.c LINK_ELEKTRA elektra-ease elektra-invoke - TEST_README) + TEST_README + COMPONENT libelektra4) if (DEPENDENCY_PHASE AND BUILD_SHARED) add_dependencies (elektra-specload elektra-quickdump) diff --git a/src/plugins/sync/CMakeLists.txt b/src/plugins/sync/CMakeLists.txt index e24d2731395..67d7c7034c2 100644 --- a/src/plugins/sync/CMakeLists.txt +++ b/src/plugins/sync/CMakeLists.txt @@ -1,3 +1,4 @@ include (LibAddMacros) -add_plugin (sync SOURCES sync.h sync.c) +add_plugin (sync SOURCES sync.h sync.c + COMPONENT libelektra4) diff --git a/src/plugins/syslog/CMakeLists.txt b/src/plugins/syslog/CMakeLists.txt index 10a317408a2..8e41837c884 100644 --- a/src/plugins/syslog/CMakeLists.txt +++ b/src/plugins/syslog/CMakeLists.txt @@ -1,3 +1,3 @@ include (LibAddMacros) -add_plugin (syslog SOURCES log.h syslog.c) +add_plugin (syslog SOURCES log.h syslog.c COMPONENT libelektra4-extra) diff --git a/src/plugins/template/CMakeLists.txt b/src/plugins/template/CMakeLists.txt index 322e22283f4..4cff109b934 100644 --- a/src/plugins/template/CMakeLists.txt +++ b/src/plugins/template/CMakeLists.txt @@ -3,4 +3,5 @@ include (LibAddMacros) add_plugin ( template SOURCES template.h template.c - ADD_TEST TEST_README) + ADD_TEST TEST_README + COMPONENT libelektra4-experimental) diff --git a/src/plugins/timeofday/CMakeLists.txt b/src/plugins/timeofday/CMakeLists.txt index 83b440e3951..dc78ae044f5 100644 --- a/src/plugins/timeofday/CMakeLists.txt +++ b/src/plugins/timeofday/CMakeLists.txt @@ -1,3 +1,3 @@ include (LibAddMacros) -add_plugin (timeofday SOURCES timeofday.h timeofday.c) +add_plugin (timeofday SOURCES timeofday.h timeofday.c COMPONENT libelektra4-extra) diff --git a/src/plugins/toml/CMakeLists.txt b/src/plugins/toml/CMakeLists.txt index d32d85bc22c..a5ef343672d 100644 --- a/src/plugins/toml/CMakeLists.txt +++ b/src/plugins/toml/CMakeLists.txt @@ -150,4 +150,5 @@ add_plugin ( TEST_REQUIRED_PLUGINS type base64 LINK_ELEKTRA elektra-meta SOURCES ${SOURCE_FILES} - INCLUDE_DIRECTORIES ${CMAKE_CURRENT_SOURCE_DIR}) + INCLUDE_DIRECTORIES ${CMAKE_CURRENT_SOURCE_DIR} + COMPONENT libelektra4) diff --git a/src/plugins/tracer/CMakeLists.txt b/src/plugins/tracer/CMakeLists.txt index 2fdba510190..4b231390d6b 100644 --- a/src/plugins/tracer/CMakeLists.txt +++ b/src/plugins/tracer/CMakeLists.txt @@ -1,3 +1,3 @@ include (LibAddMacros) -add_plugin (tracer SOURCES tracer.h tracer.c) +add_plugin (tracer SOURCES tracer.h tracer.c COMPONENT libelektra4-extra) diff --git a/src/plugins/type/CMakeLists.txt b/src/plugins/type/CMakeLists.txt index 938042c57f7..41ef105de9b 100644 --- a/src/plugins/type/CMakeLists.txt +++ b/src/plugins/type/CMakeLists.txt @@ -2,4 +2,5 @@ add_plugin ( type SOURCES type.h type.c types.h types.c LINK_ELEKTRA elektra-meta elektra-ease - ADD_TEST TEST_README) + ADD_TEST TEST_README + COMPONENT libelektra4) diff --git a/src/plugins/uname/CMakeLists.txt b/src/plugins/uname/CMakeLists.txt index e92bb0cd8e3..fa8265be35d 100644 --- a/src/plugins/uname/CMakeLists.txt +++ b/src/plugins/uname/CMakeLists.txt @@ -12,4 +12,5 @@ add_plugin ( uname SOURCES uname.h uname.c ADD_TEST TEST_README - TEST_REQUIRED_PLUGINS noresolver) + TEST_REQUIRED_PLUGINS noresolver + COMPONENT libelektra4-extra) diff --git a/src/plugins/unit/CMakeLists.txt b/src/plugins/unit/CMakeLists.txt index 0dedfa0d0d8..cd0b17c37de 100644 --- a/src/plugins/unit/CMakeLists.txt +++ b/src/plugins/unit/CMakeLists.txt @@ -3,4 +3,5 @@ include (LibAddMacros) add_plugin ( unit SOURCES unit.h unit.c - ADD_TEST TEST_README) + ADD_TEST TEST_README + COMPONENT libelektra4-extra) diff --git a/src/plugins/validation/CMakeLists.txt b/src/plugins/validation/CMakeLists.txt index d16381fc04b..49dac2c4b57 100644 --- a/src/plugins/validation/CMakeLists.txt +++ b/src/plugins/validation/CMakeLists.txt @@ -3,4 +3,5 @@ include (LibAddMacros) add_plugin ( validation SOURCES validation.h validation.c lookupre.c - ADD_TEST) + ADD_TEST + COMPONENT libelektra4) diff --git a/src/plugins/wresolver/CMakeLists.txt b/src/plugins/wresolver/CMakeLists.txt index 081ec0990cf..e8aefe17cd7 100644 --- a/src/plugins/wresolver/CMakeLists.txt +++ b/src/plugins/wresolver/CMakeLists.txt @@ -1,3 +1,4 @@ include (LibAddMacros) -add_plugin (wresolver SOURCES wresolver.h wresolver.c) +add_plugin (wresolver SOURCES wresolver.h wresolver.c + COMPONENT libelektra4) diff --git a/src/plugins/xerces/CMakeLists.txt b/src/plugins/xerces/CMakeLists.txt index d06b4cb9c44..60b8d5d5a6f 100644 --- a/src/plugins/xerces/CMakeLists.txt +++ b/src/plugins/xerces/CMakeLists.txt @@ -22,7 +22,8 @@ add_plugin ( INCLUDE_SYSTEM_DIRECTORIES ${XercesC_INCLUDE_DIRS} LINK_LIBRARIES ${XercesC_LIBRARIES} LINK_ELEKTRA elektra-meta - INSTALL_TEST_DATA TEST_README) + INSTALL_TEST_DATA TEST_README + COMPONENT libelektra4-xerces) if (ADDTESTING_PHASE) include (LibAddTest) diff --git a/src/plugins/xmltool/CMakeLists.txt b/src/plugins/xmltool/CMakeLists.txt index e5104034787..143d52fec3b 100644 --- a/src/plugins/xmltool/CMakeLists.txt +++ b/src/plugins/xmltool/CMakeLists.txt @@ -12,7 +12,8 @@ add_plugin ( INSTALL_TEST_DATA INCLUDE_DIRECTORIES ${LIBXML2_INCLUDE_DIR} LINK_ELEKTRA elektra-meta - LINK_LIBRARIES ${LIBXML2_LIBRARIES}) + LINK_LIBRARIES ${LIBXML2_LIBRARIES} + COMPONENT libelektra4-xmltool) if (ADDTESTING_PHASE) include (LibAddMacros) diff --git a/src/plugins/yajl/CMakeLists.txt b/src/plugins/yajl/CMakeLists.txt index 4c347b47a14..a8e94eada08 100644 --- a/src/plugins/yajl/CMakeLists.txt +++ b/src/plugins/yajl/CMakeLists.txt @@ -24,4 +24,5 @@ add_plugin ( INSTALL_TEST_DATA INCLUDE_DIRECTORIES "${INCL}" LINK_ELEKTRA elektra-ease - LINK_LIBRARIES ${YAJL_LIBRARIES}) + LINK_LIBRARIES ${YAJL_LIBRARIES} + COMPONENT libelektra4-yajl) diff --git a/src/plugins/yamlsmith/CMakeLists.txt b/src/plugins/yamlsmith/CMakeLists.txt index 16e02521863..75684feac0d 100644 --- a/src/plugins/yamlsmith/CMakeLists.txt +++ b/src/plugins/yamlsmith/CMakeLists.txt @@ -2,4 +2,5 @@ add_plugin ( yamlsmith CPP SOURCES yamlsmith.hpp yamlsmith.cpp LINK_ELEKTRA elektra-ease - ADD_TEST TEST_README) + ADD_TEST TEST_README + COMPONENT libelektra4-extra) diff --git a/src/plugins/zeromqrecv/CMakeLists.txt b/src/plugins/zeromqrecv/CMakeLists.txt index 0d99d88f3f4..0ad078f18de 100644 --- a/src/plugins/zeromqrecv/CMakeLists.txt +++ b/src/plugins/zeromqrecv/CMakeLists.txt @@ -14,7 +14,8 @@ add_plugin ( OBJECT_SOURCES $ INCLUDE_DIRECTORIES ${ZeroMQ_INCLUDE_DIR} LINK_ELEKTRA elektra-io - LINK_LIBRARIES ${ZeroMQ_LIBRARIES}) + LINK_LIBRARIES ${ZeroMQ_LIBRARIES} + COMPONENT libelektra4-zeromq) if (ADDTESTING_PHASE) check_binding_was_added ("io_uv" IS_INCLUDED) diff --git a/src/plugins/zeromqsend/CMakeLists.txt b/src/plugins/zeromqsend/CMakeLists.txt index 01ff426be1f..dfd54554a44 100644 --- a/src/plugins/zeromqsend/CMakeLists.txt +++ b/src/plugins/zeromqsend/CMakeLists.txt @@ -10,7 +10,8 @@ add_plugin ( zeromqsend SOURCES zeromqsend.h zeromqsend.c publish.c INCLUDE_DIRECTORIES ${ZeroMQ_INCLUDE_DIR} - LINK_LIBRARIES ${ZeroMQ_LIBRARIES}) + LINK_LIBRARIES ${ZeroMQ_LIBRARIES} + COMPONENT libelektra4-zeromq) if (ADDTESTING_PHASE) # the test requires pthread find_package (Threads QUIET) diff --git a/src/tools/kdb/CMakeLists.txt b/src/tools/kdb/CMakeLists.txt index 4e978c4b811..829cc9be13f 100644 --- a/src/tools/kdb/CMakeLists.txt +++ b/src/tools/kdb/CMakeLists.txt @@ -23,7 +23,7 @@ if (BUILD_SHARED) target_link_libraries (kdb elektra-core elektra-kdb elektratools elektra-opts elektra-merge) - install (TARGETS kdb DESTINATION bin) + install (TARGETS kdb DESTINATION bin COMPONENT elektra-bin) endif (BUILD_SHARED) if (BUILD_FULL) @@ -32,7 +32,7 @@ if (BUILD_FULL) target_link_libraries (kdb-full elektra-full elektratools-full) - install (TARGETS kdb-full DESTINATION bin) + install (TARGETS kdb-full DESTINATION bin COMPONENT libelektra4-full) endif (BUILD_FULL) if (BUILD_STATIC) @@ -50,5 +50,5 @@ if (BUILD_STATIC) set_target_properties (kdb-static PROPERTIES LINK_FLAGS ${CMAKE_STATIC_FLAGS}) endif () - install (TARGETS kdb-static DESTINATION bin) + install (TARGETS kdb-static DESTINATION bin COMPONENT elektra-bin) endif (BUILD_STATIC) diff --git a/src/tools/qt-gui/CMakeLists.txt b/src/tools/qt-gui/CMakeLists.txt index b4f0d23598e..b478edf1233 100644 --- a/src/tools/qt-gui/CMakeLists.txt +++ b/src/tools/qt-gui/CMakeLists.txt @@ -80,19 +80,21 @@ else () ${Qt5DBus_LIBRARIES}) tool_link_elektratools (qt-gui elektra-ease) - install (TARGETS qt-gui DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) + install (TARGETS qt-gui DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-qt-gui) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/elektra-qt-editor.in" "${CMAKE_CURRENT_BINARY_DIR}/elektra-qt-editor") - install (PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/elektra-qt-editor" DESTINATION bin) - install (FILES org.libelektra.elektra-qt-editor.desktop DESTINATION share/applications) - install (FILES org.libelektra.elektra-qt-editor.appdata.xml DESTINATION share/appdata) + install (PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/elektra-qt-editor" DESTINATION bin COMPONENT elektra-qt-gui) + install (FILES org.libelektra.elektra-qt-editor.desktop DESTINATION share/applications COMPONENT elektra-qt-gui) + install (FILES org.libelektra.elektra-qt-editor.appdata.xml DESTINATION share/appdata COMPONENT elektra-qt-gui) install ( FILES ../../../doc/images/logo/logo_color.svg DESTINATION share/icons/hicolor/scalable/apps - RENAME elektra.svg) + RENAME elektra.svg + COMPONENT elektra-qt-gui) install ( FILES ../../../doc/images/logo/logo_gray.svg DESTINATION share/icons/hicolor/scalable/apps - RENAME elektra-symbolic.svg) + RENAME elektra-symbolic.svg + COMPONENT elektra-qt-gui) generate_manpage (kdb-qt-gui FILENAME ${CMAKE_CURRENT_SOURCE_DIR}/README.md) diff --git a/src/tools/race/CMakeLists.txt b/src/tools/race/CMakeLists.txt index ae36f8db5e4..89ca5ba0c89 100644 --- a/src/tools/race/CMakeLists.txt +++ b/src/tools/race/CMakeLists.txt @@ -18,5 +18,5 @@ else () target_link_libraries (race ${CMAKE_THREAD_LIBS_INIT}) target_link_libraries (race ${LIBRT_LIBRARIES}) - install (TARGETS race DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) + install (TARGETS race DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-tests) endif () diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index 61ec690a69c..d34e91fd410 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -51,7 +51,7 @@ macro (do_test source) add_executable (${source} ${SOURCES}) if (INSTALL_TESTING) - install (TARGETS ${source} DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) + install (TARGETS ${source} DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-tests) endif (INSTALL_TESTING) target_link_elektra (${source}) diff --git a/tests/shell/CMakeLists.txt b/tests/shell/CMakeLists.txt index 286c3399c37..cc45e962f63 100644 --- a/tests/shell/CMakeLists.txt +++ b/tests/shell/CMakeLists.txt @@ -48,6 +48,11 @@ function (add_scripttest testname) message (SEND_ERROR "add_scripttest: given file ${filename} does not exists") endif (NOT EXISTS ${filename}) + set ( + COMPONENT_BIN_EXTRA_FILES + generate_data + ) + foreach (TARGET true false) if (TARGET) if (INSTALL_TESTING) @@ -62,6 +67,12 @@ function (add_scripttest testname) check_plugins check_spelling) + if ("${testname_we}" IN_LIST COMPONENT_BIN_EXTRA_FILES) + set(HAS_COMPONENT elektra-bin-extra) + else() + set(HAS_COMPONENT elektra-tests) + endif() + list (FIND excluded_tests "${testname_we}" index_excluded) if (index_excluded EQUAL -1) set (RACE_COMMAND "$KDB race") @@ -78,7 +89,8 @@ function (add_scripttest testname) GROUP_EXECUTE WORLD_READ WORLD_EXECUTE - RENAME ${testname_we}) + RENAME ${testname_we} + COMPONENT ${HAS_COMPONENT}) endif (index_excluded EQUAL -1) endif (INSTALL_TESTING) @@ -115,7 +127,7 @@ function (add_scripttest testname) endfunction (add_scripttest) if (INSTALL_TESTING) - install (DIRECTORY "shell" DESTINATION ${TARGET_TEST_DATA_FOLDER}) + install (DIRECTORY "shell" DESTINATION ${TARGET_TEST_DATA_FOLDER} COMPONENT elektra-tests) endif (INSTALL_TESTING) file (GLOB SCRIPT_TESTS *.sh) diff --git a/tests/shell/external/CMakeLists.txt b/tests/shell/external/CMakeLists.txt index 5663322a209..5fda42e154b 100644 --- a/tests/shell/external/CMakeLists.txt +++ b/tests/shell/external/CMakeLists.txt @@ -31,7 +31,8 @@ function (add_externaltest testname) GROUP_EXECUTE WORLD_READ WORLD_EXECUTE - RENAME "check_external_${testname_we}") + RENAME "check_external_${testname_we}" + COMPONENT elektra-tests) endif (ENABLE_KDB_TESTING AND INSTALL_TESTING) endfunction (add_externaltest) diff --git a/tests/shell/gen/CMakeLists.txt b/tests/shell/gen/CMakeLists.txt index fd28e24fa85..33d123b0b4a 100644 --- a/tests/shell/gen/CMakeLists.txt +++ b/tests/shell/gen/CMakeLists.txt @@ -25,10 +25,11 @@ endforeach () unset (C_FLAG_32BIT) if (INSTALL_TESTING) - install (DIRECTORY "." DESTINATION "${TARGET_TEST_DATA_FOLDER}/gen") + install (DIRECTORY "." DESTINATION "${TARGET_TEST_DATA_FOLDER}/gen" COMPONENT elektra-tests) install ( DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}" DESTINATION "${TARGET_TEST_DATA_FOLDER}/gen" + COMPONENT elektra-tests FILES_MATCHING PATTERN "*.sh") endif (INSTALL_TESTING) From 1e88436b415cf298e3b7fb75ccd2da211c71c873 Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Sat, 5 Dec 2020 12:09:47 +0100 Subject: [PATCH 02/32] cpack: add debian package descriptions --- scripts/cmake/ElektraPackaging.cmake | 103 ++++++++++++++------------- 1 file changed, 55 insertions(+), 48 deletions(-) diff --git a/scripts/cmake/ElektraPackaging.cmake b/scripts/cmake/ElektraPackaging.cmake index e0cde75f048..d50200c97e9 100644 --- a/scripts/cmake/ElektraPackaging.cmake +++ b/scripts/cmake/ElektraPackaging.cmake @@ -102,122 +102,129 @@ if (UNIX) set (CPACK_DEBIAN_RUNTIME_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_NAME "libelektra4") - set (CPACK_COMPONENT_LIBELEKTRA4_DISPLAY_NAME "") - set (CPACK_COMPONENT_LIBELEKTRA4_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4_DISPLAY_NAME "libelektra4") + set ( + CPACK_COMPONENT_LIBELEKTRA4_DESCRIPTION + "This package contains the main elektra library, and most of the core plugins") set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_NAME "libelektra4-full") - set (CPACK_COMPONENT_LIBELEKTRA4-FULL_DISPLAY_NAME "") - set (CPACK_COMPONENT_LIBELEKTRA4-FULL_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-FULL_DISPLAY_NAME "libelektra4-full") + set ( + CPACK_COMPONENT_LIBELEKTRA4-FULL_DESCRIPTION + "This package contains an variant of the Elektra library in which all plugins + are linked together to a full library. The package is only needed for testing.") set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_PACKAGE_NAME "libelektra4-experimental") - set (CPACK_COMPONENT_LIBELEKTRA4-EXPERIMENTAL_DISPLAY_NAME "") - set (CPACK_COMPONENT_LIBELEKTRA4-EXPERIMENTAL_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-EXPERIMENTAL_DISPLAY_NAME "libelektra4-experimental") + set (CPACK_COMPONENT_LIBELEKTRA4-EXPERIMENTAL_DESCRIPTION "This package contains experimental plugins.") set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_PACKAGE_NAME "libelektra4-extra") - set (CPACK_COMPONENT_LIBELEKTRA4-EXTRA_DISPLAY_NAME "") - set (CPACK_COMPONENT_LIBELEKTRA4-EXTRA_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-EXTRA_DISPLAY_NAME "libelektra4-extra") + set (CPACK_COMPONENT_LIBELEKTRA4-EXTRA_DESCRIPTION "This package contains extra plugins.") set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_NAME "elektra-bin") - set (CPACK_COMPONENT_ELEKTRA-BIN_DISPLAY_NAME "") - set (CPACK_COMPONENT_ELEKTRA-BIN_DESCRIPTION "") + set (CPACK_COMPONENT_ELEKTRA-BIN_DISPLAY_NAME "elektra-bin") + set (CPACK_COMPONENT_ELEKTRA-BIN_DESCRIPTION "This package contains command line utilities for Elektra.") set (CPACK_COMPONENT_ELEKTRA-BIN_DEPENDS "libelektra4") set (CPACK_DEBIAN_LIBELEKTRA4-AUGEAS_PACKAGE_NAME "libelektra4-augeas") - set (CPACK_COMPONENT_LIBELEKTRA4-AUGEAS_DISPLAY_NAME "") - set (CPACK_COMPONENT_LIBELEKTRA4-AUGEAS_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-AUGEAS_DISPLAY_NAME "libelektra4-augeas") + set (CPACK_COMPONENT_LIBELEKTRA4-AUGEAS_DESCRIPTION "This package contains the 'augeas' plugin.") set (CPACK_COMPONENT_LIBELEKTRA4-AUGEAS_DEPENDS "libelektra4") set (CPACK_DEBIAN_LIBELEKTRA4-DBUS_PACKAGE_NAME "libelektra4-dbus") - set (CPACK_COMPONENT_LIBELEKTRA4-DBUS_DISPLAY_NAME "") - set (CPACK_COMPONENT_LIBELEKTRA4-DBUS_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-DBUS_DISPLAY_NAME "libelektra4-dbus") + set (CPACK_COMPONENT_LIBELEKTRA4-DBUS_DESCRIPTION "This package contains the 'dbus' plugins.") set (CPACK_COMPONENT_LIBELEKTRA4-DBUS_DEPENDS "libelektra4") set (CPACK_DEBIAN_LIBELEKTRA-DEV_PACKAGE_NAME "libelektra-dev") - set (CPACK_COMPONENT_LIBELEKTRA-DEV_DISPLAY_NAME "") - set (CPACK_COMPONENT_LIBELEKTRA-DEV_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA-DEV_DISPLAY_NAME "libelektra-dev") + set (CPACK_COMPONENT_LIBELEKTRA-DEV_DESCRIPTION "This package contains the development files for the main Elektra library.") set (CPACK_COMPONENT_LIBELEKTRA4-DBUS_DEPENDS "libelektra4") set (CPACK_DEBIAN_LIBELEKTRA4-ZEROMQ_PACKAGE_NAME "libelektra4-zeromq") - set (CPACK_COMPONENT_LIBELEKTRA4-ZEROMQ_DISPLAY_NAME "") - set (CPACK_COMPONENT_LIBELEKTRA4-ZEROMQ_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-ZEROMQ_DISPLAY_NAME "libelektra4-zeromq") + set (CPACK_COMPONENT_LIBELEKTRA4-ZEROMQ_DESCRIPTION "This package contains the 'zeromq' plugins.") set (CPACK_COMPONENT_LIBELEKTRA4-ZEROMQ_DEPENDS "libelektra4") set (CPACK_DEBIAN_LIBELEKTRA4-XMLTOOL_PACKAGE_NAME "libelektra4-xmltool") - set (CPACK_COMPONENT_LIBELEKTRA4-XMLTOOL_DISPLAY_NAME "") - set (CPACK_COMPONENT_LIBELEKTRA4-XMLTOOL_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-XMLTOOL_DISPLAY_NAME "libelektra4-xmltool") + set (CPACK_COMPONENT_LIBELEKTRA4-XMLTOOL_DESCRIPTION "This package contains the 'xmltool' plugin.") set (CPACK_COMPONENT_LIBELEKTRA4-XMLTOOL_DEPENDS "libelektra4") set (CPACK_DEBIAN_LIBELEKTRA4-XERCES_PACKAGE_NAME "libelektra4-xerces") - set (CPACK_COMPONENT_LIBELEKTRA4-XERCES_DISPLAY_NAME "") - set (CPACK_COMPONENT_LIBELEKTRA4-XERCES_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-XERCES_DISPLAY_NAME "libelektra4-xerces") + set (CPACK_COMPONENT_LIBELEKTRA4-XERCES_DESCRIPTION "This package contains the 'xerces' plugin.") set (CPACK_COMPONENT_LIBELEKTRA4-XERCES_DEPENDS "libelektra4") set (CPACK_DEBIAN_LIBELEKTRA4-YAJL_PACKAGE_NAME "libelektra4-yajl") - set (CPACK_COMPONENT_LIBELEKTRA4-YAJL_DISPLAY_NAME "") - set (CPACK_COMPONENT_LIBELEKTRA4-YAJL_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-YAJL_DISPLAY_NAME "libelektra4-yajl") + set (CPACK_COMPONENT_LIBELEKTRA4-YAJL_DESCRIPTION "This package contains the 'yajl' plugin.") set (CPACK_COMPONENT_LIBELEKTRA4-YAJL_DEPENDS "libelektra4") set (CPACK_DEBIAN_LIBELEKTRA4-CRYPTO_PACKAGE_NAME "libelektra4-crypto") - set (CPACK_COMPONENT_LIBELEKTRA4-CRYPTO_DISPLAY_NAME "") - set (CPACK_COMPONENT_LIBELEKTRA4-CRYPTO_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-CRYPTO_DISPLAY_NAME "libelektra4-crypto") + set (CPACK_COMPONENT_LIBELEKTRA4-CRYPTO_DESCRIPTION "This package contains the crypto plugins.") set (CPACK_COMPONENT_LIBELEKTRA4-CRYPTO_DEPENDS "libelektra4") set (CPACK_DEBIAN_LIBELEKTRA4-CURL_PACKAGE_NAME "libelektra4-curl") - set (CPACK_COMPONENT_LIBELEKTRA4-CURL_DISPLAY_NAME "") - set (CPACK_COMPONENT_LIBELEKTRA4-CURL_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-CURL_DISPLAY_NAME "libelektra4-curl") + set (CPACK_COMPONENT_LIBELEKTRA4-CURL_DESCRIPTION "This package contains the 'curlget' plugin.") set (CPACK_COMPONENT_LIBELEKTRA4-CURL_DEPENDS "libelektra4") set (CPACK_DEBIAN_LIBELEKTRA4-JOURNALD_PACKAGE_NAME "libelektra4-journald") - set (CPACK_COMPONENT_LIBELEKTRA4-JOURNALD_DISPLAY_NAME "") - set (CPACK_COMPONENT_LIBELEKTRA4-JOURNALD_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-JOURNALD_DISPLAY_NAME "libelektra4-journald") + set (CPACK_COMPONENT_LIBELEKTRA4-JOURNALD_DESCRIPTION "This package contains the 'journald' plugins.") set (CPACK_COMPONENT_LIBELEKTRA4-JOURNALD_DEPENDS "libelektra4") set (CPACK_DEBIAN_LIBELEKTRA4-LUA_PACKAGE_NAME "libelektra4-lua") - set (CPACK_COMPONENT_LIBELEKTRA4-LUA_DISPLAY_NAME "") - set (CPACK_COMPONENT_LIBELEKTRA4-LUA_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-LUA_DISPLAY_NAME "libelektra4-lua") + set (CPACK_COMPONENT_LIBELEKTRA4-LUA_DESCRIPTION "This package contains the 'lua' plugin.") set (CPACK_COMPONENT_LIBELEKTRA4-LUA_DEPENDS "libelektra4") set (CPACK_DEBIAN_LUA-ELEKTRA_PACKAGE_NAME "lua-elektra") - set (CPACK_COMPONENT_LUA-ELEKTRA_DISPLAY_NAME "") - set (CPACK_COMPONENT_LUA-ELEKTRA_DESCRIPTION "") + set (CPACK_COMPONENT_LUA-ELEKTRA_DISPLAY_NAME "lua-elektra") + set (CPACK_COMPONENT_LUA-ELEKTRA_DESCRIPTION "This package contains the Lua bindings.") set (CPACK_COMPONENT_LUA-ELEKTRA_DEPENDS "libelektra4") # maybe add python3:depends? (see control file) set (CPACK_DEBIAN_PYTHON3-ELEKTRA_PACKAGE_NAME "python3-elektra") - set (CPACK_COMPONENT_PYTHON3-ELEKTRA_DISPLAY_NAME "") - set (CPACK_COMPONENT_PYTHON3-ELEKTRA_DESCRIPTION "") + set (CPACK_COMPONENT_PYTHON3-ELEKTRA_DISPLAY_NAME "python3-elektra") + set (CPACK_COMPONENT_PYTHON3-ELEKTRA_DESCRIPTION "This package contains the Python 3 bindings.") set (CPACK_COMPONENT_PYTHON3-ELEKTRA_DEPENDS "libelektra4") set (CPACK_DEBIAN_LIBELEKTRA4-PYTHON_PACKAGE_NAME "libelektra4-python") - set (CPACK_COMPONENT_LIBELEKTRA4-PYTHON_DISPLAY_NAME "") - set (CPACK_COMPONENT_LIBELEKTRA4-PYTHON_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-PYTHON_DISPLAY_NAME "libelektra4-python") + set (CPACK_COMPONENT_LIBELEKTRA4-PYTHON_DESCRIPTION "This package contains the 'python' plugin.") set (CPACK_COMPONENT_LIBELEKTRA4-PYTHON_DEPENDS "libelektra4" "python3-elektra") set (CPACK_DEBIAN_ELEKTRA-BIN-EXTRA_PACKAGE_NAME "elektra-bin-extra") - set (CPACK_COMPONENT_ELEKTRA-BIN-EXTRA_DISPLAY_NAME "") - set (CPACK_COMPONENT_LEKTRA-BIN-EXTRA_DESCRIPTION "") + set (CPACK_COMPONENT_ELEKTRA-BIN-EXTRA_DISPLAY_NAME "elektra-bin-extra") + set ( + CPACK_COMPONENT_LEKTRA-BIN-EXTRA_DESCRIPTION + "This package contains extra command line utilities for Elektra written in non-shell languages like python.") set (CPACK_COMPONENT_ELEKTRA-BIN-EXTRA_DEPENDS "libelektra4") set (CPACK_DEBIAN_ELEKTRA-BIN-EXTRA_PACKAGE_DEPENDS "python-all") set (CPACK_DEBIAN_ELEKTRA-QT-GUI_PACKAGE_NAME "elektra-qt-gui") - set (CPACK_COMPONENT_ELEKTRA-QT-GUI_DISPLAY_NAME "") - set (CPACK_COMPONENT_ELEKTRA-QT-GUI_DESCRIPTION "") + set (CPACK_COMPONENT_ELEKTRA-QT-GUI_DISPLAY_NAME "elektra-qt-gui") + set (CPACK_COMPONENT_ELEKTRA-QT-GUI_DESCRIPTION "This package contains a Qt-based graphical interface for Elektra.") set (CPACK_COMPONENT_ELEKTRA-QT-GUI_DEPENDS "libelektra4") # TODO: add condition for debian and ubuntu set (CPACK_DEBIAN_ELEKTRA-QT-GUI_PACKAGE_DEPENDS "qml-module-qtquick2, qml-module-qtquick-window2, qml-module-qtquick-dialogs, qml-module-qt-labs-folderlistmodel, qml-module-qt-labs-settings") set (CPACK_DEBIAN_ELEKTRA-TESTS_PACKAGE_NAME "elektra-tests") - set (CPACK_COMPONENT_ELEKTRA-TESTS_DISPLAY_NAME "") - set (CPACK_COMPONENT_ELEKTRA-TESTS_DESCRIPTION "") + set (CPACK_COMPONENT_ELEKTRA-TESTS_DISPLAY_NAME "elektra-tests") + set (CPACK_COMPONENT_ELEKTRA-TESTS_DESCRIPTION "This package contains the Elektra test suite.") set (CPACK_COMPONENT_ELEKTRA-TESTS_DEPENDS "libelektra4-full" "elektra-bin") set (CPACK_DEBIAN_ELEKTRA-DOC_PACKAGE_NAME "elektra-doc") - set (CPACK_COMPONENT_ELEKTRA-DOC_DISPLAY_NAME "") - set (CPACK_COMPONENT_ELEKTRA-DOC_DESCRIPTION "") + set (CPACK_COMPONENT_ELEKTRA-DOC_DISPLAY_NAME "elektra-doc") + set (CPACK_COMPONENT_ELEKTRA-DOC_DESCRIPTION "This package contains the API documentation for the Elektra libraries.") set (CPACK_DEBIAN_LIBELEKTRA4-ALL_PACKAGE_NAME "libelektra4-all") - set (CPACK_COMPONENT_LIBELEKTRA4-ALL_DISPLAY_NAME "") - set (CPACK_COMPONENT_LIBELEKTRA4-ALL_DESCRIPTION "") + set (CPACK_COMPONENT_LIBELEKTRA4-ALL_DISPLAY_NAME "libelektra4-all") + set (CPACK_COMPONENT_LIBELEKTRA4-ALL_DESCRIPTION "This package contains extra command line utilities for Elektra written in non-shell languages like python.") set (CPACK_COMPONENT_LIBELEKTRA4-ALL_DEPENDS "libelektra4" "libelektra4-experimental" "libelektra4-augeas" "libelektra4-dbus" "libelektra4-zeromq" "libelektra4-lua" "libelektra4-python" "libelektra4-xmltool" "libelektra4-xerces" "libelektra4-yajl" "lua-elektra" "elektra-bin" "elektra-qt-gui" "libelektra4-crypto" "libelektra4-curl" "libelektra4-journald" "libelektra4-extra") # build debug package for each component From 74186bf43575a98008a92315a7c411443bf8f1f3 Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Sun, 6 Dec 2020 22:57:53 +0100 Subject: [PATCH 03/32] cpack: add missing debian package properties --- scripts/cmake/ElektraPackaging.cmake | 83 +++++++++++++++++++++++++--- 1 file changed, 74 insertions(+), 9 deletions(-) diff --git a/scripts/cmake/ElektraPackaging.cmake b/scripts/cmake/ElektraPackaging.cmake index d50200c97e9..524599a047e 100644 --- a/scripts/cmake/ElektraPackaging.cmake +++ b/scripts/cmake/ElektraPackaging.cmake @@ -34,6 +34,10 @@ set ( elektra-qt-gui elektra-tests) +set (ALL_PLUGINS ${CPACK_COMPONENTS_ALL}) +list(FILTER ALL_PLUGINS INCLUDE REGEX "^libelektra4-.*") +string (REPLACE ";" ", " ALL_PLUGINS_STR "${ALL_PLUGINS}") + set (CMAKE_BUILD_WITH_INSTALL_RPATH 1) list(APPEND CMAKE_INSTALL_RPATH "${CMAKE_CURRENT_BINARY_DIR}") @@ -92,7 +96,8 @@ if (UNIX) if ("${LSB_DISTRIB}" MATCHES "Ubuntu|Debian") set (CPACK_GENERATOR "DEB") set (CPACK_DEBIAN_PACKAGE_PRIORITY "optional") - set (CPACK_DEBIAN_PACKAGE_SECTION "libs") + set (CPACK_DEBIAN_PACKAGE_SOURCE "elektra") + # set (CPACK_DEBIAN_PACKAGE_SECTION "libs") set (CPACK_DEBIAN_PACKAGE_RECOMMENDS "") set (CPACK_DEBIAN_PACKAGE_DEPENDS "") # no dependencies without any PLUGINS @@ -106,6 +111,10 @@ if (UNIX) set ( CPACK_COMPONENT_LIBELEKTRA4_DESCRIPTION "This package contains the main elektra library, and most of the core plugins") + set (CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_SECTION "libs") + set (CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_BREAKS "elektra-bin (<< 0.8.14-5~), libelektra-core4 (<< 0.8.19-1), libelektra-full4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_REPLACES "elektra-bin (<< 0.8.14-5~), libelelektra-core4 (<< 0.8.19-1), libelektra-full4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_SUGGESTS "elektra-doc, ${ALL_PLUGINS_STR}") set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_NAME "libelektra4-full") set (CPACK_COMPONENT_LIBELEKTRA4-FULL_DISPLAY_NAME "libelektra4-full") @@ -113,90 +122,133 @@ if (UNIX) CPACK_COMPONENT_LIBELEKTRA4-FULL_DESCRIPTION "This package contains an variant of the Elektra library in which all plugins are linked together to a full library. The package is only needed for testing.") + set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_SECTION "libs") + set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_BREAKS "elektra-bin (<< 0.8.14-5~), libelektra-core4 (<< 0.8.19-1), libelektra-full4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_REPLACES "elektra-bin (<< 0.8.14-5~), libelelektra-core4 (<< 0.8.19-1), libelektra-full4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_CONFLICTS "libelektra4 (<< ${CPACK_DEBIAN_PACKAGE_VERSION}), elektra-tests (<< ${CPACK_DEBIAN_PACKAGE_VERSION})") + set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_SUGGESTS "elektra-doc, ${ALL_PLUGINS_STR}") set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_PACKAGE_NAME "libelektra4-experimental") set (CPACK_COMPONENT_LIBELEKTRA4-EXPERIMENTAL_DISPLAY_NAME "libelektra4-experimental") set (CPACK_COMPONENT_LIBELEKTRA4-EXPERIMENTAL_DESCRIPTION "This package contains experimental plugins.") + set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_PACKAGE_SECTION "libs") + set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_PACKAGE_BREAKS "elektra-bin (<< 0.8.14-5~), libelektra-core4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_PACKAGE_REPLACES "elektra-bin (<< 0.8.14-5~), libelelektra-core4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_PACKAGE_SUGGESTS "elektra-doc, ${ALL_PLUGINS_STR}") set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_PACKAGE_NAME "libelektra4-extra") set (CPACK_COMPONENT_LIBELEKTRA4-EXTRA_DISPLAY_NAME "libelektra4-extra") set (CPACK_COMPONENT_LIBELEKTRA4-EXTRA_DESCRIPTION "This package contains extra plugins.") + set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_PACKAGE_SECTION "libs") + set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_PACKAGE_BREAKS "elektra-bin (<< 0.8.14-5~), libelektra-core4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_PACKAGE_REPLACES "elektra-bin (<< 0.8.14-5~), libelelektra-core4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_PACKAGE_SUGGESTS "elektra-doc, ${ALL_PLUGINS_STR}") set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_NAME "elektra-bin") set (CPACK_COMPONENT_ELEKTRA-BIN_DISPLAY_NAME "elektra-bin") set (CPACK_COMPONENT_ELEKTRA-BIN_DESCRIPTION "This package contains command line utilities for Elektra.") set (CPACK_COMPONENT_ELEKTRA-BIN_DEPENDS "libelektra4") + set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_SECTION "misc") + set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_BREAKS "elektra-bin (<< 0.8.14-5~),libelektra-full4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_REPLACES "elektra-bin (<< 0.8.14-5~), libelektra-full4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_CONFLICTS "kernel-patch-kdb") set (CPACK_DEBIAN_LIBELEKTRA4-AUGEAS_PACKAGE_NAME "libelektra4-augeas") set (CPACK_COMPONENT_LIBELEKTRA4-AUGEAS_DISPLAY_NAME "libelektra4-augeas") set (CPACK_COMPONENT_LIBELEKTRA4-AUGEAS_DESCRIPTION "This package contains the 'augeas' plugin.") set (CPACK_COMPONENT_LIBELEKTRA4-AUGEAS_DEPENDS "libelektra4") + set (CPACK_DEBIAN_LIBELEKTRA4-AUGEAS_PACKAGE_SECTION "libs") + set (CPACK_DEBIAN_LIBELEKTRA4-AUGEAS_PACKAGE_BREAKS "libelektra-augeas4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-AUGEAS_PACKAGE_REPLACES "libelektra-augeas4 (<< 0.8.19-1)") set (CPACK_DEBIAN_LIBELEKTRA4-DBUS_PACKAGE_NAME "libelektra4-dbus") set (CPACK_COMPONENT_LIBELEKTRA4-DBUS_DISPLAY_NAME "libelektra4-dbus") set (CPACK_COMPONENT_LIBELEKTRA4-DBUS_DESCRIPTION "This package contains the 'dbus' plugins.") set (CPACK_COMPONENT_LIBELEKTRA4-DBUS_DEPENDS "libelektra4") + set (CPACK_DEBIAN_LIBELEKTRA4-DBUS_PACKAGE_SECTION "libs") + set (CPACK_DEBIAN_LIBELEKTRA4-DBUS_PACKAGE_BREAKS "libelektra-dbus4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-DBUS_PACKAGE_REPLACES "libelektra-dbus4 (<< 0.8.19-1)") set (CPACK_DEBIAN_LIBELEKTRA-DEV_PACKAGE_NAME "libelektra-dev") set (CPACK_COMPONENT_LIBELEKTRA-DEV_DISPLAY_NAME "libelektra-dev") set (CPACK_COMPONENT_LIBELEKTRA-DEV_DESCRIPTION "This package contains the development files for the main Elektra library.") - set (CPACK_COMPONENT_LIBELEKTRA4-DBUS_DEPENDS "libelektra4") + set (CPACK_COMPONENT_LIBELEKTRA4-DEV_DEPENDS "libelektra4") + set (CPACK_DEBIAN_LIBELEKTRA4-DEV_PACKAGE_SECTION "libdevel") set (CPACK_DEBIAN_LIBELEKTRA4-ZEROMQ_PACKAGE_NAME "libelektra4-zeromq") set (CPACK_COMPONENT_LIBELEKTRA4-ZEROMQ_DISPLAY_NAME "libelektra4-zeromq") set (CPACK_COMPONENT_LIBELEKTRA4-ZEROMQ_DESCRIPTION "This package contains the 'zeromq' plugins.") set (CPACK_COMPONENT_LIBELEKTRA4-ZEROMQ_DEPENDS "libelektra4") + set (CPACK_DEBIAN_LIBELEKTRA4-ZEROMQ_PACKAGE_SECTION "libs") set (CPACK_DEBIAN_LIBELEKTRA4-XMLTOOL_PACKAGE_NAME "libelektra4-xmltool") set (CPACK_COMPONENT_LIBELEKTRA4-XMLTOOL_DISPLAY_NAME "libelektra4-xmltool") set (CPACK_COMPONENT_LIBELEKTRA4-XMLTOOL_DESCRIPTION "This package contains the 'xmltool' plugin.") set (CPACK_COMPONENT_LIBELEKTRA4-XMLTOOL_DEPENDS "libelektra4") + set (CPACK_DEBIAN_LIBELEKTRA4-XMLTOOL_PACKAGE_SECTION "libs") + set (CPACK_DEBIAN_LIBELEKTRA4-XMLTOOL_PACKAGE_BREAKS "libelektra-xmltool4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-XMLTOOL_PACKAGE_REPLACES "libelektra-xmltool4 (<< 0.8.19-1)") set (CPACK_DEBIAN_LIBELEKTRA4-XERCES_PACKAGE_NAME "libelektra4-xerces") set (CPACK_COMPONENT_LIBELEKTRA4-XERCES_DISPLAY_NAME "libelektra4-xerces") set (CPACK_COMPONENT_LIBELEKTRA4-XERCES_DESCRIPTION "This package contains the 'xerces' plugin.") set (CPACK_COMPONENT_LIBELEKTRA4-XERCES_DEPENDS "libelektra4") + set (CPACK_DEBIAN_LIBELEKTRA4-XERCES_PACKAGE_SECTION "libs") + set (CPACK_DEBIAN_LIBELEKTRA4-XERCES_PACKAGE_BREAKS "libelektra-xerces4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-XERCES_PACKAGE_REPLACES "libelektra-xerces4 (<< 0.8.19-1)") set (CPACK_DEBIAN_LIBELEKTRA4-YAJL_PACKAGE_NAME "libelektra4-yajl") set (CPACK_COMPONENT_LIBELEKTRA4-YAJL_DISPLAY_NAME "libelektra4-yajl") set (CPACK_COMPONENT_LIBELEKTRA4-YAJL_DESCRIPTION "This package contains the 'yajl' plugin.") set (CPACK_COMPONENT_LIBELEKTRA4-YAJL_DEPENDS "libelektra4") + set (CPACK_DEBIAN_LIBELEKTRA4-YAJL_PACKAGE_SECTION "libs") + set (CPACK_DEBIAN_LIBELEKTRA4-YAJL_PACKAGE_BREAKS "libelektra-yajl4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-YAJL_PACKAGE_REPLACES "libelektra-yajl4 (<< 0.8.19-1)") set (CPACK_DEBIAN_LIBELEKTRA4-CRYPTO_PACKAGE_NAME "libelektra4-crypto") set (CPACK_COMPONENT_LIBELEKTRA4-CRYPTO_DISPLAY_NAME "libelektra4-crypto") set (CPACK_COMPONENT_LIBELEKTRA4-CRYPTO_DESCRIPTION "This package contains the crypto plugins.") set (CPACK_COMPONENT_LIBELEKTRA4-CRYPTO_DEPENDS "libelektra4") + set (CPACK_DEBIAN_LIBELEKTRA4-CRYPTO_PACKAGE_SECTION "libs") set (CPACK_DEBIAN_LIBELEKTRA4-CURL_PACKAGE_NAME "libelektra4-curl") set (CPACK_COMPONENT_LIBELEKTRA4-CURL_DISPLAY_NAME "libelektra4-curl") set (CPACK_COMPONENT_LIBELEKTRA4-CURL_DESCRIPTION "This package contains the 'curlget' plugin.") set (CPACK_COMPONENT_LIBELEKTRA4-CURL_DEPENDS "libelektra4") + set (CPACK_DEBIAN_LIBELEKTRA4-CURL_PACKAGE_SECTION "libs") set (CPACK_DEBIAN_LIBELEKTRA4-JOURNALD_PACKAGE_NAME "libelektra4-journald") set (CPACK_COMPONENT_LIBELEKTRA4-JOURNALD_DISPLAY_NAME "libelektra4-journald") set (CPACK_COMPONENT_LIBELEKTRA4-JOURNALD_DESCRIPTION "This package contains the 'journald' plugins.") set (CPACK_COMPONENT_LIBELEKTRA4-JOURNALD_DEPENDS "libelektra4") + set (CPACK_DEBIAN_LIBELEKTRA4-JOURNALD_PACKAGE_SECTION "libs") set (CPACK_DEBIAN_LIBELEKTRA4-LUA_PACKAGE_NAME "libelektra4-lua") set (CPACK_COMPONENT_LIBELEKTRA4-LUA_DISPLAY_NAME "libelektra4-lua") set (CPACK_COMPONENT_LIBELEKTRA4-LUA_DESCRIPTION "This package contains the 'lua' plugin.") set (CPACK_COMPONENT_LIBELEKTRA4-LUA_DEPENDS "libelektra4") + set (CPACK_DEBIAN_LIBELEKTRA4-LUA_PACKAGE_SECTION "libs") set (CPACK_DEBIAN_LUA-ELEKTRA_PACKAGE_NAME "lua-elektra") set (CPACK_COMPONENT_LUA-ELEKTRA_DISPLAY_NAME "lua-elektra") set (CPACK_COMPONENT_LUA-ELEKTRA_DESCRIPTION "This package contains the Lua bindings.") set (CPACK_COMPONENT_LUA-ELEKTRA_DEPENDS "libelektra4") + set (CPACK_DEBIAN_LUA-ELEKTRA_PACKAGE_SECTION "interpreters") # maybe add python3:depends? (see control file) set (CPACK_DEBIAN_PYTHON3-ELEKTRA_PACKAGE_NAME "python3-elektra") set (CPACK_COMPONENT_PYTHON3-ELEKTRA_DISPLAY_NAME "python3-elektra") set (CPACK_COMPONENT_PYTHON3-ELEKTRA_DESCRIPTION "This package contains the Python 3 bindings.") set (CPACK_COMPONENT_PYTHON3-ELEKTRA_DEPENDS "libelektra4") + set (CPACK_DEBIAN_PYTHON3-ELEKTRA_PACKAGE_SECTION "python") set (CPACK_DEBIAN_LIBELEKTRA4-PYTHON_PACKAGE_NAME "libelektra4-python") set (CPACK_COMPONENT_LIBELEKTRA4-PYTHON_DISPLAY_NAME "libelektra4-python") set (CPACK_COMPONENT_LIBELEKTRA4-PYTHON_DESCRIPTION "This package contains the 'python' plugin.") set (CPACK_COMPONENT_LIBELEKTRA4-PYTHON_DEPENDS "libelektra4" "python3-elektra") + set (CPACK_DEBIAN_LIBELEKTRA4-PYTHON_PACKAGE_SECTION "libs") + set (CPACK_DEBIAN_LIBELEKTRA4-PYTHON_PACKAGE_BREAKS "libelelektra-python4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-PYTHON_PACKAGE_REPLACES "libelelektra-python4 (<< 0.8.19-1)") set (CPACK_DEBIAN_ELEKTRA-BIN-EXTRA_PACKAGE_NAME "elektra-bin-extra") set (CPACK_COMPONENT_ELEKTRA-BIN-EXTRA_DISPLAY_NAME "elektra-bin-extra") @@ -205,27 +257,45 @@ if (UNIX) "This package contains extra command line utilities for Elektra written in non-shell languages like python.") set (CPACK_COMPONENT_ELEKTRA-BIN-EXTRA_DEPENDS "libelektra4") set (CPACK_DEBIAN_ELEKTRA-BIN-EXTRA_PACKAGE_DEPENDS "python-all") + set (CPACK_DEBIAN_ELEKTRA-BIN-EXTRA_PACKAGE_SECTION "misc") + set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_PACKAGE_CONFLICTS "elektra-bin (<< ${CPACK_DEBIAN_PACKAGE_VERSION})") set (CPACK_DEBIAN_ELEKTRA-QT-GUI_PACKAGE_NAME "elektra-qt-gui") set (CPACK_COMPONENT_ELEKTRA-QT-GUI_DISPLAY_NAME "elektra-qt-gui") set (CPACK_COMPONENT_ELEKTRA-QT-GUI_DESCRIPTION "This package contains a Qt-based graphical interface for Elektra.") set (CPACK_COMPONENT_ELEKTRA-QT-GUI_DEPENDS "libelektra4") - # TODO: add condition for debian and ubuntu - set (CPACK_DEBIAN_ELEKTRA-QT-GUI_PACKAGE_DEPENDS "qml-module-qtquick2, qml-module-qtquick-window2, qml-module-qtquick-dialogs, qml-module-qt-labs-folderlistmodel, qml-module-qt-labs-settings") + if ("${LSB_DISTRIB}" MATCHES "Ubuntu20.04") + # qml-module-qtquick-controls-styles-breeze not available on ubuntu focal + set (CPACK_DEBIAN_ELEKTRA-QT-GUI_PACKAGE_DEPENDS "qml-module-qtquick2, qml-module-qtquick-window2, qml-module-qtquick-dialogs, qml-module-qt-labs-folderlistmodel, qml-module-qt-labs-settings") + else() + set (CPACK_DEBIAN_ELEKTRA-QT-GUI_PACKAGE_DEPENDS "qml-module-qtquick2, qml-module-qtquick-window2, qml-module-qtquick-dialogs, qml-module-qt-labs-folderlistmodel, qml-module-qt-labs-settings, qml-module-qtquick-controls-styles-breeze") + endif() + set (CPACK_DEBIAN_ELEKTRA-QT-GUI_PACKAGE_SECTION "misc") set (CPACK_DEBIAN_ELEKTRA-TESTS_PACKAGE_NAME "elektra-tests") set (CPACK_COMPONENT_ELEKTRA-TESTS_DISPLAY_NAME "elektra-tests") set (CPACK_COMPONENT_ELEKTRA-TESTS_DESCRIPTION "This package contains the Elektra test suite.") set (CPACK_COMPONENT_ELEKTRA-TESTS_DEPENDS "libelektra4-full" "elektra-bin") + set (CPACK_DEBIAN_ELEKTRA-TESTS_PACKAGE_SECTION "misc") + set (CPACK_DEBIAN_ELEKTRA-TESTS_PACKAGE_PRIORITY "extra") + set (CPACK_DEBIAN_ELEKTRA-TESTS_PACKAGE_BREAKS "libelektra-test (<< 0.8.19-1), libelektra-full4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_ELEKTRA-TESTS_PACKAGE_REPLACES "libelektra-test (<< 0.8.19-1), libelektra-full4 (<< 0.8.19-1)") set (CPACK_DEBIAN_ELEKTRA-DOC_PACKAGE_NAME "elektra-doc") set (CPACK_COMPONENT_ELEKTRA-DOC_DISPLAY_NAME "elektra-doc") set (CPACK_COMPONENT_ELEKTRA-DOC_DESCRIPTION "This package contains the API documentation for the Elektra libraries.") + set (CPACK_DEBIAN_ELEKTRA-DOC_PACKAGE_ARCHITECTURE "all") + set (CPACK_DEBIAN_ELEKTRA-DOC_PACKAGE_SECTION "doc") + set (CPACK_DEBIAN_ELEKTRA-DOC_PACKAGE_BREAKS "libelektra-doc (<< 0.8.19-1)") + set (CPACK_DEBIAN_ELEKTRA-DOC_PACKAGE_REPLACES "libelektra-doc (<< 0.8.19-1)") set (CPACK_DEBIAN_LIBELEKTRA4-ALL_PACKAGE_NAME "libelektra4-all") set (CPACK_COMPONENT_LIBELEKTRA4-ALL_DISPLAY_NAME "libelektra4-all") set (CPACK_COMPONENT_LIBELEKTRA4-ALL_DESCRIPTION "This package contains extra command line utilities for Elektra written in non-shell languages like python.") set (CPACK_COMPONENT_LIBELEKTRA4-ALL_DEPENDS "libelektra4" "libelektra4-experimental" "libelektra4-augeas" "libelektra4-dbus" "libelektra4-zeromq" "libelektra4-lua" "libelektra4-python" "libelektra4-xmltool" "libelektra4-xerces" "libelektra4-yajl" "lua-elektra" "elektra-bin" "elektra-qt-gui" "libelektra4-crypto" "libelektra4-curl" "libelektra4-journald" "libelektra4-extra") + set (CPACK_DEBIAN_LIBELEKTRA4-ALL_PACKAGE_SECTION "misc") + set (CPACK_DEBIAN_LIBELEKTRA4-ALL_PACKAGE_DEPENDS "libelektra4, libelektra4-experimental, libelektra4-augeas, libelektra4-dbus, libelektra4-zeromq, libelektra4-lua, libelektra4-python, libelektra4-xmltool, libelektra4-xerces, libelektra4-yajl, lua-elektra, elektra-bin, elektra-qt-gui, libelektra4-crypto, libelektra4-curl, libelektra4-journald, libelektra4-extra") + set (CPACK_DEBIAN_LIBELEKTRA4-ALL_PACKAGE_RECOMMENDS "elektra-tests, elektra-doc, libelektra-dev") # add all .ddeb packages? # build debug package for each component set (CPACK_DEBIAN_DEBUGINFO_PACKAGE "ON") @@ -233,11 +303,6 @@ if (UNIX) set (CPACK_DEBIAN_PACKAGE_SHLIBDEPS "ON") set (CPACK_DEBIAN_PACKAGE_GENERATE_SHLIBS "ON") - - - #set (CPACK_DEBIAN_PACKAGE_GENERATE_SHLIBS_POLICY ">=") # Defaults to "=" - #set (CPACK_DEBIAN_PACKAGE_GENERATE_SHLIBS "ON") - # We need to alter the architecture names as per distro rules if ("${CPACK_PACKAGE_ARCHITECTURE}" MATCHES "i[3-6]86") set (CPACK_PACKAGE_ARCHITECTURE i386) From ff1ad5f677fb8459b44c84384e9a79946437f420 Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Sun, 6 Dec 2020 23:49:14 +0100 Subject: [PATCH 04/32] package: add hardening flags, fix install location --- scripts/release/package.sh | 34 +++++++++++++++++++--------------- 1 file changed, 19 insertions(+), 15 deletions(-) diff --git a/scripts/release/package.sh b/scripts/release/package.sh index e79a404f9a1..bbb522eeba9 100644 --- a/scripts/release/package.sh +++ b/scripts/release/package.sh @@ -4,22 +4,25 @@ ELEKTRA_PLUGINS='ALL;mozprefs;multifile;-gitresolver;-jni;-ruby;-haskell;-yamlcp ELEKTRA_TOOLS='ALL' ELEKTRA_BINDINGS='cpp;lua;python;INTERCEPT' -# #workaround for hardening flags -# CPPFLAGS=$(dpkg-buildflags --get CPPFLAGS) -# CFLAGS=$(dpkg-buildflags --get CFLAGS $CPPFLAGS) -# CXXFLAGS=$(dpkg-buildflags --get CXXFLAGS) $(CPPFLAGS) -# LDFLAGS=$(dpkg-buildflags --get LDFLAGS) +# workaround for hardening flags +CPPFLAGS=$(dpkg-buildflags --get CPPFLAGS) +CFLAGS=$(dpkg-buildflags --get CFLAGS) +CXXFLAGS=$(dpkg-buildflags --get CXXFLAGS) +LDFLAGS=$(dpkg-buildflags --get LDFLAGS) PY3VER=$(py3versions -d -v) -#DEB_HOST_MULTIARCH=$(dpkg-architecture -qDEB_HOST_MULTIARCH) CMAKE_ARGS="-DTARGET_PLUGIN_FOLDER='elektra4' \ -DBUILD_STATIC=OFF \ -DPython_ADDITIONAL_VERSIONS=$PY3VER \ -DGTEST_ROOT='/usr/src/gtest' \ + -DCMAKE_INSTALL_PREFIX=/usr \ -DPLUGINS=$ELEKTRA_PLUGINS \ -DTOOLS=$ELEKTRA_TOOLS \ -DBINDINGS=$ELEKTRA_BINDINGS \ + -DKDB_DB_SYSTEM:PATH=/etc/kdb \ + -DKDB_DB_HOME:PATH=/home \ + -DKDB_DB_USER:PATH=.config \ -DINSTALL_DOCUMENTATION=ON \ -DSWIG_EXECUTABLE=/usr/bin/swig3.0 \ -DPYTHON_EXECUTABLE:PATH=/usr/bin/python3 \ @@ -28,14 +31,15 @@ CMAKE_ARGS="-DTARGET_PLUGIN_FOLDER='elektra4' \ -DENABLE_KDB_TESTING=OFF \ -DINSTALL_SYSTEM_FILES=ON \ -DBUILD_PDF=OFF \ - -DBUILD_FULL=ON" - - # \ - #-DTARGET_TEST_DATA_FOLDER=share/libelektra-test/test-data" + -DBUILD_FULL=ON \ + -DTARGET_DOCUMENTATION_HTML_FOLDER=share/doc/libelektra-doc/html \ + -DTARGET_TEST_DATA_FOLDER=share/libelektra-test/test-data \ + -DCMAKE_C_FLAGS=$CFLAGS \ + -DCMAKE_CXX_FLAGS=$CXXFLAGS \ + -DCMAKE_EXE_LINKER_FLAGS=$LDFLAGS \ + -DCMAKE_MODULE_LINKER_FLAGS=$LDFLAGS \ + -DCMAKE_SHARED_LINKER_FLAGS=$LDFLAGS" -# DEBUG pls remove -cpu_count=`nproc --all` -export MAKEFLAGS="-j$(($cpu_count+2)) -l$(($cpu_count*2))" -# end debug cmake $CMAKE_ARGS .. -LD_LIBRARY_PATH=/home/libelektra/build/lib:${LD_LIBRARY_PATH} make package +# TODO: change to relative path ./lib:.... instead of full path +LD_LIBRARY_PATH=$(pwd)/lib:${LD_LIBRARY_PATH} make package From b09f918487da5f13ceaf09f955443e365963ab18 Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Tue, 8 Dec 2020 00:58:28 +0100 Subject: [PATCH 05/32] cpack: fix libraries in wrong packages --- src/bindings/intercept/env/examples/CMakeLists.txt | 2 +- src/libs/merge/CMakeLists.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/bindings/intercept/env/examples/CMakeLists.txt b/src/bindings/intercept/env/examples/CMakeLists.txt index 8243df0a69d..4821dcc6212 100644 --- a/src/bindings/intercept/env/examples/CMakeLists.txt +++ b/src/bindings/intercept/env/examples/CMakeLists.txt @@ -9,7 +9,7 @@ macro (do_example source) set (SOURCES ${HDR_FILES} ${source}.c) add_executable (${source} ${SOURCES}) - install (TARGETS ${source} DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT libelektra4) + install (TARGETS ${source} DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin) set_target_properties (${source} PROPERTIES COMPILE_DEFINITIONS HAVE_KDBCONFIG_H) endmacro (do_example) diff --git a/src/libs/merge/CMakeLists.txt b/src/libs/merge/CMakeLists.txt index 2cf5ea46a66..1cc1259b627 100644 --- a/src/libs/merge/CMakeLists.txt +++ b/src/libs/merge/CMakeLists.txt @@ -31,4 +31,4 @@ set (LIBRARY_NAME elektra-merge) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/${LIBRARY_NAME}.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/${LIBRARY_NAME}.pc" @ONLY) -install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${LIBRARY_NAME}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} COMPONENT libelektra4) +install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${LIBRARY_NAME}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER}) From c3159ccff6692d0634d8dceb982c9e7155e3f5be Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Tue, 8 Dec 2020 02:00:35 +0100 Subject: [PATCH 06/32] cpack: add debian control files --- scripts/cmake/ElektraCache.cmake | 5 +++++ scripts/cmake/ElektraPackaging.cmake | 19 ++++++++++++++++--- .../debian-control/elektra-bin/postinst | 4 ++++ .../debian-control/elektra-bin/postrm | 4 ++++ .../debian-control/elektra-bin/preinst | 4 ++++ .../debian-control/elektra-bin/prerm | 4 ++++ .../debian-control/elektra-bin/triggers | 1 + .../debian-control/python3-elektra/postinst | 9 +++++++++ .../debian-control/python3-elektra/prerm | 9 +++++++++ scripts/packaging/doc-base/elektra-doc | 8 ++++++++ 10 files changed, 64 insertions(+), 3 deletions(-) create mode 100644 scripts/packaging/debian-control/elektra-bin/postinst create mode 100644 scripts/packaging/debian-control/elektra-bin/postrm create mode 100644 scripts/packaging/debian-control/elektra-bin/preinst create mode 100644 scripts/packaging/debian-control/elektra-bin/prerm create mode 100644 scripts/packaging/debian-control/elektra-bin/triggers create mode 100644 scripts/packaging/debian-control/python3-elektra/postinst create mode 100644 scripts/packaging/debian-control/python3-elektra/prerm create mode 100644 scripts/packaging/doc-base/elektra-doc diff --git a/scripts/cmake/ElektraCache.cmake b/scripts/cmake/ElektraCache.cmake index 2d2a47f6f7d..4a1668d6b74 100644 --- a/scripts/cmake/ElektraCache.cmake +++ b/scripts/cmake/ElektraCache.cmake @@ -306,6 +306,11 @@ set ( "share/doc/elektra-api/latex" CACHE STRING "The folder (below prefix) where to install latex api documentation files.") +set ( + TARGET_DOCUMENTATION_DOC-BASE_FOLDER + "share/doc-base/" + CACHE STRING "The folder (below prefix) where to install doc-base documentation files for debian packaging.") + set ( TARGET_TOOL_EXEC_FOLDER "lib${LIB_SUFFIX}/elektra/tool_exec" diff --git a/scripts/cmake/ElektraPackaging.cmake b/scripts/cmake/ElektraPackaging.cmake index 524599a047e..07520be539f 100644 --- a/scripts/cmake/ElektraPackaging.cmake +++ b/scripts/cmake/ElektraPackaging.cmake @@ -6,6 +6,8 @@ set (PACKAGE_BUGREPORT "https://bugs.libelektra.org/") set (PROJECT_VERSION "${KDB_VERSION}") set (CPACK_PACKAGE_VERSION "${PROJECT_VERSION}") set (CPACK_DEBIAN_PACKAGE_VERSION "${PROJECT_VERSION}") +set (CPACK_DEBIAN_PACKAGE_RELEASE "1") +set (CPACK_DEBIAN_FILE_NAME DEB-DEFAULT) set ( CPACK_COMPONENTS_ALL @@ -44,7 +46,7 @@ list(APPEND CMAKE_INSTALL_RPATH "${CMAKE_CURRENT_BINARY_DIR}") set ( PACKAGE_DESCRIPTION - "Elektra provides a universal and secure framework to store configuration parameters in a global, hierarchical key database. The core is a small library implemented in C. The plugin-based framework fulfills many configuration-related tasks to avoid any unnecessary code duplication across applications while it still allows the core to stay without any external dependency. Elektra abstracts from cross-platform-related issues with an consistent API, and allows applications to be aware of other applications' configurations, leveraging easy application integration." + "Elektra provides a universal and secure framework to store configuration parameters in a global, hierarchical key database. The core is a small library implemented in C. The plugin-based framework fulfills many configuration-related tasks to avoid any unnecessary code duplication across applications while it still allows the core to stay without any external dependency. Elektra abstracts from cross-platform-related issues with an consistent API, and allows applications to be aware of other applications' configurations, leveraging easy application integration.\n." ) set (CPACK_PACKAGE_DESCRIPTION_SUMMARY "${PACKAGE_DESCRIPTION}") set (CPACK_PACKAGE_CONTACT "${PACKAGE_URL}") @@ -152,6 +154,11 @@ if (UNIX) set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_BREAKS "elektra-bin (<< 0.8.14-5~),libelektra-full4 (<< 0.8.19-1)") set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_REPLACES "elektra-bin (<< 0.8.14-5~), libelektra-full4 (<< 0.8.19-1)") set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_CONFLICTS "kernel-patch-kdb") + set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_CONTROL_STRICT_PERMISSION TRUE) + file (GLOB CONTROL_FILES_ELEKTRA-BIN "${CMAKE_SOURCE_DIR}/scripts/packaging/debian-control/elektra-bin/*") + file (COPY ${CONTROL_FILES_ELEKTRA-BIN} DESTINATION "${CMAKE_BINARY_DIR}/scripts/packaging/debian-control/elektra-bin/") + file (GLOB CONTROL_FILES_ELEKTRA-BIN_BINARY "${CMAKE_BINARY_DIR}/scripts/packaging/debian-control/elektra-bin/*") + set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_CONTROL_EXTRA "${CONTROL_FILES_ELEKTRA-BIN_BINARY}") set (CPACK_DEBIAN_LIBELEKTRA4-AUGEAS_PACKAGE_NAME "libelektra4-augeas") set (CPACK_COMPONENT_LIBELEKTRA4-AUGEAS_DISPLAY_NAME "libelektra4-augeas") @@ -241,6 +248,11 @@ if (UNIX) set (CPACK_COMPONENT_PYTHON3-ELEKTRA_DESCRIPTION "This package contains the Python 3 bindings.") set (CPACK_COMPONENT_PYTHON3-ELEKTRA_DEPENDS "libelektra4") set (CPACK_DEBIAN_PYTHON3-ELEKTRA_PACKAGE_SECTION "python") + set (CPACK_DEBIAN_PYTHON3-ELEKTRA_PACKAGE_CONTROL_STRICT_PERMISSION TRUE) + file (GLOB CONTROL_FILES_PYTHON3-ELEKTRA "${CMAKE_SOURCE_DIR}/scripts/packaging/debian-control/python3-elektra/*") + file (COPY ${CONTROL_FILES_PYTHON3-ELEKTRA} DESTINATION "${CMAKE_BINARY_DIR}/scripts/packaging/debian-control/python3-elektra/") + file (GLOB CONTROL_FILES_PYTHON3-ELEKTRA_BINARY "${CMAKE_BINARY_DIR}/scripts/packaging/debian-control/python3-elektra/*") + set (CPACK_DEBIAN_PYTHON3-ELEKTRA_PACKAGE_CONTROL_EXTRA "${CONTROL_FILES_PYTHON3-ELEKTRA_BINARY}") set (CPACK_DEBIAN_LIBELEKTRA4-PYTHON_PACKAGE_NAME "libelektra4-python") set (CPACK_COMPONENT_LIBELEKTRA4-PYTHON_DISPLAY_NAME "libelektra4-python") @@ -253,12 +265,12 @@ if (UNIX) set (CPACK_DEBIAN_ELEKTRA-BIN-EXTRA_PACKAGE_NAME "elektra-bin-extra") set (CPACK_COMPONENT_ELEKTRA-BIN-EXTRA_DISPLAY_NAME "elektra-bin-extra") set ( - CPACK_COMPONENT_LEKTRA-BIN-EXTRA_DESCRIPTION + CPACK_COMPONENT_ELEKTRA-BIN-EXTRA_DESCRIPTION "This package contains extra command line utilities for Elektra written in non-shell languages like python.") set (CPACK_COMPONENT_ELEKTRA-BIN-EXTRA_DEPENDS "libelektra4") set (CPACK_DEBIAN_ELEKTRA-BIN-EXTRA_PACKAGE_DEPENDS "python-all") set (CPACK_DEBIAN_ELEKTRA-BIN-EXTRA_PACKAGE_SECTION "misc") - set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_PACKAGE_CONFLICTS "elektra-bin (<< ${CPACK_DEBIAN_PACKAGE_VERSION})") + set (CPACK_DEBIAN_ELEKTRA-BIN-EXTRA_PACKAGE_CONFLICTS "elektra-bin (<< ${CPACK_DEBIAN_PACKAGE_VERSION})") set (CPACK_DEBIAN_ELEKTRA-QT-GUI_PACKAGE_NAME "elektra-qt-gui") set (CPACK_COMPONENT_ELEKTRA-QT-GUI_DISPLAY_NAME "elektra-qt-gui") @@ -288,6 +300,7 @@ if (UNIX) set (CPACK_DEBIAN_ELEKTRA-DOC_PACKAGE_SECTION "doc") set (CPACK_DEBIAN_ELEKTRA-DOC_PACKAGE_BREAKS "libelektra-doc (<< 0.8.19-1)") set (CPACK_DEBIAN_ELEKTRA-DOC_PACKAGE_REPLACES "libelektra-doc (<< 0.8.19-1)") + install (FILES "${CMAKE_SOURCE_DIR}/scripts/packaging/doc-base/elektra-doc" COMPONENT elektra-doc DESTINATION ${TARGET_DOCUMENTATION_DOC-BASE_FOLDER}) set (CPACK_DEBIAN_LIBELEKTRA4-ALL_PACKAGE_NAME "libelektra4-all") set (CPACK_COMPONENT_LIBELEKTRA4-ALL_DISPLAY_NAME "libelektra4-all") diff --git a/scripts/packaging/debian-control/elektra-bin/postinst b/scripts/packaging/debian-control/elektra-bin/postinst new file mode 100644 index 00000000000..b230b05ea05 --- /dev/null +++ b/scripts/packaging/debian-control/elektra-bin/postinst @@ -0,0 +1,4 @@ +#!/bin/sh +set -e + +dpkg-maintscript-helper rm_conffile /etc/bash_completion.d/kdb 0.8.11-1~ -- "$@" \ No newline at end of file diff --git a/scripts/packaging/debian-control/elektra-bin/postrm b/scripts/packaging/debian-control/elektra-bin/postrm new file mode 100644 index 00000000000..b230b05ea05 --- /dev/null +++ b/scripts/packaging/debian-control/elektra-bin/postrm @@ -0,0 +1,4 @@ +#!/bin/sh +set -e + +dpkg-maintscript-helper rm_conffile /etc/bash_completion.d/kdb 0.8.11-1~ -- "$@" \ No newline at end of file diff --git a/scripts/packaging/debian-control/elektra-bin/preinst b/scripts/packaging/debian-control/elektra-bin/preinst new file mode 100644 index 00000000000..b230b05ea05 --- /dev/null +++ b/scripts/packaging/debian-control/elektra-bin/preinst @@ -0,0 +1,4 @@ +#!/bin/sh +set -e + +dpkg-maintscript-helper rm_conffile /etc/bash_completion.d/kdb 0.8.11-1~ -- "$@" \ No newline at end of file diff --git a/scripts/packaging/debian-control/elektra-bin/prerm b/scripts/packaging/debian-control/elektra-bin/prerm new file mode 100644 index 00000000000..55e86b0714e --- /dev/null +++ b/scripts/packaging/debian-control/elektra-bin/prerm @@ -0,0 +1,4 @@ +#!/bin/sh +set -e + +dpkg-maintscript-helper rm_conffile /etc/bash_completion.d/kdb 0.8.11-1~ -- "$@" diff --git a/scripts/packaging/debian-control/elektra-bin/triggers b/scripts/packaging/debian-control/elektra-bin/triggers new file mode 100644 index 00000000000..dd866036784 --- /dev/null +++ b/scripts/packaging/debian-control/elektra-bin/triggers @@ -0,0 +1 @@ +activate-noawait ldconfig diff --git a/scripts/packaging/debian-control/python3-elektra/postinst b/scripts/packaging/debian-control/python3-elektra/postinst new file mode 100644 index 00000000000..cf00e14be93 --- /dev/null +++ b/scripts/packaging/debian-control/python3-elektra/postinst @@ -0,0 +1,9 @@ +#!/bin/sh +set -e + +if which py3compile >/dev/null 2>&1; then + py3compile -p python3-elektra +fi +if which pypy3compile >/dev/null 2>&1; then + pypy3compile -p python3-elektra || true +fi diff --git a/scripts/packaging/debian-control/python3-elektra/prerm b/scripts/packaging/debian-control/python3-elektra/prerm new file mode 100644 index 00000000000..b573bc7542d --- /dev/null +++ b/scripts/packaging/debian-control/python3-elektra/prerm @@ -0,0 +1,9 @@ +#!/bin/sh +set -e + +if which py3clean >/dev/null 2>&1; then + py3clean -p python3-elektra +else + dpkg -L python3-elektra | perl -ne 's,/([^/]*)\.py$,/__pycache__/\1.*, or next; unlink $_ or die $! foreach glob($_)' + find /usr/lib/python3/dist-packages/ -type d -name __pycache__ -empty -print0 | xargs --null --no-run-if-empty rmdir +fi diff --git a/scripts/packaging/doc-base/elektra-doc b/scripts/packaging/doc-base/elektra-doc new file mode 100644 index 00000000000..fa0c22a0fe9 --- /dev/null +++ b/scripts/packaging/doc-base/elektra-doc @@ -0,0 +1,8 @@ +Document: elektra-doc +Title: Elektra Projekt Documentation +Abstract: Documentation on how to use the Elektra API. +Section: Programming/C + +Format: HTML +Index: /usr/share/doc/elektra-doc/html/index.html +Files: /usr/share/doc/elektra-doc/html/*.html From ac17b16ed67e9fe486f6a1483aef2b9786efd486 Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Tue, 8 Dec 2020 02:00:58 +0100 Subject: [PATCH 07/32] cpack: remove rpath --- scripts/cmake/ElektraPackaging.cmake | 4 ---- 1 file changed, 4 deletions(-) diff --git a/scripts/cmake/ElektraPackaging.cmake b/scripts/cmake/ElektraPackaging.cmake index 07520be539f..1815a872842 100644 --- a/scripts/cmake/ElektraPackaging.cmake +++ b/scripts/cmake/ElektraPackaging.cmake @@ -40,10 +40,6 @@ set (ALL_PLUGINS ${CPACK_COMPONENTS_ALL}) list(FILTER ALL_PLUGINS INCLUDE REGEX "^libelektra4-.*") string (REPLACE ";" ", " ALL_PLUGINS_STR "${ALL_PLUGINS}") -set (CMAKE_BUILD_WITH_INSTALL_RPATH 1) - -list(APPEND CMAKE_INSTALL_RPATH "${CMAKE_CURRENT_BINARY_DIR}") - set ( PACKAGE_DESCRIPTION "Elektra provides a universal and secure framework to store configuration parameters in a global, hierarchical key database. The core is a small library implemented in C. The plugin-based framework fulfills many configuration-related tasks to avoid any unnecessary code duplication across applications while it still allows the core to stay without any external dependency. Elektra abstracts from cross-platform-related issues with an consistent API, and allows applications to be aware of other applications' configurations, leveraging easy application integration.\n." From c9fcabb65d7f2bffdc574808e93908c34982dd55 Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Tue, 8 Dec 2020 02:04:42 +0100 Subject: [PATCH 08/32] cmake: remove debug messages --- scripts/cmake/Modules/LibAddPlugin.cmake | 4 ---- scripts/kdb/CMakeLists.txt | 1 - 2 files changed, 5 deletions(-) diff --git a/scripts/cmake/Modules/LibAddPlugin.cmake b/scripts/cmake/Modules/LibAddPlugin.cmake index 2f5bdaef113..372b9765052 100644 --- a/scripts/cmake/Modules/LibAddPlugin.cmake +++ b/scripts/cmake/Modules/LibAddPlugin.cmake @@ -410,8 +410,6 @@ function (add_plugin PLUGIN_SHORT_NAME) set (PLUGIN_OBJS ${PLUGIN_NAME}-objects) set (PLUGIN_TARGET_OBJS "$") - message (STATUS "add_plugin component: ${COMPONENT}") - restore_variable (${PLUGIN_NAME} ARG_LINK_LIBRARIES) restore_variable (${PLUGIN_NAME} ARG_SOURCES) restore_variable (${PLUGIN_NAME} ARG_OBJECT_SOURCES) @@ -428,8 +426,6 @@ function (add_plugin PLUGIN_SHORT_NAME) restore_variable (${PLUGIN_NAME} ARG_ONLY_SHARED) restore_variable (${PLUGIN_NAME} ARG_COMPONENT) - message (STATUS "add_plugin restore_variable: ${ARG_COMPONENT}") - if (ARG_UNPARSED_ARGUMENTS) message (FATAL_ERROR "Parsed a wrong argument to plugin ${PLUGIN_SHORT_NAME}: ${ARG_UNPARSED_ARGUMENTS}") endif () diff --git a/scripts/kdb/CMakeLists.txt b/scripts/kdb/CMakeLists.txt index a32823b9fbc..30798628ebb 100644 --- a/scripts/kdb/CMakeLists.txt +++ b/scripts/kdb/CMakeLists.txt @@ -31,6 +31,5 @@ foreach (file ${ALL_FILES}) else () set(HAS_COMPONENT elektra-bin) endif() - message (STATUS "HAS_COMPONENT: ${HAS_COMPONENT} FILE: ${file}") install (PROGRAMS "${file}" DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT ${HAS_COMPONENT}) endforeach (file ${ALL_FILES}) From e210171c73641435effc8f3eaa6e35e4a6e18fd2 Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Tue, 8 Dec 2020 02:42:16 +0100 Subject: [PATCH 09/32] style: reformat with cmake-format 0.6.3 --- CMakeLists.txt | 5 +- doc/CMakeLists.txt | 45 ++++++-- scripts/CMakeLists.txt | 60 ++++++++-- scripts/admin/CMakeLists.txt | 5 +- scripts/cmake/CMakeLists.txt | 11 +- scripts/cmake/ElektraPackaging.cmake | 107 ++++++++++++------ scripts/cmake/Modules/LibAddMacros.cmake | 5 +- scripts/cmake/Modules/LibAddPlugin.cmake | 22 +++- scripts/cmake/Modules/LibAddTest.cmake | 5 +- scripts/completion/CMakeLists.txt | 10 +- scripts/ffconfig/CMakeLists.txt | 20 +++- scripts/kdb/CMakeLists.txt | 30 +++-- src/bindings/cpp/include/CMakeLists.txt | 5 +- .../intercept/env/examples/CMakeLists.txt | 5 +- .../intercept/env/include/CMakeLists.txt | 5 +- src/bindings/intercept/env/src/CMakeLists.txt | 5 +- src/bindings/intercept/fs/CMakeLists.txt | 5 +- src/include/elektra/CMakeLists.txt | 5 +- src/libs/CMakeLists.txt | 9 +- src/libs/elektra/CMakeLists.txt | 5 +- src/libs/globbing/CMakeLists.txt | 9 +- src/libs/highlevel/CMakeLists.txt | 20 +++- src/libs/invoke/CMakeLists.txt | 9 +- src/libs/io/CMakeLists.txt | 16 ++- src/libs/merge/CMakeLists.txt | 3 +- src/libs/meta/CMakeLists.txt | 9 +- src/libs/notification/CMakeLists.txt | 8 +- src/libs/opts/CMakeLists.txt | 9 +- src/libs/pluginprocess/CMakeLists.txt | 10 +- src/libs/tools/include/CMakeLists.txt | 15 ++- src/libs/tools/src/CMakeLists.txt | 15 ++- src/plugins/CMakeLists.txt | 9 +- src/plugins/augeas/CMakeLists.txt | 3 +- src/plugins/base64/CMakeLists.txt | 3 +- src/plugins/blockresolver/CMakeLists.txt | 3 +- src/plugins/c/CMakeLists.txt | 3 +- src/plugins/cache/CMakeLists.txt | 3 +- src/plugins/ccode/CMakeLists.txt | 3 +- src/plugins/conditionals/CMakeLists.txt | 3 +- src/plugins/constants/CMakeLists.txt | 3 +- src/plugins/crypto/CMakeLists.txt | 3 +- src/plugins/csvstorage/CMakeLists.txt | 3 +- src/plugins/curlget/CMakeLists.txt | 3 +- src/plugins/date/CMakeLists.txt | 3 +- src/plugins/dbus/CMakeLists.txt | 3 +- src/plugins/dbusrecv/CMakeLists.txt | 9 +- src/plugins/directoryvalue/CMakeLists.txt | 3 +- src/plugins/doc/CMakeLists.txt | 3 +- src/plugins/dump/CMakeLists.txt | 3 +- src/plugins/fcrypt/CMakeLists.txt | 3 +- src/plugins/file/CMakeLists.txt | 3 +- src/plugins/filecheck/CMakeLists.txt | 3 +- src/plugins/fstab/CMakeLists.txt | 3 +- src/plugins/glob/CMakeLists.txt | 3 +- src/plugins/gopts/CMakeLists.txt | 3 +- src/plugins/gpgme/CMakeLists.txt | 3 +- src/plugins/hexcode/CMakeLists.txt | 3 +- src/plugins/hexnumber/CMakeLists.txt | 3 +- src/plugins/hosts/CMakeLists.txt | 3 +- src/plugins/iconv/CMakeLists.txt | 3 +- .../internalnotification/CMakeLists.txt | 3 +- src/plugins/ipaddr/CMakeLists.txt | 3 +- src/plugins/iterate/CMakeLists.txt | 3 +- src/plugins/journald/CMakeLists.txt | 3 +- src/plugins/kconfig/CMakeLists.txt | 3 +- src/plugins/keytometa/CMakeLists.txt | 3 +- src/plugins/line/CMakeLists.txt | 3 +- src/plugins/lineendings/CMakeLists.txt | 3 +- src/plugins/list/CMakeLists.txt | 3 +- src/plugins/lua/CMakeLists.txt | 3 +- src/plugins/macaddr/CMakeLists.txt | 3 +- src/plugins/mathcheck/CMakeLists.txt | 3 +- src/plugins/mini/CMakeLists.txt | 3 +- src/plugins/mmapstorage/CMakeLists.txt | 6 +- src/plugins/mozprefs/CMakeLists.txt | 3 +- src/plugins/multifile/CMakeLists.txt | 3 +- src/plugins/network/CMakeLists.txt | 3 +- src/plugins/ni/CMakeLists.txt | 3 +- src/plugins/noresolver/CMakeLists.txt | 3 +- src/plugins/passwd/CMakeLists.txt | 3 +- src/plugins/path/CMakeLists.txt | 3 +- src/plugins/process/CMakeLists.txt | 3 +- src/plugins/profile/CMakeLists.txt | 3 +- src/plugins/python/CMakeLists.txt | 7 +- src/plugins/quickdump/CMakeLists.txt | 3 +- src/plugins/range/CMakeLists.txt | 3 +- src/plugins/reference/CMakeLists.txt | 3 +- src/plugins/rename/CMakeLists.txt | 3 +- src/plugins/resolver/CMakeLists.txt | 14 ++- src/plugins/rgbcolor/CMakeLists.txt | 3 +- src/plugins/shell/CMakeLists.txt | 3 +- src/plugins/simpleini/CMakeLists.txt | 3 +- src/plugins/spec/CMakeLists.txt | 3 +- src/plugins/specload/CMakeLists.txt | 3 +- src/plugins/sync/CMakeLists.txt | 3 +- src/plugins/template/CMakeLists.txt | 3 +- src/plugins/toml/CMakeLists.txt | 3 +- src/plugins/type/CMakeLists.txt | 3 +- src/plugins/uname/CMakeLists.txt | 3 +- src/plugins/unit/CMakeLists.txt | 3 +- src/plugins/validation/CMakeLists.txt | 3 +- src/plugins/wresolver/CMakeLists.txt | 3 +- src/plugins/xerces/CMakeLists.txt | 3 +- src/plugins/xmltool/CMakeLists.txt | 3 +- src/plugins/yajl/CMakeLists.txt | 3 +- src/plugins/yamlsmith/CMakeLists.txt | 3 +- src/plugins/zeromqrecv/CMakeLists.txt | 3 +- src/plugins/zeromqsend/CMakeLists.txt | 3 +- src/tools/kdb/CMakeLists.txt | 15 ++- src/tools/qt-gui/CMakeLists.txt | 20 +++- src/tools/race/CMakeLists.txt | 5 +- tests/CMakeLists.txt | 5 +- tests/shell/CMakeLists.txt | 18 +-- tests/shell/gen/CMakeLists.txt | 5 +- 114 files changed, 522 insertions(+), 299 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index afd087c8bc1..bd03651c402 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -125,4 +125,7 @@ if (BUILD_FULL endif (BUILD_TESTING) endif () -install (FILES LICENSE.md DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} COMPONENT libelektra4) +install ( + FILES LICENSE.md + DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} + COMPONENT libelektra4) diff --git a/doc/CMakeLists.txt b/doc/CMakeLists.txt index dc9046c4d5a..8b1ba63088d 100644 --- a/doc/CMakeLists.txt +++ b/doc/CMakeLists.txt @@ -20,7 +20,10 @@ macro (do_doc target folder file install target_component) add_custom_target (${target} ALL DEPENDS ${folder}/${file}) if (INSTALL_DOCUMENTATION) - install (DIRECTORY ${folder} COMPONENT ${target_component} DESTINATION ${install}) + install ( + DIRECTORY ${folder} + COMPONENT ${target_component} + DESTINATION ${install}) endif (INSTALL_DOCUMENTATION) endmacro (do_doc) @@ -123,12 +126,30 @@ else (DOXYGEN_FOUND) endif (DOXYGEN_FOUND) if (INSTALL_DOCUMENTATION) - install (FILES BIGPICTURE.md DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} COMPONENT libelektra4) - install (FILES GOALS.md DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} COMPONENT libelektra4) - install (FILES METADATA.ini DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} COMPONENT libelektra4) - install (FILES SECURITY.md DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} COMPONENT libelektra4) - install (FILES AUTHORS.md DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} COMPONENT libelektra4) - install (FILES CONTRACT.ini DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} COMPONENT libelektra4) + install ( + FILES BIGPICTURE.md + DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} + COMPONENT libelektra4) + install ( + FILES GOALS.md + DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} + COMPONENT libelektra4) + install ( + FILES METADATA.ini + DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} + COMPONENT libelektra4) + install ( + FILES SECURITY.md + DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} + COMPONENT libelektra4) + install ( + FILES AUTHORS.md + DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} + COMPONENT libelektra4) + install ( + FILES CONTRACT.ini + DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} + COMPONENT libelektra4) set (news ${CMAKE_CURRENT_BINARY_DIR}/NEWS.md) file (GLOB files "news/*.md") file (REMOVE ${news}) @@ -136,8 +157,14 @@ if (INSTALL_DOCUMENTATION) file (READ ${file} content) file (APPEND ${news} "\n\n\n\n\n${content}") endforeach () - install (FILES ${news} DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} COMPONENT libelektra4) - install (FILES WHY.md DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} COMPONENT libelektra4) + install ( + FILES ${news} + DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} + COMPONENT libelektra4) + install ( + FILES WHY.md + DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} + COMPONENT libelektra4) endif () diff --git a/scripts/CMakeLists.txt b/scripts/CMakeLists.txt index 857c6123a82..2a83224f4e3 100644 --- a/scripts/CMakeLists.txt +++ b/scripts/CMakeLists.txt @@ -8,31 +8,67 @@ endif (PROCESSOR_COUNT EQUAL 0) set (CMAKE_MAKE_PROGRAM_BASENAME ${CMAKE_MAKE_PROGRAM}) string (REGEX REPLACE ".*/([^/]+)$" "\\1" CMAKE_MAKE_PROGRAM_BASENAME ${CMAKE_MAKE_PROGRAM_BASENAME}) -install (PROGRAMS benchmark-createtree DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin-extra) +install ( + PROGRAMS benchmark-createtree + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} + COMPONENT elektra-bin-extra) -install (PROGRAMS upgrade-bootstrap DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin-extra) +install ( + PROGRAMS upgrade-bootstrap + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} + COMPONENT elektra-bin-extra) -install (PROGRAMS kdb/mountpoint-info DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin-extra) -install (PROGRAMS check-env-dep DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-tests) +install ( + PROGRAMS kdb/mountpoint-info + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} + COMPONENT elektra-bin-extra) +install ( + PROGRAMS check-env-dep + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} + COMPONENT elektra-tests) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/make-source-package.in" "${CMAKE_CURRENT_BINARY_DIR}/make-source-package" @ONLY) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/configure-firefox.in" "${CMAKE_CURRENT_BINARY_DIR}/configure-firefox" @ONLY) -install (PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/configure-firefox" DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin-extra) +install ( + PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/configure-firefox" + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} + COMPONENT elektra-bin-extra) add_subdirectory (ffconfig) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/change-resolver-symlink.in" "${CMAKE_CURRENT_BINARY_DIR}/change-resolver-symlink" @ONLY) -install (PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/change-resolver-symlink" DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin) +install ( + PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/change-resolver-symlink" + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} + COMPONENT elektra-bin) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/change-storage-symlink.in" "${CMAKE_CURRENT_BINARY_DIR}/change-storage-symlink" @ONLY) -install (PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/change-storage-symlink" DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin) +install ( + PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/change-storage-symlink" + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} + COMPONENT elektra-bin) -install (PROGRAMS stash DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin) -install (PROGRAMS restore DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin) +install ( + PROGRAMS stash + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} + COMPONENT elektra-bin) +install ( + PROGRAMS restore + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} + COMPONENT elektra-bin) -install (PROGRAMS reset DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin) -install (PROGRAMS reset-elektra DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin) -install (PROGRAMS umount-all DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin) +install ( + PROGRAMS reset + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} + COMPONENT elektra-bin) +install ( + PROGRAMS reset-elektra + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} + COMPONENT elektra-bin) +install ( + PROGRAMS umount-all + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} + COMPONENT elektra-bin) add_custom_target ( source-package diff --git a/scripts/admin/CMakeLists.txt b/scripts/admin/CMakeLists.txt index 5ed72e24f54..7a412162b15 100644 --- a/scripts/admin/CMakeLists.txt +++ b/scripts/admin/CMakeLists.txt @@ -1 +1,4 @@ -install (PROGRAMS update-snippet-repository DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin-extra) +install ( + PROGRAMS update-snippet-repository + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} + COMPONENT elektra-bin-extra) diff --git a/scripts/cmake/CMakeLists.txt b/scripts/cmake/CMakeLists.txt index 690295b9cfc..7b2023e5fd2 100644 --- a/scripts/cmake/CMakeLists.txt +++ b/scripts/cmake/CMakeLists.txt @@ -26,8 +26,10 @@ write_basic_package_version_file ( VERSION ${KDB_VERSION} COMPATIBILITY AnyNewerVersion) -install (FILES "${CMAKE_CURRENT_BINARY_DIR}/ElektraConfig.cmake" "${CMAKE_CURRENT_BINARY_DIR}/ElektraConfigVersion.cmake" - DESTINATION ${TARGET_CMAKE_FOLDER} COMPONENT libelektra-dev) +install ( + FILES "${CMAKE_CURRENT_BINARY_DIR}/ElektraConfig.cmake" "${CMAKE_CURRENT_BINARY_DIR}/ElektraConfigVersion.cmake" + DESTINATION ${TARGET_CMAKE_FOLDER} + COMPONENT libelektra-dev) # pkg-config files if (BUILD_SHARED) @@ -42,7 +44,10 @@ elseif (BUILD_STATIC) endif () configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/elektra.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/elektra.pc" @ONLY) -install (FILES "${CMAKE_CURRENT_BINARY_DIR}/elektra.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} COMPONENT libelektra-dev) +install ( + FILES "${CMAKE_CURRENT_BINARY_DIR}/elektra.pc" + DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} + COMPONENT libelektra-dev) add_custom_target ( uninstall diff --git a/scripts/cmake/ElektraPackaging.cmake b/scripts/cmake/ElektraPackaging.cmake index 1815a872842..43582f8d108 100644 --- a/scripts/cmake/ElektraPackaging.cmake +++ b/scripts/cmake/ElektraPackaging.cmake @@ -10,24 +10,24 @@ set (CPACK_DEBIAN_PACKAGE_RELEASE "1") set (CPACK_DEBIAN_FILE_NAME DEB-DEFAULT) set ( - CPACK_COMPONENTS_ALL + CPACK_COMPONENTS_ALL libelektra4 libelektra4-all libelektra4-full libelektra4-experimental libelektra4-extra - libelektra4-augeas - libelektra4-crypto - libelektra4-curl - libelektra4-dbus + libelektra4-augeas + libelektra4-crypto + libelektra4-curl + libelektra4-dbus libelektra-dev - libelektra4-journald + libelektra4-journald libelektra4-lua libelektra4-python - libelektra4-xerces - libelektra4-xmltool - libelektra4-yajl - libelektra4-zeromq + libelektra4-xerces + libelektra4-xmltool + libelektra4-yajl + libelektra4-zeromq lua-elektra python3-elektra elektra-bin @@ -37,7 +37,7 @@ set ( elektra-tests) set (ALL_PLUGINS ${CPACK_COMPONENTS_ALL}) -list(FILTER ALL_PLUGINS INCLUDE REGEX "^libelektra4-.*") +list (FILTER ALL_PLUGINS INCLUDE REGEX "^libelektra4-.*") string (REPLACE ";" ", " ALL_PLUGINS_STR "${ALL_PLUGINS}") set ( @@ -106,24 +106,26 @@ if (UNIX) set (CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_NAME "libelektra4") set (CPACK_COMPONENT_LIBELEKTRA4_DISPLAY_NAME "libelektra4") - set ( - CPACK_COMPONENT_LIBELEKTRA4_DESCRIPTION - "This package contains the main elektra library, and most of the core plugins") + set (CPACK_COMPONENT_LIBELEKTRA4_DESCRIPTION "This package contains the main elektra library, and most of the core plugins") set (CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_SECTION "libs") - set (CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_BREAKS "elektra-bin (<< 0.8.14-5~), libelektra-core4 (<< 0.8.19-1), libelektra-full4 (<< 0.8.19-1)") - set (CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_REPLACES "elektra-bin (<< 0.8.14-5~), libelelektra-core4 (<< 0.8.19-1), libelektra-full4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_BREAKS + "elektra-bin (<< 0.8.14-5~), libelektra-core4 (<< 0.8.19-1), libelektra-full4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_REPLACES + "elektra-bin (<< 0.8.14-5~), libelelektra-core4 (<< 0.8.19-1), libelektra-full4 (<< 0.8.19-1)") set (CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_SUGGESTS "elektra-doc, ${ALL_PLUGINS_STR}") set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_NAME "libelektra4-full") set (CPACK_COMPONENT_LIBELEKTRA4-FULL_DISPLAY_NAME "libelektra4-full") - set ( - CPACK_COMPONENT_LIBELEKTRA4-FULL_DESCRIPTION - "This package contains an variant of the Elektra library in which all plugins + set (CPACK_COMPONENT_LIBELEKTRA4-FULL_DESCRIPTION + "This package contains an variant of the Elektra library in which all plugins are linked together to a full library. The package is only needed for testing.") set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_SECTION "libs") - set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_BREAKS "elektra-bin (<< 0.8.14-5~), libelektra-core4 (<< 0.8.19-1), libelektra-full4 (<< 0.8.19-1)") - set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_REPLACES "elektra-bin (<< 0.8.14-5~), libelelektra-core4 (<< 0.8.19-1), libelektra-full4 (<< 0.8.19-1)") - set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_CONFLICTS "libelektra4 (<< ${CPACK_DEBIAN_PACKAGE_VERSION}), elektra-tests (<< ${CPACK_DEBIAN_PACKAGE_VERSION})") + set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_BREAKS + "elektra-bin (<< 0.8.14-5~), libelektra-core4 (<< 0.8.19-1), libelektra-full4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_REPLACES + "elektra-bin (<< 0.8.14-5~), libelelektra-core4 (<< 0.8.19-1), libelektra-full4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_CONFLICTS + "libelektra4 (<< ${CPACK_DEBIAN_PACKAGE_VERSION}), elektra-tests (<< ${CPACK_DEBIAN_PACKAGE_VERSION})") set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_SUGGESTS "elektra-doc, ${ALL_PLUGINS_STR}") set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_PACKAGE_NAME "libelektra4-experimental") @@ -231,7 +233,7 @@ if (UNIX) set (CPACK_COMPONENT_LIBELEKTRA4-LUA_DESCRIPTION "This package contains the 'lua' plugin.") set (CPACK_COMPONENT_LIBELEKTRA4-LUA_DEPENDS "libelektra4") set (CPACK_DEBIAN_LIBELEKTRA4-LUA_PACKAGE_SECTION "libs") - + set (CPACK_DEBIAN_LUA-ELEKTRA_PACKAGE_NAME "lua-elektra") set (CPACK_COMPONENT_LUA-ELEKTRA_DISPLAY_NAME "lua-elektra") set (CPACK_COMPONENT_LUA-ELEKTRA_DESCRIPTION "This package contains the Lua bindings.") @@ -246,10 +248,11 @@ if (UNIX) set (CPACK_DEBIAN_PYTHON3-ELEKTRA_PACKAGE_SECTION "python") set (CPACK_DEBIAN_PYTHON3-ELEKTRA_PACKAGE_CONTROL_STRICT_PERMISSION TRUE) file (GLOB CONTROL_FILES_PYTHON3-ELEKTRA "${CMAKE_SOURCE_DIR}/scripts/packaging/debian-control/python3-elektra/*") - file (COPY ${CONTROL_FILES_PYTHON3-ELEKTRA} DESTINATION "${CMAKE_BINARY_DIR}/scripts/packaging/debian-control/python3-elektra/") + file (COPY ${CONTROL_FILES_PYTHON3-ELEKTRA} + DESTINATION "${CMAKE_BINARY_DIR}/scripts/packaging/debian-control/python3-elektra/") file (GLOB CONTROL_FILES_PYTHON3-ELEKTRA_BINARY "${CMAKE_BINARY_DIR}/scripts/packaging/debian-control/python3-elektra/*") set (CPACK_DEBIAN_PYTHON3-ELEKTRA_PACKAGE_CONTROL_EXTRA "${CONTROL_FILES_PYTHON3-ELEKTRA_BINARY}") - + set (CPACK_DEBIAN_LIBELEKTRA4-PYTHON_PACKAGE_NAME "libelektra4-python") set (CPACK_COMPONENT_LIBELEKTRA4-PYTHON_DISPLAY_NAME "libelektra4-python") set (CPACK_COMPONENT_LIBELEKTRA4-PYTHON_DESCRIPTION "This package contains the 'python' plugin.") @@ -257,12 +260,11 @@ if (UNIX) set (CPACK_DEBIAN_LIBELEKTRA4-PYTHON_PACKAGE_SECTION "libs") set (CPACK_DEBIAN_LIBELEKTRA4-PYTHON_PACKAGE_BREAKS "libelelektra-python4 (<< 0.8.19-1)") set (CPACK_DEBIAN_LIBELEKTRA4-PYTHON_PACKAGE_REPLACES "libelelektra-python4 (<< 0.8.19-1)") - + set (CPACK_DEBIAN_ELEKTRA-BIN-EXTRA_PACKAGE_NAME "elektra-bin-extra") set (CPACK_COMPONENT_ELEKTRA-BIN-EXTRA_DISPLAY_NAME "elektra-bin-extra") - set ( - CPACK_COMPONENT_ELEKTRA-BIN-EXTRA_DESCRIPTION - "This package contains extra command line utilities for Elektra written in non-shell languages like python.") + set (CPACK_COMPONENT_ELEKTRA-BIN-EXTRA_DESCRIPTION + "This package contains extra command line utilities for Elektra written in non-shell languages like python.") set (CPACK_COMPONENT_ELEKTRA-BIN-EXTRA_DEPENDS "libelektra4") set (CPACK_DEBIAN_ELEKTRA-BIN-EXTRA_PACKAGE_DEPENDS "python-all") set (CPACK_DEBIAN_ELEKTRA-BIN-EXTRA_PACKAGE_SECTION "misc") @@ -274,10 +276,16 @@ if (UNIX) set (CPACK_COMPONENT_ELEKTRA-QT-GUI_DEPENDS "libelektra4") if ("${LSB_DISTRIB}" MATCHES "Ubuntu20.04") # qml-module-qtquick-controls-styles-breeze not available on ubuntu focal - set (CPACK_DEBIAN_ELEKTRA-QT-GUI_PACKAGE_DEPENDS "qml-module-qtquick2, qml-module-qtquick-window2, qml-module-qtquick-dialogs, qml-module-qt-labs-folderlistmodel, qml-module-qt-labs-settings") - else() - set (CPACK_DEBIAN_ELEKTRA-QT-GUI_PACKAGE_DEPENDS "qml-module-qtquick2, qml-module-qtquick-window2, qml-module-qtquick-dialogs, qml-module-qt-labs-folderlistmodel, qml-module-qt-labs-settings, qml-module-qtquick-controls-styles-breeze") - endif() + set ( + CPACK_DEBIAN_ELEKTRA-QT-GUI_PACKAGE_DEPENDS + "qml-module-qtquick2, qml-module-qtquick-window2, qml-module-qtquick-dialogs, qml-module-qt-labs-folderlistmodel, qml-module-qt-labs-settings" + ) + else () + set ( + CPACK_DEBIAN_ELEKTRA-QT-GUI_PACKAGE_DEPENDS + "qml-module-qtquick2, qml-module-qtquick-window2, qml-module-qtquick-dialogs, qml-module-qt-labs-folderlistmodel, qml-module-qt-labs-settings, qml-module-qtquick-controls-styles-breeze" + ) + endif () set (CPACK_DEBIAN_ELEKTRA-QT-GUI_PACKAGE_SECTION "misc") set (CPACK_DEBIAN_ELEKTRA-TESTS_PACKAGE_NAME "elektra-tests") @@ -296,14 +304,39 @@ if (UNIX) set (CPACK_DEBIAN_ELEKTRA-DOC_PACKAGE_SECTION "doc") set (CPACK_DEBIAN_ELEKTRA-DOC_PACKAGE_BREAKS "libelektra-doc (<< 0.8.19-1)") set (CPACK_DEBIAN_ELEKTRA-DOC_PACKAGE_REPLACES "libelektra-doc (<< 0.8.19-1)") - install (FILES "${CMAKE_SOURCE_DIR}/scripts/packaging/doc-base/elektra-doc" COMPONENT elektra-doc DESTINATION ${TARGET_DOCUMENTATION_DOC-BASE_FOLDER}) + install ( + FILES "${CMAKE_SOURCE_DIR}/scripts/packaging/doc-base/elektra-doc" + COMPONENT elektra-doc + DESTINATION ${TARGET_DOCUMENTATION_DOC-BASE_FOLDER}) set (CPACK_DEBIAN_LIBELEKTRA4-ALL_PACKAGE_NAME "libelektra4-all") set (CPACK_COMPONENT_LIBELEKTRA4-ALL_DISPLAY_NAME "libelektra4-all") - set (CPACK_COMPONENT_LIBELEKTRA4-ALL_DESCRIPTION "This package contains extra command line utilities for Elektra written in non-shell languages like python.") - set (CPACK_COMPONENT_LIBELEKTRA4-ALL_DEPENDS "libelektra4" "libelektra4-experimental" "libelektra4-augeas" "libelektra4-dbus" "libelektra4-zeromq" "libelektra4-lua" "libelektra4-python" "libelektra4-xmltool" "libelektra4-xerces" "libelektra4-yajl" "lua-elektra" "elektra-bin" "elektra-qt-gui" "libelektra4-crypto" "libelektra4-curl" "libelektra4-journald" "libelektra4-extra") + set (CPACK_COMPONENT_LIBELEKTRA4-ALL_DESCRIPTION + "This package contains extra command line utilities for Elektra written in non-shell languages like python.") + set ( + CPACK_COMPONENT_LIBELEKTRA4-ALL_DEPENDS + "libelektra4" + "libelektra4-experimental" + "libelektra4-augeas" + "libelektra4-dbus" + "libelektra4-zeromq" + "libelektra4-lua" + "libelektra4-python" + "libelektra4-xmltool" + "libelektra4-xerces" + "libelektra4-yajl" + "lua-elektra" + "elektra-bin" + "elektra-qt-gui" + "libelektra4-crypto" + "libelektra4-curl" + "libelektra4-journald" + "libelektra4-extra") set (CPACK_DEBIAN_LIBELEKTRA4-ALL_PACKAGE_SECTION "misc") - set (CPACK_DEBIAN_LIBELEKTRA4-ALL_PACKAGE_DEPENDS "libelektra4, libelektra4-experimental, libelektra4-augeas, libelektra4-dbus, libelektra4-zeromq, libelektra4-lua, libelektra4-python, libelektra4-xmltool, libelektra4-xerces, libelektra4-yajl, lua-elektra, elektra-bin, elektra-qt-gui, libelektra4-crypto, libelektra4-curl, libelektra4-journald, libelektra4-extra") + set ( + CPACK_DEBIAN_LIBELEKTRA4-ALL_PACKAGE_DEPENDS + "libelektra4, libelektra4-experimental, libelektra4-augeas, libelektra4-dbus, libelektra4-zeromq, libelektra4-lua, libelektra4-python, libelektra4-xmltool, libelektra4-xerces, libelektra4-yajl, lua-elektra, elektra-bin, elektra-qt-gui, libelektra4-crypto, libelektra4-curl, libelektra4-journald, libelektra4-extra" + ) set (CPACK_DEBIAN_LIBELEKTRA4-ALL_PACKAGE_RECOMMENDS "elektra-tests, elektra-doc, libelektra-dev") # add all .ddeb packages? # build debug package for each component diff --git a/scripts/cmake/Modules/LibAddMacros.cmake b/scripts/cmake/Modules/LibAddMacros.cmake index c24b5295dad..7bb5f9e18e4 100644 --- a/scripts/cmake/Modules/LibAddMacros.cmake +++ b/scripts/cmake/Modules/LibAddMacros.cmake @@ -604,7 +604,10 @@ If you do not add this file, then installing Elektra will fail!\n") endif (NOT EXISTS "${OUTFILE}") if (INSTALL_DOCUMENTATION) - install (FILES ${OUTFILE} DESTINATION share/man/man${SECTION} COMPONENT "${ARG_COMPONENT}") + install ( + FILES ${OUTFILE} + DESTINATION share/man/man${SECTION} + COMPONENT "${ARG_COMPONENT}") endif () endif (BUILD_DOCUMENTATION) endfunction () diff --git a/scripts/cmake/Modules/LibAddPlugin.cmake b/scripts/cmake/Modules/LibAddPlugin.cmake index 372b9765052..3aa2f9cf077 100644 --- a/scripts/cmake/Modules/LibAddPlugin.cmake +++ b/scripts/cmake/Modules/LibAddPlugin.cmake @@ -175,9 +175,15 @@ function (add_plugintest testname) # ~~~ if (INSTALL_TESTING) - install (TARGETS ${testexename} DESTINATION "${TARGET_TOOL_EXEC_FOLDER}" COMPONENT elektra-tests) + install ( + TARGETS ${testexename} + DESTINATION "${TARGET_TOOL_EXEC_FOLDER}" + COMPONENT elektra-tests) if (ARG_INSTALL_TEST_DATA) - install (DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/${testname}" DESTINATION "${TARGET_TEST_DATA_FOLDER}" COMPONENT elektra-tests) + install ( + DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/${testname}" + DESTINATION "${TARGET_TEST_DATA_FOLDER}" + COMPONENT elektra-tests) endif () endif (INSTALL_TESTING) @@ -433,9 +439,10 @@ function (add_plugin PLUGIN_SHORT_NAME) if (ADDTESTING_PHASE) if (ARG_INSTALL_TEST_DATA AND NOT ARG_ADD_TEST) if (INSTALL_TESTING) - install (DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/${PLUGIN_SHORT_NAME}" - DESTINATION "${TARGET_TEST_DATA_FOLDER}" - COMPONENT elektra-tests) + install ( + DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/${PLUGIN_SHORT_NAME}" + DESTINATION "${TARGET_TEST_DATA_FOLDER}" + COMPONENT elektra-tests) endif (INSTALL_TESTING) endif () @@ -618,7 +625,10 @@ function (add_plugin PLUGIN_SHORT_NAME) target_link_libraries (${PLUGIN_NAME} elektra-plugin) endif () target_link_libraries (${PLUGIN_NAME} ${ARG_LINK_LIBRARIES}) - install (TARGETS ${PLUGIN_NAME} DESTINATION lib${LIB_SUFFIX}/${TARGET_PLUGIN_FOLDER} COMPONENT "${ARG_COMPONENT}") + install ( + TARGETS ${PLUGIN_NAME} + DESTINATION lib${LIB_SUFFIX}/${TARGET_PLUGIN_FOLDER} + COMPONENT "${ARG_COMPONENT}") set_property ( TARGET ${PLUGIN_NAME} APPEND diff --git a/scripts/cmake/Modules/LibAddTest.cmake b/scripts/cmake/Modules/LibAddTest.cmake index f956be5b383..fd88a8070fa 100644 --- a/scripts/cmake/Modules/LibAddTest.cmake +++ b/scripts/cmake/Modules/LibAddTest.cmake @@ -48,7 +48,10 @@ macro (add_gtest source) include_directories (${CMAKE_SOURCE_DIR}/tests/gtest-framework) if (INSTALL_TESTING) - install (TARGETS ${source} DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-tests) + install ( + TARGETS ${source} + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} + COMPONENT elektra-tests) endif (INSTALL_TESTING) set_target_properties (${source} PROPERTIES COMPILE_DEFINITIONS HAVE_KDBCONFIG_H) diff --git a/scripts/completion/CMakeLists.txt b/scripts/completion/CMakeLists.txt index 05e894146a5..856d47668ab 100644 --- a/scripts/completion/CMakeLists.txt +++ b/scripts/completion/CMakeLists.txt @@ -1,7 +1,10 @@ file (READ "kdb_zsh_completion" CONTENT_OF_ZSH_COMP) file (READ "kdb-bash-completion" CONTENT_OF_BASH_COMP) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/install-sh-completion.in" "${CMAKE_CURRENT_BINARY_DIR}/install-sh-completion" @ONLY) -install (PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/install-sh-completion" DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin) +install ( + PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/install-sh-completion" + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} + COMPONENT elektra-bin) if (INSTALL_SYSTEM_FILES) if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin") @@ -43,7 +46,10 @@ if (INSTALL_SYSTEM_FILES) pkg_get_variable (FISH_COMPLETION_COMPLETIONSDIR fish completionsdir) endif () endif () - install (FILES kdb.fish DESTINATION ${FISH_COMPLETION_COMPLETIONSDIR} COMPONENT elektra-bin) + install ( + FILES kdb.fish + DESTINATION ${FISH_COMPLETION_COMPLETIONSDIR} + COMPONENT elektra-bin) if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin") diff --git a/scripts/ffconfig/CMakeLists.txt b/scripts/ffconfig/CMakeLists.txt index b0bdb48ac04..dcd3ecd904e 100644 --- a/scripts/ffconfig/CMakeLists.txt +++ b/scripts/ffconfig/CMakeLists.txt @@ -1,4 +1,16 @@ -install (PROGRAMS writeConfigFiles DESTINATION "${TARGET_TOOL_EXEC_FOLDER}/ffconfig/" COMPONENT elektra-bin-extra) -install (PROGRAMS setupConfig DESTINATION "${TARGET_TOOL_EXEC_FOLDER}/ffconfig/" COMPONENT elektra-bin-extra) -install (PROGRAMS setupProxy DESTINATION "${TARGET_TOOL_EXEC_FOLDER}/ffconfig/" COMPONENT elektra-bin-extra) -install (PROGRAMS setupHomepage DESTINATION "${TARGET_TOOL_EXEC_FOLDER}/ffconfig/" COMPONENT elektra-bin-extra) +install ( + PROGRAMS writeConfigFiles + DESTINATION "${TARGET_TOOL_EXEC_FOLDER}/ffconfig/" + COMPONENT elektra-bin-extra) +install ( + PROGRAMS setupConfig + DESTINATION "${TARGET_TOOL_EXEC_FOLDER}/ffconfig/" + COMPONENT elektra-bin-extra) +install ( + PROGRAMS setupProxy + DESTINATION "${TARGET_TOOL_EXEC_FOLDER}/ffconfig/" + COMPONENT elektra-bin-extra) +install ( + PROGRAMS setupHomepage + DESTINATION "${TARGET_TOOL_EXEC_FOLDER}/ffconfig/" + COMPONENT elektra-bin-extra) diff --git a/scripts/kdb/CMakeLists.txt b/scripts/kdb/CMakeLists.txt index 30798628ebb..ada845647b4 100644 --- a/scripts/kdb/CMakeLists.txt +++ b/scripts/kdb/CMakeLists.txt @@ -4,20 +4,15 @@ file (GLOB IN_FILES *.in) foreach (file ${IN_FILES}) get_filename_component (file_we "${file}" NAME_WE) configure_file ("${file}" "${file_we}" @ONLY) - install (PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/${file_we}" DESTINATION "${TARGET_TOOL_EXEC_FOLDER}" COMPONENT elektra-bin) + install ( + PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/${file_we}" + DESTINATION "${TARGET_TOOL_EXEC_FOLDER}" + COMPONENT elektra-bin) endforeach (file ${IN_FILES}) -set ( - COMPONENT_BIN_EXTRA_FILES - "find-tools" - "mount-list-all-files" - "mountpoint-info") +set (COMPONENT_BIN_EXTRA_FILES "find-tools" "mount-list-all-files" "mountpoint-info") -set ( - NOT_INCLUDE - "cmerge-config-files" - "install-config-file" -) +set (NOT_INCLUDE "cmerge-config-files" "install-config-file") file (GLOB ALL_FILES *) list (REMOVE_ITEM ALL_FILES ${IN_FILES}) @@ -25,11 +20,14 @@ list (REMOVE_ITEM ALL_FILES "${CMAKE_CURRENT_SOURCE_DIR}/CMakeLists.txt") foreach (file ${ALL_FILES}) get_filename_component (file_we "${file}" NAME_WE) if ("${file_we}" IN_LIST COMPONENT_BIN_EXTRA_FILES) - set(HAS_COMPONENT elektra-bin-extra) + set (HAS_COMPONENT elektra-bin-extra) elseif ("${file_we}" IN_LIST NOT_INCLUDE) - set(HAS_COMPONENT "") + set (HAS_COMPONENT "") else () - set(HAS_COMPONENT elektra-bin) - endif() - install (PROGRAMS "${file}" DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT ${HAS_COMPONENT}) + set (HAS_COMPONENT elektra-bin) + endif () + install ( + PROGRAMS "${file}" + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} + COMPONENT ${HAS_COMPONENT}) endforeach (file ${ALL_FILES}) diff --git a/src/bindings/cpp/include/CMakeLists.txt b/src/bindings/cpp/include/CMakeLists.txt index bd3d7be44be..5c0c4e2cbab 100644 --- a/src/bindings/cpp/include/CMakeLists.txt +++ b/src/bindings/cpp/include/CMakeLists.txt @@ -1,3 +1,6 @@ file (GLOB HEADER_FILES *.hpp) -install (FILES ${HEADER_FILES} DESTINATION include/${TARGET_INCLUDE_FOLDER} COMPONENT libelektra-dev) +install ( + FILES ${HEADER_FILES} + DESTINATION include/${TARGET_INCLUDE_FOLDER} + COMPONENT libelektra-dev) diff --git a/src/bindings/intercept/env/examples/CMakeLists.txt b/src/bindings/intercept/env/examples/CMakeLists.txt index 4821dcc6212..002557b45f3 100644 --- a/src/bindings/intercept/env/examples/CMakeLists.txt +++ b/src/bindings/intercept/env/examples/CMakeLists.txt @@ -9,7 +9,10 @@ macro (do_example source) set (SOURCES ${HDR_FILES} ${source}.c) add_executable (${source} ${SOURCES}) - install (TARGETS ${source} DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-bin) + install ( + TARGETS ${source} + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} + COMPONENT elektra-bin) set_target_properties (${source} PROPERTIES COMPILE_DEFINITIONS HAVE_KDBCONFIG_H) endmacro (do_example) diff --git a/src/bindings/intercept/env/include/CMakeLists.txt b/src/bindings/intercept/env/include/CMakeLists.txt index 80fd5c45980..ef1d0dcce51 100644 --- a/src/bindings/intercept/env/include/CMakeLists.txt +++ b/src/bindings/intercept/env/include/CMakeLists.txt @@ -1,3 +1,6 @@ file (GLOB HDR_FILES *.h) -install (FILES ${HDR_FILES} DESTINATION include/${TARGET_INCLUDE_FOLDER} COMPONENT libelektra-dev) +install ( + FILES ${HDR_FILES} + DESTINATION include/${TARGET_INCLUDE_FOLDER} + COMPONENT libelektra-dev) diff --git a/src/bindings/intercept/env/src/CMakeLists.txt b/src/bindings/intercept/env/src/CMakeLists.txt index 7f1c56189e7..8857b2e908e 100644 --- a/src/bindings/intercept/env/src/CMakeLists.txt +++ b/src/bindings/intercept/env/src/CMakeLists.txt @@ -18,7 +18,10 @@ set_target_properties ( LINKER_LANGUAGE CXX) -install (TARGETS elektraintercept-env DESTINATION lib${LIB_SUFFIX} COMPONENT libelektra4) +install ( + TARGETS elektraintercept-env + DESTINATION lib${LIB_SUFFIX} + COMPONENT libelektra4) mkdir (${CMAKE_LIBRARY_OUTPUT_DIRECTORY}) create_lib_symlink (libelektraintercept-env.so libelektragetenv.so libelektra4) diff --git a/src/bindings/intercept/fs/CMakeLists.txt b/src/bindings/intercept/fs/CMakeLists.txt index ade3e7602ef..884ece8e131 100644 --- a/src/bindings/intercept/fs/CMakeLists.txt +++ b/src/bindings/intercept/fs/CMakeLists.txt @@ -13,7 +13,10 @@ else () set_source_files_properties (intercept.c PROPERTIES COMPILE_FLAGS "-Wno-unused-result") add_library (elektraintercept-fs SHARED "intercept.c") target_link_libraries (elektraintercept-fs elektra-kdb elektra-meta) - install (TARGETS elektraintercept-fs DESTINATION lib${LIB_SUFFIX} COMPONENT libelektra4) + install ( + TARGETS elektraintercept-fs + DESTINATION lib${LIB_SUFFIX} + COMPONENT libelektra4) mkdir (${CMAKE_LIBRARY_OUTPUT_DIRECTORY}) create_lib_symlink (libelektraintercept-fs.so libelektraintercept.so libelektra4) diff --git a/src/include/elektra/CMakeLists.txt b/src/include/elektra/CMakeLists.txt index 84cf1b7a642..bfb4c4328a8 100644 --- a/src/include/elektra/CMakeLists.txt +++ b/src/include/elektra/CMakeLists.txt @@ -1 +1,4 @@ -install (FILES error.h conversion.h types.h DESTINATION include/${TARGET_INCLUDE_FOLDER}/elektra COMPONENT libelektra-dev) +install ( + FILES error.h conversion.h types.h + DESTINATION include/${TARGET_INCLUDE_FOLDER}/elektra + COMPONENT libelektra-dev) diff --git a/src/libs/CMakeLists.txt b/src/libs/CMakeLists.txt index 32a81f8fd12..fd61370d1c1 100644 --- a/src/libs/CMakeLists.txt +++ b/src/libs/CMakeLists.txt @@ -41,4 +41,11 @@ foreach (subdir ${SUBDIRS}) add_subdirectory ("${subdir}") endforeach (subdir) -generate_manpage (elektra-libs FILENAME "${CMAKE_CURRENT_SOURCE_DIR}/README.md" SECTION 7 COMPONENT elektra-doc) +generate_manpage ( + elektra-libs + FILENAME + "${CMAKE_CURRENT_SOURCE_DIR}/README.md" + SECTION + 7 + COMPONENT + elektra-doc) diff --git a/src/libs/elektra/CMakeLists.txt b/src/libs/elektra/CMakeLists.txt index b545eb5ca7d..7ec132f98f4 100644 --- a/src/libs/elektra/CMakeLists.txt +++ b/src/libs/elektra/CMakeLists.txt @@ -180,7 +180,10 @@ if (BUILD_STATIC) endif (BUILD_STATIC) export (TARGETS ${targets_built} FILE "${CMAKE_CURRENT_BINARY_DIR}/ElektraTargetsLibelektra.cmake") -install (EXPORT ElektraTargetsLibelektra DESTINATION "${TARGET_CMAKE_FOLDER}" COMPONENT libelektra-dev) +install ( + EXPORT ElektraTargetsLibelektra + DESTINATION "${TARGET_CMAKE_FOLDER}" + COMPONENT libelektra-dev) # if you want the same name for those 3 libraries, here is how to do it: # http://www.itk.org/Wiki/CMake_FAQ#How_do_I_make_my_shared_and_static_libraries_have_the_same_root_name.2C_but_different_suffixes.3F diff --git a/src/libs/globbing/CMakeLists.txt b/src/libs/globbing/CMakeLists.txt index 20df7ff1be0..df2411de557 100644 --- a/src/libs/globbing/CMakeLists.txt +++ b/src/libs/globbing/CMakeLists.txt @@ -3,7 +3,14 @@ file (GLOB SOURCES *.c) safe_check_symbol_exists ("fnmatch" "fnmatch.h" HAVE_FNMATCH) if (HAVE_FNMATCH) - add_lib (globbing SOURCES ${SOURCES} LINK_ELEKTRA elektra-ease COMPONENT libelektra4) + add_lib ( + globbing + SOURCES + ${SOURCES} + LINK_ELEKTRA + elektra-ease + COMPONENT + libelektra4) else () message ("Excluding lib-globbing, because fnmatch was not found.") endif () diff --git a/src/libs/highlevel/CMakeLists.txt b/src/libs/highlevel/CMakeLists.txt index 367ecbf1aeb..94287bbf280 100644 --- a/src/libs/highlevel/CMakeLists.txt +++ b/src/libs/highlevel/CMakeLists.txt @@ -1,6 +1,14 @@ file (GLOB SOURCES *.c) -add_lib (highlevel SOURCES ${SOURCES} LINK_ELEKTRA elektra-kdb elektra-ease COMPONENT libelektra4) +add_lib ( + highlevel + SOURCES + ${SOURCES} + LINK_ELEKTRA + elektra-kdb + elektra-ease + COMPONENT + libelektra4) if (BUILD_SHARED) set (LIBRARIES "-lelektra-highlevel -lelektra-kdb -lelektra-ease -lelektra-core") @@ -14,7 +22,13 @@ else (BUILD_STATIC) endif () configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/elektra-highlevel.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/elektra-highlevel.pc" @ONLY) -install (FILES "${CMAKE_CURRENT_BINARY_DIR}/elektra-highlevel.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} COMPONENT libelektra-dev) +install ( + FILES "${CMAKE_CURRENT_BINARY_DIR}/elektra-highlevel.pc" + DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} + COMPONENT libelektra-dev) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/elektra-codegen.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/elektra-codegen.pc" @ONLY) -install (FILES "${CMAKE_CURRENT_BINARY_DIR}/elektra-codegen.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} COMPONENT libelektra-dev) +install ( + FILES "${CMAKE_CURRENT_BINARY_DIR}/elektra-codegen.pc" + DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} + COMPONENT libelektra-dev) diff --git a/src/libs/invoke/CMakeLists.txt b/src/libs/invoke/CMakeLists.txt index 733920d4da5..b0eb3bacc4d 100644 --- a/src/libs/invoke/CMakeLists.txt +++ b/src/libs/invoke/CMakeLists.txt @@ -1,2 +1,9 @@ file (GLOB SOURCES *.c) -add_lib (invoke SOURCES ${SOURCES} LINK_ELEKTRA elektra-kdb COMPONENT libelektra4) +add_lib ( + invoke + SOURCES + ${SOURCES} + LINK_ELEKTRA + elektra-kdb + COMPONENT + libelektra4) diff --git a/src/libs/io/CMakeLists.txt b/src/libs/io/CMakeLists.txt index 26a44fc4321..ba0c5a0a47f 100644 --- a/src/libs/io/CMakeLists.txt +++ b/src/libs/io/CMakeLists.txt @@ -2,11 +2,21 @@ set (SOURCES "${CMAKE_CURRENT_SOURCE_DIR}/io.c") set (LIBRARY_NAME elektra-io) -add_lib (io SOURCES ${SOURCES} LINK_ELEKTRA elektra-kdb elektra-invoke - COMPONENT libelektra4) +add_lib ( + io + SOURCES + ${SOURCES} + LINK_ELEKTRA + elektra-kdb + elektra-invoke + COMPONENT + libelektra4) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/${LIBRARY_NAME}.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/${LIBRARY_NAME}.pc" @ONLY) -install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${LIBRARY_NAME}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} COMPONENT libelektra-dev) +install ( + FILES "${CMAKE_CURRENT_BINARY_DIR}/${LIBRARY_NAME}.pc" + DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} + COMPONENT libelektra-dev) add_subdirectory (adapter) diff --git a/src/libs/merge/CMakeLists.txt b/src/libs/merge/CMakeLists.txt index 1cc1259b627..a9699caf6e7 100644 --- a/src/libs/merge/CMakeLists.txt +++ b/src/libs/merge/CMakeLists.txt @@ -25,7 +25,8 @@ add_lib ( elektra-ease LINK_LIBRARIES ${CMERGE_LIBRARY_DIRS} - COMPONENT elektra-bin) + COMPONENT + elektra-bin) set (LIBRARY_NAME elektra-merge) diff --git a/src/libs/meta/CMakeLists.txt b/src/libs/meta/CMakeLists.txt index 0d12edb5837..8aa1adb0f14 100644 --- a/src/libs/meta/CMakeLists.txt +++ b/src/libs/meta/CMakeLists.txt @@ -1,2 +1,9 @@ file (GLOB SOURCES *.c) -add_lib (meta SOURCES ${SOURCES} LINK_ELEKTRA elektra-ease COMPONENT libelektra4) +add_lib ( + meta + SOURCES + ${SOURCES} + LINK_ELEKTRA + elektra-ease + COMPONENT + libelektra4) diff --git a/src/libs/notification/CMakeLists.txt b/src/libs/notification/CMakeLists.txt index 0df0c692c8a..8345a1a35cc 100644 --- a/src/libs/notification/CMakeLists.txt +++ b/src/libs/notification/CMakeLists.txt @@ -16,11 +16,15 @@ else () elektra-kdb elektra-ease elektra-invoke - COMPONENT libelektra4) + COMPONENT + libelektra4) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/${LIBRARY_NAME}.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/${LIBRARY_NAME}.pc" @ONLY) - install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${LIBRARY_NAME}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} COMPONENT libelektra-dev) + install ( + FILES "${CMAKE_CURRENT_BINARY_DIR}/${LIBRARY_NAME}.pc" + DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} + COMPONENT libelektra-dev) if (ENABLE_TESTING) add_subdirectory (tests) diff --git a/src/libs/opts/CMakeLists.txt b/src/libs/opts/CMakeLists.txt index f38f3d8a702..e24c7f388dc 100644 --- a/src/libs/opts/CMakeLists.txt +++ b/src/libs/opts/CMakeLists.txt @@ -1,3 +1,10 @@ file (GLOB SOURCES *.c) -add_lib (opts SOURCES ${SOURCES} LINK_ELEKTRA elektra-meta COMPONENT libelektra4) +add_lib ( + opts + SOURCES + ${SOURCES} + LINK_ELEKTRA + elektra-meta + COMPONENT + libelektra4) diff --git a/src/libs/pluginprocess/CMakeLists.txt b/src/libs/pluginprocess/CMakeLists.txt index 0743efd9cb3..d21d4b9a8c3 100644 --- a/src/libs/pluginprocess/CMakeLists.txt +++ b/src/libs/pluginprocess/CMakeLists.txt @@ -3,7 +3,15 @@ find_package (Pluginprocess) file (GLOB SOURCES *.c) if (PLUGINPROCESS_FOUND) - add_lib (pluginprocess SOURCES ${SOURCES} LINK_ELEKTRA elektra-invoke elektra-plugin COMPONENT libelektra4) + add_lib ( + pluginprocess + SOURCES + ${SOURCES} + LINK_ELEKTRA + elektra-invoke + elektra-plugin + COMPONENT + libelektra4) if (ENABLE_TESTING) add_subdirectory (tests) diff --git a/src/libs/tools/include/CMakeLists.txt b/src/libs/tools/include/CMakeLists.txt index 3615452b062..fcb168b4330 100644 --- a/src/libs/tools/include/CMakeLists.txt +++ b/src/libs/tools/include/CMakeLists.txt @@ -1,11 +1,20 @@ file (GLOB HDR_FILES *.hpp) -install (FILES ${HDR_FILES} DESTINATION include/${TARGET_INCLUDE_FOLDER} COMPONENT libelektra-dev) +install ( + FILES ${HDR_FILES} + DESTINATION include/${TARGET_INCLUDE_FOLDER} + COMPONENT libelektra-dev) file (GLOB HELPER_HDR_FILES helper/*.hpp) -install (FILES ${HELPER_HDR_FILES} DESTINATION include/${TARGET_INCLUDE_FOLDER}/helper COMPONENT libelektra-dev) +install ( + FILES ${HELPER_HDR_FILES} + DESTINATION include/${TARGET_INCLUDE_FOLDER}/helper + COMPONENT libelektra-dev) file (GLOB MERGING_HDR_FILES merging/*.hpp) -install (FILES ${MERGING_HDR_FILES} DESTINATION include/${TARGET_INCLUDE_FOLDER}/merging COMPONENT libelektra-dev) +install ( + FILES ${MERGING_HDR_FILES} + DESTINATION include/${TARGET_INCLUDE_FOLDER}/merging + COMPONENT libelektra-dev) diff --git a/src/libs/tools/src/CMakeLists.txt b/src/libs/tools/src/CMakeLists.txt index dd8348d7bdd..366c2af4e79 100644 --- a/src/libs/tools/src/CMakeLists.txt +++ b/src/libs/tools/src/CMakeLists.txt @@ -35,7 +35,10 @@ if (BUILD_SHARED) set_target_properties (elektratools PROPERTIES LINK_FLAGS "-Wl,--version-script='${__symbols_file}'") endif () - install (TARGETS elektratools DESTINATION lib${LIB_SUFFIX} COMPONENT elektra-bin) + install ( + TARGETS elektratools + DESTINATION lib${LIB_SUFFIX} + COMPONENT elektra-bin) endif (BUILD_SHARED) if (BUILD_FULL) @@ -53,7 +56,10 @@ if (BUILD_FULL) set_target_properties (elektratools-full PROPERTIES LINK_FLAGS "-Wl,--version-script='${__symbols_file}'") endif () - install (TARGETS elektratools-full DESTINATION lib${LIB_SUFFIX} COMPONENT libelektra4-full) + install ( + TARGETS elektratools-full + DESTINATION lib${LIB_SUFFIX} + COMPONENT libelektra4-full) endif (BUILD_FULL) if (BUILD_STATIC) @@ -72,5 +78,8 @@ if (BUILD_STATIC) set_target_properties (elektratools-static PROPERTIES LINK_FLAGS "-Wl,--version-script='${__symbols_file}'") endif () - install (TARGETS elektratools-static DESTINATION lib${LIB_SUFFIX} COMPONENT elektra-bin) + install ( + TARGETS elektratools-static + DESTINATION lib${LIB_SUFFIX} + COMPONENT elektra-bin) endif (BUILD_STATIC) diff --git a/src/plugins/CMakeLists.txt b/src/plugins/CMakeLists.txt index bf81a375ac5..179a7801e74 100644 --- a/src/plugins/CMakeLists.txt +++ b/src/plugins/CMakeLists.txt @@ -18,7 +18,14 @@ if (ADDTESTING_PHASE) return () endif () -generate_manpage (elektra-plugins FILENAME ${CMAKE_CURRENT_SOURCE_DIR}/README.md SECTION 7 COMPONENT elektra-doc) +generate_manpage ( + elektra-plugins + FILENAME + ${CMAKE_CURRENT_SOURCE_DIR}/README.md + SECTION + 7 + COMPONENT + elektra-doc) set (COLLECTION_PHASE ON) set (DEPENDENCY_PHASE OFF) diff --git a/src/plugins/augeas/CMakeLists.txt b/src/plugins/augeas/CMakeLists.txt index d939c9e9564..9c72d75a202 100644 --- a/src/plugins/augeas/CMakeLists.txt +++ b/src/plugins/augeas/CMakeLists.txt @@ -45,5 +45,4 @@ add_plugin ( COMPILE_DEFINITIONS "${LIBAUGEAS_COMPILE_DEFINITIONS}" LINK_ELEKTRA elektra-meta LINK_LIBRARIES ${AUGEAS_PLUGIN_LIBRARIES} - TEST_ENVIRONMENT "ASAN_OPTIONS=detect_container_overflow=0" - COMPONENT libelektra4-augeas) + TEST_ENVIRONMENT "ASAN_OPTIONS=detect_container_overflow=0" COMPONENT libelektra4-augeas) diff --git a/src/plugins/base64/CMakeLists.txt b/src/plugins/base64/CMakeLists.txt index 26c12f88b23..4bb0c40070f 100644 --- a/src/plugins/base64/CMakeLists.txt +++ b/src/plugins/base64/CMakeLists.txt @@ -4,5 +4,4 @@ add_plugin ( base64 SOURCES base64_functions.h base64_functions.c base64.h base64.c ADD_TEST TEST_README - TEST_REQUIRED_PLUGINS toml - COMPONENT libelektra4) + TEST_REQUIRED_PLUGINS toml COMPONENT libelektra4) diff --git a/src/plugins/blockresolver/CMakeLists.txt b/src/plugins/blockresolver/CMakeLists.txt index 1aa27c29171..f250d7a8f21 100644 --- a/src/plugins/blockresolver/CMakeLists.txt +++ b/src/plugins/blockresolver/CMakeLists.txt @@ -3,5 +3,4 @@ add_plugin ( SOURCES blockresolver.h blockresolver.c LINK_ELEKTRA elektra-invoke ADD_TEST INSTALL_TEST_DATA TEST_README - TEST_REQUIRED_PLUGINS mini - COMPONENT libelektra4-experimental) + TEST_REQUIRED_PLUGINS mini COMPONENT libelektra4-experimental) diff --git a/src/plugins/c/CMakeLists.txt b/src/plugins/c/CMakeLists.txt index 786e1a2b9aa..4993e5376ac 100644 --- a/src/plugins/c/CMakeLists.txt +++ b/src/plugins/c/CMakeLists.txt @@ -1,4 +1,3 @@ include (LibAddMacros) -add_plugin (c SOURCES c.h c.c - COMPONENT libelektra4) +add_plugin (c SOURCES c.h c.c COMPONENT libelektra4) diff --git a/src/plugins/cache/CMakeLists.txt b/src/plugins/cache/CMakeLists.txt index ecfb196bd0c..0beeb9bbfc5 100644 --- a/src/plugins/cache/CMakeLists.txt +++ b/src/plugins/cache/CMakeLists.txt @@ -28,8 +28,7 @@ add_plugin ( cache SOURCES cache.h cache.c LINK_ELEKTRA elektra-kdb - ADD_TEST TEST_README - COMPONENT libelektra4) + ADD_TEST TEST_README COMPONENT libelektra4) if (CACHE_DEPENDENCIES_OK AND BUILD_SHARED) add_dependencies (elektra-cache elektra-resolver_fm_hpu_b elektra-mmapstorage) diff --git a/src/plugins/ccode/CMakeLists.txt b/src/plugins/ccode/CMakeLists.txt index 6c3cbf28ff0..f4c227bbab5 100644 --- a/src/plugins/ccode/CMakeLists.txt +++ b/src/plugins/ccode/CMakeLists.txt @@ -2,5 +2,4 @@ add_plugin ( ccode CPP ADD_TEST CPP_TEST SOURCES ccode.hpp ccode.cpp coder.hpp coder.cpp TEST_README - TEST_REQUIRED_PLUGINS tcl base64 - COMPONENT libelektra4-extra) + TEST_REQUIRED_PLUGINS tcl base64 COMPONENT libelektra4-extra) diff --git a/src/plugins/conditionals/CMakeLists.txt b/src/plugins/conditionals/CMakeLists.txt index f8ff928413a..b77fb9ee9f9 100644 --- a/src/plugins/conditionals/CMakeLists.txt +++ b/src/plugins/conditionals/CMakeLists.txt @@ -10,5 +10,4 @@ add_plugin ( SOURCES conditionals.h conditionals.c LINK_ELEKTRA elektra-meta ADD_TEST TEST_README - TEST_REQUIRED_PLUGINS dump ini ni - COMPONENT libelektra4-extra) + TEST_REQUIRED_PLUGINS dump ini ni COMPONENT libelektra4-extra) diff --git a/src/plugins/constants/CMakeLists.txt b/src/plugins/constants/CMakeLists.txt index bc6ad810c68..2b08ecb7de4 100644 --- a/src/plugins/constants/CMakeLists.txt +++ b/src/plugins/constants/CMakeLists.txt @@ -10,5 +10,4 @@ add_plugin ( constants SOURCES ${CMAKE_CURRENT_BINARY_DIR}/constants.c TEST_README - TEST_REQUIRED_PLUGINS noresolver - COMPONENT libelektra4) + TEST_REQUIRED_PLUGINS noresolver COMPONENT libelektra4) diff --git a/src/plugins/crypto/CMakeLists.txt b/src/plugins/crypto/CMakeLists.txt index d2cb8ca1689..118831b7d6e 100644 --- a/src/plugins/crypto/CMakeLists.txt +++ b/src/plugins/crypto/CMakeLists.txt @@ -23,8 +23,7 @@ add_plugin ( INCLUDE_DIRECTORIES ${Libgcrypt_INCLUDE_DIRS} LINK_LIBRARIES ${Libgcrypt_LIBRARIES} LINK_ELEKTRA elektra-invoke - ADD_TEST - COMPONENT libelektra4-crypto) + ADD_TEST COMPONENT libelektra4-crypto) if (ADDTESTING_PHASE) set_property (TEST "testmod_crypto" PROPERTY LABELS memleak) diff --git a/src/plugins/csvstorage/CMakeLists.txt b/src/plugins/csvstorage/CMakeLists.txt index d2326ed6270..80842714695 100644 --- a/src/plugins/csvstorage/CMakeLists.txt +++ b/src/plugins/csvstorage/CMakeLists.txt @@ -7,5 +7,4 @@ add_plugin ( SOURCES csvstorage.h csvstorage.c LINK_ELEKTRA elektra-ease elektra-kdb ADD_TEST INSTALL_TEST_DATA TEST_README - TEST_REQUIRED_PLUGINS directoryvalue - COMPONENT libelektra4) \ No newline at end of file + TEST_REQUIRED_PLUGINS directoryvalue COMPONENT libelektra4) diff --git a/src/plugins/curlget/CMakeLists.txt b/src/plugins/curlget/CMakeLists.txt index 787bef72472..6c32f8de92f 100644 --- a/src/plugins/curlget/CMakeLists.txt +++ b/src/plugins/curlget/CMakeLists.txt @@ -22,5 +22,4 @@ add_plugin ( SOURCES curlget.h curlget.c LINK_ELEKTRA elektra-invoke INCLUDE_DIRECTORIES ${CURLGET_INCLUDE_DIRS} - LINK_LIBRARIES ${CURLGET_LIBRARY_DIRS} - COMPONENT libelektra4-curl) + LINK_LIBRARIES ${CURLGET_LIBRARY_DIRS} COMPONENT libelektra4-curl) diff --git a/src/plugins/date/CMakeLists.txt b/src/plugins/date/CMakeLists.txt index c1fdeb63716..4011c70977c 100644 --- a/src/plugins/date/CMakeLists.txt +++ b/src/plugins/date/CMakeLists.txt @@ -11,5 +11,4 @@ endif (DEPENDENCY_PHASE) add_plugin ( date SOURCES date.h date.c - ADD_TEST - COMPONENT libelektra4-extra) + ADD_TEST COMPONENT libelektra4-extra) diff --git a/src/plugins/dbus/CMakeLists.txt b/src/plugins/dbus/CMakeLists.txt index 2d0f73030ce..4fcf13745aa 100644 --- a/src/plugins/dbus/CMakeLists.txt +++ b/src/plugins/dbus/CMakeLists.txt @@ -10,8 +10,7 @@ add_plugin ( dbus SOURCES dbus.h dbus.c sendmessage.c INCLUDE_DIRECTORIES ${DBUS_INCLUDE_DIR} ${DBUS_ARCH_INCLUDE_DIR} - LINK_LIBRARIES ${DBUS_LIBRARIES} - COMPONENT libelektra4-dbus) + LINK_LIBRARIES ${DBUS_LIBRARIES} COMPONENT libelektra4-dbus) add_plugintest (dbus testmod_dbus.c receivemessage.c INCLUDE_DIRECTORIES ${DBUS_INCLUDE_DIR} ${DBUS_ARCH_INCLUDE_DIR}) diff --git a/src/plugins/dbusrecv/CMakeLists.txt b/src/plugins/dbusrecv/CMakeLists.txt index 01f0999b7b2..8d66bc10cc5 100644 --- a/src/plugins/dbusrecv/CMakeLists.txt +++ b/src/plugins/dbusrecv/CMakeLists.txt @@ -14,8 +14,7 @@ add_plugin ( OBJECT_SOURCES $ INCLUDE_DIRECTORIES ${DBUS_INCLUDE_DIR} ${DBUS_ARCH_INCLUDE_DIR} LINK_ELEKTRA elektra-io elektra-invoke - LINK_LIBRARIES ${DBUS_LIBRARIES} - COMPONENT libelektra4-dbus) + LINK_LIBRARIES ${DBUS_LIBRARIES} COMPONENT libelektra4-dbus) set (NOT_INCLUDED "") plugin_check_if_included ("${PLUGIN_SHORT_NAME}") @@ -52,8 +51,10 @@ if (ADDTESTING_PHASE) dbusrecv TEST_LINK_LIBRARIES ${STATIC_LIBRARIES} TEST_LINK_ELEKTRA elektra-io-uv - INCLUDE_SYSTEM_DIRECTORIES ${libuv_INCLUDE_DIRS} - COMPONENT libelektra4-dbus) + INCLUDE_SYSTEM_DIRECTORIES + ${libuv_INCLUDE_DIRS} + COMPONENT + libelektra4-dbus) # add sources manually because add_plugintest does not support generator expressions for additional source files if (BUILD_FULL OR BUILD_STATIC) diff --git a/src/plugins/directoryvalue/CMakeLists.txt b/src/plugins/directoryvalue/CMakeLists.txt index 7d4e7287756..29b589f0d9f 100644 --- a/src/plugins/directoryvalue/CMakeLists.txt +++ b/src/plugins/directoryvalue/CMakeLists.txt @@ -1,5 +1,4 @@ add_plugin ( directoryvalue CPP ADD_TEST CPP_TEST TEST_README SOURCES directoryvalue.hpp directoryvalue.cpp directoryvalue_delegate.hpp directoryvalue_delegate.cpp log.hpp - LINK_ELEKTRA elektra-ease - COMPONENT libelektra4) \ No newline at end of file + LINK_ELEKTRA elektra-ease COMPONENT libelektra4) diff --git a/src/plugins/doc/CMakeLists.txt b/src/plugins/doc/CMakeLists.txt index f5155c139ba..2f81c81f877 100644 --- a/src/plugins/doc/CMakeLists.txt +++ b/src/plugins/doc/CMakeLists.txt @@ -3,5 +3,4 @@ include (LibAddMacros) add_plugin ( doc SOURCES doc.h doc.c - LINK_ELEKTRA elektra-kdb - COMPONENT libelektra4-experimental) + LINK_ELEKTRA elektra-kdb COMPONENT libelektra4-experimental) diff --git a/src/plugins/dump/CMakeLists.txt b/src/plugins/dump/CMakeLists.txt index 1fbf745cf96..bdde7780dc8 100644 --- a/src/plugins/dump/CMakeLists.txt +++ b/src/plugins/dump/CMakeLists.txt @@ -1,7 +1,6 @@ include (LibAddPlugin) -add_plugin (dump SOURCES dump.hpp dump.cpp - COMPONENT libelektra4) +add_plugin (dump SOURCES dump.hpp dump.cpp COMPONENT libelektra4) if (ADDTESTING_PHASE) add_plugintest (dump INSTALL_TEST_DATA INCLUDE_DIRECTORIES ${CMAKE_CURRENT_BINARY_DIR}) diff --git a/src/plugins/fcrypt/CMakeLists.txt b/src/plugins/fcrypt/CMakeLists.txt index 897aa6c28ad..d4aee478ad7 100644 --- a/src/plugins/fcrypt/CMakeLists.txt +++ b/src/plugins/fcrypt/CMakeLists.txt @@ -4,8 +4,7 @@ add_plugin ( fcrypt SOURCES ../crypto/gpg.h ../crypto/gpg.c fcrypt.h fcrypt.c INCLUDE_DIRECTORIES ${CMAKE_SOURCE_DIR}/src/plugins/crypto/ - ADD_TEST - COMPONENT libelektra4-experimental) + ADD_TEST COMPONENT libelektra4-experimental) if (ADDTESTING_PHASE) set_property (TEST "testmod_fcrypt" PROPERTY LABELS memleak) diff --git a/src/plugins/file/CMakeLists.txt b/src/plugins/file/CMakeLists.txt index 42ce6f8d6ac..42630b145ec 100644 --- a/src/plugins/file/CMakeLists.txt +++ b/src/plugins/file/CMakeLists.txt @@ -3,5 +3,4 @@ include (LibAddMacros) add_plugin ( file SOURCES file.h file.c - ADD_TEST INSTALL_TEST_DATA TEST_README - COMPONENT libelektra4-experimental) + ADD_TEST INSTALL_TEST_DATA TEST_README COMPONENT libelektra4-experimental) diff --git a/src/plugins/filecheck/CMakeLists.txt b/src/plugins/filecheck/CMakeLists.txt index 4dfecf62ab7..482ab989d9f 100644 --- a/src/plugins/filecheck/CMakeLists.txt +++ b/src/plugins/filecheck/CMakeLists.txt @@ -17,5 +17,4 @@ add_plugin ( SOURCES filecheck.h filecheck.c INCLUDE_DIRECTORIES ${Iconv_INCLUDE_DIRS} LINK_LIBRARIES ${Iconv_LIBRARIES} - ADD_TEST INSTALL_TEST_DATA - COMPONENT libelektra4-extra) + ADD_TEST INSTALL_TEST_DATA COMPONENT libelektra4-extra) diff --git a/src/plugins/fstab/CMakeLists.txt b/src/plugins/fstab/CMakeLists.txt index f3bc5a88932..58968363e4c 100644 --- a/src/plugins/fstab/CMakeLists.txt +++ b/src/plugins/fstab/CMakeLists.txt @@ -10,5 +10,4 @@ add_plugin ( fstab SOURCES fstab.c fstab.h LINK_ELEKTRA elektra-meta - ADD_TEST INSTALL_TEST_DATA - COMPONENT libelektra4-extra) + ADD_TEST INSTALL_TEST_DATA COMPONENT libelektra4-extra) diff --git a/src/plugins/glob/CMakeLists.txt b/src/plugins/glob/CMakeLists.txt index a4481b74d12..e06b60b7ede 100644 --- a/src/plugins/glob/CMakeLists.txt +++ b/src/plugins/glob/CMakeLists.txt @@ -3,5 +3,4 @@ include (LibAddMacros) add_plugin ( glob SOURCES glob.h glob.c - ADD_TEST - COMPONENT libelektra4) + ADD_TEST COMPONENT libelektra4) diff --git a/src/plugins/gopts/CMakeLists.txt b/src/plugins/gopts/CMakeLists.txt index 32ee0b46bc0..7920f486d73 100644 --- a/src/plugins/gopts/CMakeLists.txt +++ b/src/plugins/gopts/CMakeLists.txt @@ -33,8 +33,7 @@ if (gopts_source) gopts SOURCES gopts.h gopts.c ${gopts_source} LINK_ELEKTRA elektra-opts - TEST_README - COMPONENT libelektra4-experimental) + TEST_README COMPONENT libelektra4-experimental) if (ADDTESTING_PHASE) set (TEST_SOURCES $ ${ARG_OBJECT_SOURCES}) diff --git a/src/plugins/gpgme/CMakeLists.txt b/src/plugins/gpgme/CMakeLists.txt index 52520bb0a7e..bf0cd33aff9 100644 --- a/src/plugins/gpgme/CMakeLists.txt +++ b/src/plugins/gpgme/CMakeLists.txt @@ -16,8 +16,7 @@ add_plugin ( SOURCES ${GPGME_SOURCE_FILES} INCLUDE_DIRECTORIES ${LIBGPGME_INCLUDE_DIRS} LINK_LIBRARIES ${LIBGPGME_LIBRARIES} - ADD_TEST - COMPONENT libelektra4-experimental) + ADD_TEST COMPONENT libelektra4-experimental) if (ADDTESTING_PHASE) set_property (TEST "testmod_gpgme" PROPERTY LABELS memleak) diff --git a/src/plugins/hexcode/CMakeLists.txt b/src/plugins/hexcode/CMakeLists.txt index 7f5cd454f86..ea86dabd32c 100644 --- a/src/plugins/hexcode/CMakeLists.txt +++ b/src/plugins/hexcode/CMakeLists.txt @@ -3,5 +3,4 @@ include (LibAddMacros) add_plugin ( hexcode SOURCES hexcode.h hexcode.c - ADD_TEST - COMPONENT libelektra4-extra) + ADD_TEST COMPONENT libelektra4-extra) diff --git a/src/plugins/hexnumber/CMakeLists.txt b/src/plugins/hexnumber/CMakeLists.txt index f0987abd7b4..9a67b44dc66 100644 --- a/src/plugins/hexnumber/CMakeLists.txt +++ b/src/plugins/hexnumber/CMakeLists.txt @@ -4,5 +4,4 @@ add_plugin ( hexnumber SOURCES hexnumber.h hexnumber.c LINK_ELEKTRA elektra-ease - ADD_TEST TEST_README - COMPONENT libelektra4-extra) + ADD_TEST TEST_README COMPONENT libelektra4-extra) diff --git a/src/plugins/hosts/CMakeLists.txt b/src/plugins/hosts/CMakeLists.txt index 308b1b05f62..e4f23a868d5 100644 --- a/src/plugins/hosts/CMakeLists.txt +++ b/src/plugins/hosts/CMakeLists.txt @@ -6,5 +6,4 @@ add_plugin ( LINK_ELEKTRA elektra-ease elektra-meta ADD_TEST TEST_README TEST_REQUIRED_PLUGINS network - INSTALL_TEST_DATA - COMPONENT libelektra4) + INSTALL_TEST_DATA COMPONENT libelektra4) diff --git a/src/plugins/iconv/CMakeLists.txt b/src/plugins/iconv/CMakeLists.txt index 13d8f20f98d..315972046d6 100644 --- a/src/plugins/iconv/CMakeLists.txt +++ b/src/plugins/iconv/CMakeLists.txt @@ -16,5 +16,4 @@ add_plugin ( SOURCES conv.h iconv.c INCLUDE_DIRECTORIES ${Iconv_INCLUDE_DIRS} LINK_LIBRARIES ${Iconv_LIBRARIES} - ADD_TEST TEST_README - COMPONENT libelektra4-extra) + ADD_TEST TEST_README COMPONENT libelektra4-extra) diff --git a/src/plugins/internalnotification/CMakeLists.txt b/src/plugins/internalnotification/CMakeLists.txt index 0beb3435a9e..7bbd1f5db25 100644 --- a/src/plugins/internalnotification/CMakeLists.txt +++ b/src/plugins/internalnotification/CMakeLists.txt @@ -4,5 +4,4 @@ add_plugin ( internalnotification SOURCES internalnotification.h internalnotification.c ADD_TEST - LINK_ELEKTRA elektra-kdb - COMPONENT libelektra4) + LINK_ELEKTRA elektra-kdb COMPONENT libelektra4) diff --git a/src/plugins/ipaddr/CMakeLists.txt b/src/plugins/ipaddr/CMakeLists.txt index 4db64b149c8..526b40dd1d9 100644 --- a/src/plugins/ipaddr/CMakeLists.txt +++ b/src/plugins/ipaddr/CMakeLists.txt @@ -3,5 +3,4 @@ include (LibAddMacros) add_plugin ( ipaddr SOURCES ipaddr.h ipaddr.c test_ipaddr.h - ADD_TEST TEST_README - COMPONENT libelektra4-experimental) + ADD_TEST TEST_README COMPONENT libelektra4-experimental) diff --git a/src/plugins/iterate/CMakeLists.txt b/src/plugins/iterate/CMakeLists.txt index 01623aa5b2c..8311fad250d 100644 --- a/src/plugins/iterate/CMakeLists.txt +++ b/src/plugins/iterate/CMakeLists.txt @@ -3,5 +3,4 @@ include (LibAddMacros) add_plugin ( iterate SOURCES iterate.h iterate.c - ADD_TEST - COMPONENT libelektra4-experimental) + ADD_TEST COMPONENT libelektra4-experimental) diff --git a/src/plugins/journald/CMakeLists.txt b/src/plugins/journald/CMakeLists.txt index 68f691f23cf..1395524d7c0 100644 --- a/src/plugins/journald/CMakeLists.txt +++ b/src/plugins/journald/CMakeLists.txt @@ -12,5 +12,4 @@ add_plugin ( journald SOURCES journald.h journald.c INCLUDE_DIRECTORIES ${LIBSYSTEMD_JOURNAL_INCLUDE_DIR} - LINK_LIBRARIES ${LIBSYSTEMD_JOURNAL_LIBRARIES} - COMPONENT libelektra4-journald) + LINK_LIBRARIES ${LIBSYSTEMD_JOURNAL_LIBRARIES} COMPONENT libelektra4-journald) diff --git a/src/plugins/kconfig/CMakeLists.txt b/src/plugins/kconfig/CMakeLists.txt index 98890b16e7e..2093138b236 100644 --- a/src/plugins/kconfig/CMakeLists.txt +++ b/src/plugins/kconfig/CMakeLists.txt @@ -8,4 +8,5 @@ add_plugin ( kconfig_parser_exception.cpp kconfig_serializer.cpp file_utility.cpp - COMPONENT libelektra4) + COMPONENT + libelektra4) diff --git a/src/plugins/keytometa/CMakeLists.txt b/src/plugins/keytometa/CMakeLists.txt index 26df3589185..db9b7895c37 100644 --- a/src/plugins/keytometa/CMakeLists.txt +++ b/src/plugins/keytometa/CMakeLists.txt @@ -4,5 +4,4 @@ add_plugin ( keytometa SOURCES keytometa.h keytometa.c LINK_ELEKTRA elektra-meta - ADD_TEST - COMPONENT libelektra4-extra) + ADD_TEST COMPONENT libelektra4-extra) diff --git a/src/plugins/line/CMakeLists.txt b/src/plugins/line/CMakeLists.txt index a74c6a64358..96742efade6 100644 --- a/src/plugins/line/CMakeLists.txt +++ b/src/plugins/line/CMakeLists.txt @@ -10,8 +10,7 @@ add_plugin ( line SOURCES line.h line.c LINK_ELEKTRA elektra-ease - INSTALL_TEST_DATA TEST_README - COMPONENT libelektra4) + INSTALL_TEST_DATA TEST_README COMPONENT libelektra4) if (ADDTESTING_PHASE) add_plugintest (line INSTALL_TEST_DATA) diff --git a/src/plugins/lineendings/CMakeLists.txt b/src/plugins/lineendings/CMakeLists.txt index ca4d4fb8941..b18df047b45 100644 --- a/src/plugins/lineendings/CMakeLists.txt +++ b/src/plugins/lineendings/CMakeLists.txt @@ -5,5 +5,4 @@ set_source_files_properties (lineendings.c PROPERTIES COMPILE_FLAGS "-Wno-unused add_plugin ( lineendings SOURCES lineendings.h lineendings.c - ADD_TEST INSTALL_TEST_DATA - COMPONENT libelektra4-extra) + ADD_TEST INSTALL_TEST_DATA COMPONENT libelektra4-extra) diff --git a/src/plugins/list/CMakeLists.txt b/src/plugins/list/CMakeLists.txt index 8a502540830..f31fd1ff00d 100644 --- a/src/plugins/list/CMakeLists.txt +++ b/src/plugins/list/CMakeLists.txt @@ -4,5 +4,4 @@ add_plugin ( list SOURCES list.h list.c LINK_ELEKTRA elektra-kdb elektra-invoke elektra-ease - ADD_TEST - COMPONENT libelektra4) + ADD_TEST COMPONENT libelektra4) diff --git a/src/plugins/lua/CMakeLists.txt b/src/plugins/lua/CMakeLists.txt index 8d82dd2ce4e..14ce0dfab5a 100644 --- a/src/plugins/lua/CMakeLists.txt +++ b/src/plugins/lua/CMakeLists.txt @@ -31,8 +31,7 @@ add_plugin ( INCLUDE_DIRECTORIES ${LUA_INCLUDE_DIR} LINK_LIBRARIES ${LUA_LIBRARIES} COMPILE_DEFINITIONS SWIG_TYPE_TABLE=kdb - INSTALL_TEST_DATA - COMPONENT libelektra4-lua) + INSTALL_TEST_DATA COMPONENT libelektra4-lua) if (ADDTESTING_PHASE) diff --git a/src/plugins/macaddr/CMakeLists.txt b/src/plugins/macaddr/CMakeLists.txt index 3617ae64150..fc69e853bdb 100644 --- a/src/plugins/macaddr/CMakeLists.txt +++ b/src/plugins/macaddr/CMakeLists.txt @@ -3,5 +3,4 @@ include (LibAddMacros) add_plugin ( macaddr SOURCES macaddr.h macaddr.c - ADD_TEST TEST_README - COMPONENT libelektra4-extra) + ADD_TEST TEST_README COMPONENT libelektra4-extra) diff --git a/src/plugins/mathcheck/CMakeLists.txt b/src/plugins/mathcheck/CMakeLists.txt index 26ba662bbb9..2f4bb3015c2 100644 --- a/src/plugins/mathcheck/CMakeLists.txt +++ b/src/plugins/mathcheck/CMakeLists.txt @@ -3,6 +3,5 @@ include (LibAddMacros) add_plugin ( mathcheck SOURCES mathcheck.h mathcheck.c floathelper.h floathelper.c - TEST_README - COMPONENT libelektra4-extra) + TEST_README COMPONENT libelektra4-extra) add_plugintest (mathcheck) diff --git a/src/plugins/mini/CMakeLists.txt b/src/plugins/mini/CMakeLists.txt index ae044b15c2f..3a5466d1384 100644 --- a/src/plugins/mini/CMakeLists.txt +++ b/src/plugins/mini/CMakeLists.txt @@ -5,5 +5,4 @@ add_plugin ( SOURCES mini.h mini.c LINK_ELEKTRA elektra-ease elektra-utility ADD_TEST INSTALL_TEST_DATA TEST_README - TEST_REQUIRED_PLUGINS ccode - COMPONENT libelektra4) + TEST_REQUIRED_PLUGINS ccode COMPONENT libelektra4) diff --git a/src/plugins/mmapstorage/CMakeLists.txt b/src/plugins/mmapstorage/CMakeLists.txt index 2a881bc95fa..be73b14c2d9 100644 --- a/src/plugins/mmapstorage/CMakeLists.txt +++ b/src/plugins/mmapstorage/CMakeLists.txt @@ -15,8 +15,7 @@ add_plugin ( INCLUDE_DIRECTORIES ${ZLIB_INCLUDE_DIRS} LINK_LIBRARIES ${ZLIB_LIBRARIES} LINK_ELEKTRA elektra-core - ADD_TEST - COMPONENT libelektra4-extra + ADD_TEST COMPONENT libelektra4-extra COMPILE_DEFINITIONS ELEKTRA_VARIANT=crc ELEKTRA_MMAP_CHECKSUM) # Plugin variant: mmapstorage @@ -24,5 +23,4 @@ add_plugin ( mmapstorage SOURCES ${MMAPSTORAGE_SOURCES} LINK_ELEKTRA elektra-core - ADD_TEST TEST_README - COMPONENT libelektra4) + ADD_TEST TEST_README COMPONENT libelektra4) diff --git a/src/plugins/mozprefs/CMakeLists.txt b/src/plugins/mozprefs/CMakeLists.txt index 3869ad7dfec..1215d257620 100644 --- a/src/plugins/mozprefs/CMakeLists.txt +++ b/src/plugins/mozprefs/CMakeLists.txt @@ -4,5 +4,4 @@ add_plugin ( mozprefs SOURCES mozprefs.h mozprefs.c LINK_ELEKTRA elektra-utility - ADD_TEST INSTALL_TEST_DATA TEST_README - COMPONENT libelektra4-extra) + ADD_TEST INSTALL_TEST_DATA TEST_README COMPONENT libelektra4-extra) diff --git a/src/plugins/multifile/CMakeLists.txt b/src/plugins/multifile/CMakeLists.txt index 50051cfdd4a..7c4b2adfd82 100644 --- a/src/plugins/multifile/CMakeLists.txt +++ b/src/plugins/multifile/CMakeLists.txt @@ -5,5 +5,4 @@ add_plugin ( SOURCES multifile.h multifile.c LINK_ELEKTRA elektra-kdb elektra-invoke TEST_README - TEST_REQUIRED_PLUGINS toml - COMPONENT libelektra4) + TEST_REQUIRED_PLUGINS toml COMPONENT libelektra4) diff --git a/src/plugins/network/CMakeLists.txt b/src/plugins/network/CMakeLists.txt index ceba1731e82..3753feee04d 100644 --- a/src/plugins/network/CMakeLists.txt +++ b/src/plugins/network/CMakeLists.txt @@ -3,7 +3,6 @@ include (LibAddMacros) add_plugin ( network SOURCES network.h network.c - TEST_README - COMPONENT libelektra4) + TEST_README COMPONENT libelektra4) add_plugintest (network ../ipaddr/test_ipaddr.h) diff --git a/src/plugins/ni/CMakeLists.txt b/src/plugins/ni/CMakeLists.txt index e68486d5f90..0f3db0e72c4 100644 --- a/src/plugins/ni/CMakeLists.txt +++ b/src/plugins/ni/CMakeLists.txt @@ -9,8 +9,7 @@ add_plugin ( SOURCES ni.h ni.c ${NI_FILES} INCLUDE_DIRECTORIES ${NI}/include ${NI}/src/include LINK_ELEKTRA elektra-ease - ADD_TEST TEST_README - COMPONENT libelektra4) + ADD_TEST TEST_README COMPONENT libelektra4) if (ADDTESTING_PHASE) file (GLOB NI_INI_FILES ${NI}/src/tests/*.ini) diff --git a/src/plugins/noresolver/CMakeLists.txt b/src/plugins/noresolver/CMakeLists.txt index 202cbc7f6ec..b1b76a7e349 100644 --- a/src/plugins/noresolver/CMakeLists.txt +++ b/src/plugins/noresolver/CMakeLists.txt @@ -1,4 +1,3 @@ include (LibAddMacros) -add_plugin (noresolver SOURCES noresolver.h noresolver.c - COMPONENT libelektra4) +add_plugin (noresolver SOURCES noresolver.h noresolver.c COMPONENT libelektra4) diff --git a/src/plugins/passwd/CMakeLists.txt b/src/plugins/passwd/CMakeLists.txt index f5334ab3d55..368a7f2b089 100644 --- a/src/plugins/passwd/CMakeLists.txt +++ b/src/plugins/passwd/CMakeLists.txt @@ -27,5 +27,4 @@ add_plugin ( passwd SOURCES passwd.h passwd.c COMPILE_DEFINITIONS ${PASSWD_COMPILE_DEFS} - ADD_TEST INSTALL_TEST_DATA - COMPONENT libelektra4-experimental) + ADD_TEST INSTALL_TEST_DATA COMPONENT libelektra4-experimental) diff --git a/src/plugins/path/CMakeLists.txt b/src/plugins/path/CMakeLists.txt index 818484f9b00..b402f83ea31 100644 --- a/src/plugins/path/CMakeLists.txt +++ b/src/plugins/path/CMakeLists.txt @@ -42,5 +42,4 @@ endif () add_plugin ( path SOURCES path.h path.c - TEST_README - COMPONENT libelektra4-extra) + TEST_README COMPONENT libelektra4-extra) diff --git a/src/plugins/process/CMakeLists.txt b/src/plugins/process/CMakeLists.txt index 9232e805b7f..f90ec5b1dbe 100644 --- a/src/plugins/process/CMakeLists.txt +++ b/src/plugins/process/CMakeLists.txt @@ -14,8 +14,7 @@ if (PLUGINPROCESS_FOUND) SOURCES process.h process.c ADD_TEST TEST_README TEST_REQUIRED_PLUGINS "dump" - LINK_ELEKTRA elektra-pluginprocess elektra-invoke - COMPONENT libelektra4-experimental) + LINK_ELEKTRA elektra-pluginprocess elektra-invoke COMPONENT libelektra4-experimental) else (PLUGINPROCESS_FOUND) remove_plugin (process "${PLUGINPROCESS_NOTFOUND_INFO}, pluginprocess library excluded, thus also excluding the process plugin") endif (PLUGINPROCESS_FOUND) diff --git a/src/plugins/profile/CMakeLists.txt b/src/plugins/profile/CMakeLists.txt index f760418c9a9..9b110f848a7 100644 --- a/src/plugins/profile/CMakeLists.txt +++ b/src/plugins/profile/CMakeLists.txt @@ -3,5 +3,4 @@ include (LibAddMacros) add_plugin ( profile SOURCES profile.h profile.c - LINK_ELEKTRA elektra-ease - COMPONENT libelektra4-extra) + LINK_ELEKTRA elektra-ease COMPONENT libelektra4-extra) diff --git a/src/plugins/python/CMakeLists.txt b/src/plugins/python/CMakeLists.txt index 883ae05de68..8909912f915 100644 --- a/src/plugins/python/CMakeLists.txt +++ b/src/plugins/python/CMakeLists.txt @@ -52,7 +52,7 @@ add_plugin ( LINK_LIBRARIES ${PYTHON_LIBRARIES} LINK_ELEKTRA elektra-pluginprocess COMPILE_DEFINITIONS SWIG_TYPE_TABLE=kdb SWIG_RUNTIME=\"runtime.h\" PYTHON_PLUGIN_NAME=python PYTHON_PLUGIN_SYMBOL_NAME=Python - COMPONENT libelektra4-python) + COMPONENT libelektra4-python) if (ADDTESTING_PHASE) # bindings are required for tests @@ -65,7 +65,10 @@ if (ADDTESTING_PHASE) if (INSTALL_TESTING) - install (DIRECTORY ${CMAKE_SOURCE_DIR}/src/plugins/python/python/ DESTINATION "${TARGET_TEST_DATA_FOLDER}/python" COMPONENT elektra-tests) + install ( + DIRECTORY ${CMAKE_SOURCE_DIR}/src/plugins/python/python/ + DESTINATION "${TARGET_TEST_DATA_FOLDER}/python" + COMPONENT elektra-tests) endif () else () diff --git a/src/plugins/quickdump/CMakeLists.txt b/src/plugins/quickdump/CMakeLists.txt index c3301d85b8f..59d2f344758 100644 --- a/src/plugins/quickdump/CMakeLists.txt +++ b/src/plugins/quickdump/CMakeLists.txt @@ -3,8 +3,7 @@ include (LibAddMacros) add_plugin ( quickdump SOURCES quickdump.h quickdump.c - TEST_README - COMPONENT libelektra4) + TEST_README COMPONENT libelektra4) if (ADDTESTING_PHASE) add_plugintest (quickdump INSTALL_TEST_DATA INCLUDE_DIRECTORIES ${CMAKE_CURRENT_BINARY_DIR}) diff --git a/src/plugins/range/CMakeLists.txt b/src/plugins/range/CMakeLists.txt index 28b8d1d5863..ddcf141acae 100644 --- a/src/plugins/range/CMakeLists.txt +++ b/src/plugins/range/CMakeLists.txt @@ -8,8 +8,7 @@ add_plugin ( range SOURCES range.h range.c LINK_LIBRARIES m - ADD_TEST TEST_README - COMPONENT libelektra4-experimental) + ADD_TEST TEST_README COMPONENT libelektra4-experimental) if (ADDTESTING_PHASE) if (CMAKE_C_COMPILER_ID STREQUAL "Clang" OR CMAKE_CXX_COMPILER_ID STREQUAL "Clang") diff --git a/src/plugins/reference/CMakeLists.txt b/src/plugins/reference/CMakeLists.txt index 5b065bdc3a1..77d58d76d8d 100644 --- a/src/plugins/reference/CMakeLists.txt +++ b/src/plugins/reference/CMakeLists.txt @@ -5,5 +5,4 @@ add_plugin ( SOURCES reference.h reference.c referencegraph.c referencegraph.h LINK_ELEKTRA elektra-ease elektra-globbing ADD_TEST TEST_README - TEST_REQUIRED_PLUGINS dump sync - COMPONENT libelektra4-experimental) + TEST_REQUIRED_PLUGINS dump sync COMPONENT libelektra4-experimental) diff --git a/src/plugins/rename/CMakeLists.txt b/src/plugins/rename/CMakeLists.txt index f248187e04d..57c3dc737b7 100644 --- a/src/plugins/rename/CMakeLists.txt +++ b/src/plugins/rename/CMakeLists.txt @@ -2,5 +2,4 @@ add_plugin ( rename SOURCES rename.h rename.c ADD_TEST TEST_README - TEST_REQUIRED_PLUGINS mini - COMPONENT libelektra4) + TEST_REQUIRED_PLUGINS mini COMPONENT libelektra4) diff --git a/src/plugins/resolver/CMakeLists.txt b/src/plugins/resolver/CMakeLists.txt index e7bf317e86a..e7182f05747 100644 --- a/src/plugins/resolver/CMakeLists.txt +++ b/src/plugins/resolver/CMakeLists.txt @@ -63,19 +63,23 @@ foreach (plugin ${RESOLVERS}) set (HAS_COMPONENT "") if (plugin MATCHES "resolver_fm_hpu_b") set (HAS_COMPONENT "libelektra4") - else() + else () set (HAS_COMPONENT "libelektra4-extra") - endif() + endif () add_plugin ( ${plugin} SOURCES ${SOURCES} LINK_LIBRARIES ${FURTHER_LIBRARIES} COMPILE_DEFINITIONS - ELEKTRA_VARIANT_BASE=\"${variant_base}\" ELEKTRA_VARIANT_USER=\"${variant_user}\" - ELEKTRA_VARIANT_SYSTEM=\"${variant_system}\" ELEKTRA_VARIANT=${variant} ELEKTRA_PLUGIN_NAME=\"${plugin}\" + ELEKTRA_VARIANT_BASE=\"${variant_base}\" + ELEKTRA_VARIANT_USER=\"${variant_user}\" + ELEKTRA_VARIANT_SYSTEM=\"${variant_system}\" + ELEKTRA_VARIANT=${variant} + ELEKTRA_PLUGIN_NAME=\"${plugin}\" ${FURTHER_DEFINITIONS} - COMPONENT "${HAS_COMPONENT}") + COMPONENT + "${HAS_COMPONENT}") if (variant MATCHES "fm_hpu_b") add_plugintest ( diff --git a/src/plugins/rgbcolor/CMakeLists.txt b/src/plugins/rgbcolor/CMakeLists.txt index 7f6557530d4..68f5f55f65f 100644 --- a/src/plugins/rgbcolor/CMakeLists.txt +++ b/src/plugins/rgbcolor/CMakeLists.txt @@ -3,5 +3,4 @@ include (LibAddMacros) add_plugin ( rgbcolor SOURCES rgbcolor.h rgbcolor.c - ADD_TEST TEST_README - COMPONENT libelektra4-extra) + ADD_TEST TEST_README COMPONENT libelektra4-extra) diff --git a/src/plugins/shell/CMakeLists.txt b/src/plugins/shell/CMakeLists.txt index 68f594e47c2..32938d7d3ed 100644 --- a/src/plugins/shell/CMakeLists.txt +++ b/src/plugins/shell/CMakeLists.txt @@ -1,4 +1,3 @@ include (LibAddMacros) -add_plugin (shell TEST_README SOURCES shell.h shell.c - COMPONENT libelektra4) +add_plugin (shell TEST_README SOURCES shell.h shell.c COMPONENT libelektra4) diff --git a/src/plugins/simpleini/CMakeLists.txt b/src/plugins/simpleini/CMakeLists.txt index 960075b277c..d9ddc08c299 100644 --- a/src/plugins/simpleini/CMakeLists.txt +++ b/src/plugins/simpleini/CMakeLists.txt @@ -7,8 +7,7 @@ if (HAVE_GLIBC) add_plugin ( simpleini SOURCES simpleini.h simpleini.c - LINK_ELEKTRA elektra-ease elektra-utility - COMPONENT libelektra4 + LINK_ELEKTRA elektra-ease elektra-utility COMPONENT libelektra4 ADD_TEST) else () remove_plugin (simpleini "simpleini needs glibc to work, use the mini plugin instead") diff --git a/src/plugins/spec/CMakeLists.txt b/src/plugins/spec/CMakeLists.txt index d78dbb85e65..46132161cfe 100644 --- a/src/plugins/spec/CMakeLists.txt +++ b/src/plugins/spec/CMakeLists.txt @@ -4,5 +4,4 @@ add_plugin ( spec SOURCES spec.h spec.c LINK_ELEKTRA elektra-ease elektra-meta elektra-globbing - ADD_TEST - COMPONENT libelektra4) + ADD_TEST COMPONENT libelektra4) diff --git a/src/plugins/specload/CMakeLists.txt b/src/plugins/specload/CMakeLists.txt index 27981dcf6de..e9a8f026535 100644 --- a/src/plugins/specload/CMakeLists.txt +++ b/src/plugins/specload/CMakeLists.txt @@ -4,8 +4,7 @@ add_plugin ( specload SOURCES specload.h specload.c LINK_ELEKTRA elektra-ease elektra-invoke - TEST_README - COMPONENT libelektra4) + TEST_README COMPONENT libelektra4) if (DEPENDENCY_PHASE AND BUILD_SHARED) add_dependencies (elektra-specload elektra-quickdump) diff --git a/src/plugins/sync/CMakeLists.txt b/src/plugins/sync/CMakeLists.txt index 67d7c7034c2..654bf413ed1 100644 --- a/src/plugins/sync/CMakeLists.txt +++ b/src/plugins/sync/CMakeLists.txt @@ -1,4 +1,3 @@ include (LibAddMacros) -add_plugin (sync SOURCES sync.h sync.c - COMPONENT libelektra4) +add_plugin (sync SOURCES sync.h sync.c COMPONENT libelektra4) diff --git a/src/plugins/template/CMakeLists.txt b/src/plugins/template/CMakeLists.txt index 4cff109b934..9c8959176f9 100644 --- a/src/plugins/template/CMakeLists.txt +++ b/src/plugins/template/CMakeLists.txt @@ -3,5 +3,4 @@ include (LibAddMacros) add_plugin ( template SOURCES template.h template.c - ADD_TEST TEST_README - COMPONENT libelektra4-experimental) + ADD_TEST TEST_README COMPONENT libelektra4-experimental) diff --git a/src/plugins/toml/CMakeLists.txt b/src/plugins/toml/CMakeLists.txt index a5ef343672d..4cff76707f1 100644 --- a/src/plugins/toml/CMakeLists.txt +++ b/src/plugins/toml/CMakeLists.txt @@ -150,5 +150,4 @@ add_plugin ( TEST_REQUIRED_PLUGINS type base64 LINK_ELEKTRA elektra-meta SOURCES ${SOURCE_FILES} - INCLUDE_DIRECTORIES ${CMAKE_CURRENT_SOURCE_DIR} - COMPONENT libelektra4) + INCLUDE_DIRECTORIES ${CMAKE_CURRENT_SOURCE_DIR} COMPONENT libelektra4) diff --git a/src/plugins/type/CMakeLists.txt b/src/plugins/type/CMakeLists.txt index 41ef105de9b..ca4958ab7ac 100644 --- a/src/plugins/type/CMakeLists.txt +++ b/src/plugins/type/CMakeLists.txt @@ -2,5 +2,4 @@ add_plugin ( type SOURCES type.h type.c types.h types.c LINK_ELEKTRA elektra-meta elektra-ease - ADD_TEST TEST_README - COMPONENT libelektra4) + ADD_TEST TEST_README COMPONENT libelektra4) diff --git a/src/plugins/uname/CMakeLists.txt b/src/plugins/uname/CMakeLists.txt index fa8265be35d..51f5348fc5a 100644 --- a/src/plugins/uname/CMakeLists.txt +++ b/src/plugins/uname/CMakeLists.txt @@ -12,5 +12,4 @@ add_plugin ( uname SOURCES uname.h uname.c ADD_TEST TEST_README - TEST_REQUIRED_PLUGINS noresolver - COMPONENT libelektra4-extra) + TEST_REQUIRED_PLUGINS noresolver COMPONENT libelektra4-extra) diff --git a/src/plugins/unit/CMakeLists.txt b/src/plugins/unit/CMakeLists.txt index cd0b17c37de..e2d959dc33d 100644 --- a/src/plugins/unit/CMakeLists.txt +++ b/src/plugins/unit/CMakeLists.txt @@ -3,5 +3,4 @@ include (LibAddMacros) add_plugin ( unit SOURCES unit.h unit.c - ADD_TEST TEST_README - COMPONENT libelektra4-extra) + ADD_TEST TEST_README COMPONENT libelektra4-extra) diff --git a/src/plugins/validation/CMakeLists.txt b/src/plugins/validation/CMakeLists.txt index 49dac2c4b57..b5b47703293 100644 --- a/src/plugins/validation/CMakeLists.txt +++ b/src/plugins/validation/CMakeLists.txt @@ -3,5 +3,4 @@ include (LibAddMacros) add_plugin ( validation SOURCES validation.h validation.c lookupre.c - ADD_TEST - COMPONENT libelektra4) + ADD_TEST COMPONENT libelektra4) diff --git a/src/plugins/wresolver/CMakeLists.txt b/src/plugins/wresolver/CMakeLists.txt index e8aefe17cd7..e7c8545d305 100644 --- a/src/plugins/wresolver/CMakeLists.txt +++ b/src/plugins/wresolver/CMakeLists.txt @@ -1,4 +1,3 @@ include (LibAddMacros) -add_plugin (wresolver SOURCES wresolver.h wresolver.c - COMPONENT libelektra4) +add_plugin (wresolver SOURCES wresolver.h wresolver.c COMPONENT libelektra4) diff --git a/src/plugins/xerces/CMakeLists.txt b/src/plugins/xerces/CMakeLists.txt index 60b8d5d5a6f..b107efc104a 100644 --- a/src/plugins/xerces/CMakeLists.txt +++ b/src/plugins/xerces/CMakeLists.txt @@ -22,8 +22,7 @@ add_plugin ( INCLUDE_SYSTEM_DIRECTORIES ${XercesC_INCLUDE_DIRS} LINK_LIBRARIES ${XercesC_LIBRARIES} LINK_ELEKTRA elektra-meta - INSTALL_TEST_DATA TEST_README - COMPONENT libelektra4-xerces) + INSTALL_TEST_DATA TEST_README COMPONENT libelektra4-xerces) if (ADDTESTING_PHASE) include (LibAddTest) diff --git a/src/plugins/xmltool/CMakeLists.txt b/src/plugins/xmltool/CMakeLists.txt index 143d52fec3b..1bf934d4cec 100644 --- a/src/plugins/xmltool/CMakeLists.txt +++ b/src/plugins/xmltool/CMakeLists.txt @@ -12,8 +12,7 @@ add_plugin ( INSTALL_TEST_DATA INCLUDE_DIRECTORIES ${LIBXML2_INCLUDE_DIR} LINK_ELEKTRA elektra-meta - LINK_LIBRARIES ${LIBXML2_LIBRARIES} - COMPONENT libelektra4-xmltool) + LINK_LIBRARIES ${LIBXML2_LIBRARIES} COMPONENT libelektra4-xmltool) if (ADDTESTING_PHASE) include (LibAddMacros) diff --git a/src/plugins/yajl/CMakeLists.txt b/src/plugins/yajl/CMakeLists.txt index a8e94eada08..e85d045e0d1 100644 --- a/src/plugins/yajl/CMakeLists.txt +++ b/src/plugins/yajl/CMakeLists.txt @@ -24,5 +24,4 @@ add_plugin ( INSTALL_TEST_DATA INCLUDE_DIRECTORIES "${INCL}" LINK_ELEKTRA elektra-ease - LINK_LIBRARIES ${YAJL_LIBRARIES} - COMPONENT libelektra4-yajl) + LINK_LIBRARIES ${YAJL_LIBRARIES} COMPONENT libelektra4-yajl) diff --git a/src/plugins/yamlsmith/CMakeLists.txt b/src/plugins/yamlsmith/CMakeLists.txt index 75684feac0d..08647827615 100644 --- a/src/plugins/yamlsmith/CMakeLists.txt +++ b/src/plugins/yamlsmith/CMakeLists.txt @@ -2,5 +2,4 @@ add_plugin ( yamlsmith CPP SOURCES yamlsmith.hpp yamlsmith.cpp LINK_ELEKTRA elektra-ease - ADD_TEST TEST_README - COMPONENT libelektra4-extra) + ADD_TEST TEST_README COMPONENT libelektra4-extra) diff --git a/src/plugins/zeromqrecv/CMakeLists.txt b/src/plugins/zeromqrecv/CMakeLists.txt index 0ad078f18de..958ac8600bc 100644 --- a/src/plugins/zeromqrecv/CMakeLists.txt +++ b/src/plugins/zeromqrecv/CMakeLists.txt @@ -14,8 +14,7 @@ add_plugin ( OBJECT_SOURCES $ INCLUDE_DIRECTORIES ${ZeroMQ_INCLUDE_DIR} LINK_ELEKTRA elektra-io - LINK_LIBRARIES ${ZeroMQ_LIBRARIES} - COMPONENT libelektra4-zeromq) + LINK_LIBRARIES ${ZeroMQ_LIBRARIES} COMPONENT libelektra4-zeromq) if (ADDTESTING_PHASE) check_binding_was_added ("io_uv" IS_INCLUDED) diff --git a/src/plugins/zeromqsend/CMakeLists.txt b/src/plugins/zeromqsend/CMakeLists.txt index dfd54554a44..263db7d7caa 100644 --- a/src/plugins/zeromqsend/CMakeLists.txt +++ b/src/plugins/zeromqsend/CMakeLists.txt @@ -10,8 +10,7 @@ add_plugin ( zeromqsend SOURCES zeromqsend.h zeromqsend.c publish.c INCLUDE_DIRECTORIES ${ZeroMQ_INCLUDE_DIR} - LINK_LIBRARIES ${ZeroMQ_LIBRARIES} - COMPONENT libelektra4-zeromq) + LINK_LIBRARIES ${ZeroMQ_LIBRARIES} COMPONENT libelektra4-zeromq) if (ADDTESTING_PHASE) # the test requires pthread find_package (Threads QUIET) diff --git a/src/tools/kdb/CMakeLists.txt b/src/tools/kdb/CMakeLists.txt index 829cc9be13f..ea5780f9dec 100644 --- a/src/tools/kdb/CMakeLists.txt +++ b/src/tools/kdb/CMakeLists.txt @@ -23,7 +23,10 @@ if (BUILD_SHARED) target_link_libraries (kdb elektra-core elektra-kdb elektratools elektra-opts elektra-merge) - install (TARGETS kdb DESTINATION bin COMPONENT elektra-bin) + install ( + TARGETS kdb + DESTINATION bin + COMPONENT elektra-bin) endif (BUILD_SHARED) if (BUILD_FULL) @@ -32,7 +35,10 @@ if (BUILD_FULL) target_link_libraries (kdb-full elektra-full elektratools-full) - install (TARGETS kdb-full DESTINATION bin COMPONENT libelektra4-full) + install ( + TARGETS kdb-full + DESTINATION bin + COMPONENT libelektra4-full) endif (BUILD_FULL) if (BUILD_STATIC) @@ -50,5 +56,8 @@ if (BUILD_STATIC) set_target_properties (kdb-static PROPERTIES LINK_FLAGS ${CMAKE_STATIC_FLAGS}) endif () - install (TARGETS kdb-static DESTINATION bin COMPONENT elektra-bin) + install ( + TARGETS kdb-static + DESTINATION bin + COMPONENT elektra-bin) endif (BUILD_STATIC) diff --git a/src/tools/qt-gui/CMakeLists.txt b/src/tools/qt-gui/CMakeLists.txt index b478edf1233..cb51cc063a1 100644 --- a/src/tools/qt-gui/CMakeLists.txt +++ b/src/tools/qt-gui/CMakeLists.txt @@ -80,11 +80,23 @@ else () ${Qt5DBus_LIBRARIES}) tool_link_elektratools (qt-gui elektra-ease) - install (TARGETS qt-gui DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-qt-gui) + install ( + TARGETS qt-gui + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} + COMPONENT elektra-qt-gui) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/elektra-qt-editor.in" "${CMAKE_CURRENT_BINARY_DIR}/elektra-qt-editor") - install (PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/elektra-qt-editor" DESTINATION bin COMPONENT elektra-qt-gui) - install (FILES org.libelektra.elektra-qt-editor.desktop DESTINATION share/applications COMPONENT elektra-qt-gui) - install (FILES org.libelektra.elektra-qt-editor.appdata.xml DESTINATION share/appdata COMPONENT elektra-qt-gui) + install ( + PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/elektra-qt-editor" + DESTINATION bin + COMPONENT elektra-qt-gui) + install ( + FILES org.libelektra.elektra-qt-editor.desktop + DESTINATION share/applications + COMPONENT elektra-qt-gui) + install ( + FILES org.libelektra.elektra-qt-editor.appdata.xml + DESTINATION share/appdata + COMPONENT elektra-qt-gui) install ( FILES ../../../doc/images/logo/logo_color.svg DESTINATION share/icons/hicolor/scalable/apps diff --git a/src/tools/race/CMakeLists.txt b/src/tools/race/CMakeLists.txt index 89ca5ba0c89..a95e3cabe62 100644 --- a/src/tools/race/CMakeLists.txt +++ b/src/tools/race/CMakeLists.txt @@ -18,5 +18,8 @@ else () target_link_libraries (race ${CMAKE_THREAD_LIBS_INIT}) target_link_libraries (race ${LIBRT_LIBRARIES}) - install (TARGETS race DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-tests) + install ( + TARGETS race + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} + COMPONENT elektra-tests) endif () diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index d34e91fd410..afd5bef6b05 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -51,7 +51,10 @@ macro (do_test source) add_executable (${source} ${SOURCES}) if (INSTALL_TESTING) - install (TARGETS ${source} DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-tests) + install ( + TARGETS ${source} + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} + COMPONENT elektra-tests) endif (INSTALL_TESTING) target_link_elektra (${source}) diff --git a/tests/shell/CMakeLists.txt b/tests/shell/CMakeLists.txt index cc45e962f63..71bb65b5194 100644 --- a/tests/shell/CMakeLists.txt +++ b/tests/shell/CMakeLists.txt @@ -48,10 +48,7 @@ function (add_scripttest testname) message (SEND_ERROR "add_scripttest: given file ${filename} does not exists") endif (NOT EXISTS ${filename}) - set ( - COMPONENT_BIN_EXTRA_FILES - generate_data - ) + set (COMPONENT_BIN_EXTRA_FILES generate_data) foreach (TARGET true false) if (TARGET) @@ -68,10 +65,10 @@ function (add_scripttest testname) check_spelling) if ("${testname_we}" IN_LIST COMPONENT_BIN_EXTRA_FILES) - set(HAS_COMPONENT elektra-bin-extra) - else() - set(HAS_COMPONENT elektra-tests) - endif() + set (HAS_COMPONENT elektra-bin-extra) + else () + set (HAS_COMPONENT elektra-tests) + endif () list (FIND excluded_tests "${testname_we}" index_excluded) if (index_excluded EQUAL -1) @@ -127,7 +124,10 @@ function (add_scripttest testname) endfunction (add_scripttest) if (INSTALL_TESTING) - install (DIRECTORY "shell" DESTINATION ${TARGET_TEST_DATA_FOLDER} COMPONENT elektra-tests) + install ( + DIRECTORY "shell" + DESTINATION ${TARGET_TEST_DATA_FOLDER} + COMPONENT elektra-tests) endif (INSTALL_TESTING) file (GLOB SCRIPT_TESTS *.sh) diff --git a/tests/shell/gen/CMakeLists.txt b/tests/shell/gen/CMakeLists.txt index 33d123b0b4a..15d9cad5a15 100644 --- a/tests/shell/gen/CMakeLists.txt +++ b/tests/shell/gen/CMakeLists.txt @@ -25,7 +25,10 @@ endforeach () unset (C_FLAG_32BIT) if (INSTALL_TESTING) - install (DIRECTORY "." DESTINATION "${TARGET_TEST_DATA_FOLDER}/gen" COMPONENT elektra-tests) + install ( + DIRECTORY "." + DESTINATION "${TARGET_TEST_DATA_FOLDER}/gen" + COMPONENT elektra-tests) install ( DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}" DESTINATION "${TARGET_TEST_DATA_FOLDER}/gen" From 66cd9774ea1c4cf846c0b2a6e5c82babfb233a59 Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Tue, 8 Dec 2020 02:46:12 +0100 Subject: [PATCH 10/32] package: move script to packaging folder --- scripts/{release => packaging}/package.sh | 1 - 1 file changed, 1 deletion(-) rename scripts/{release => packaging}/package.sh (95%) diff --git a/scripts/release/package.sh b/scripts/packaging/package.sh similarity index 95% rename from scripts/release/package.sh rename to scripts/packaging/package.sh index bbb522eeba9..6ac529f2849 100644 --- a/scripts/release/package.sh +++ b/scripts/packaging/package.sh @@ -41,5 +41,4 @@ CMAKE_ARGS="-DTARGET_PLUGIN_FOLDER='elektra4' \ -DCMAKE_SHARED_LINKER_FLAGS=$LDFLAGS" cmake $CMAKE_ARGS .. -# TODO: change to relative path ./lib:.... instead of full path LD_LIBRARY_PATH=$(pwd)/lib:${LD_LIBRARY_PATH} make package From 9b568751b25db427b3f4799f320154d3af5990d2 Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Tue, 8 Dec 2020 03:05:31 +0100 Subject: [PATCH 11/32] doc: add release notes --- doc/news/_preparation_next_release.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/news/_preparation_next_release.md b/doc/news/_preparation_next_release.md index f8cc4c9519c..76e4a85e4be 100644 --- a/doc/news/_preparation_next_release.md +++ b/doc/news/_preparation_next_release.md @@ -162,7 +162,7 @@ you up to date with the multi-language support provided by Elektra. ### CMake - Use Lua 5.4 when available. _(Mihael Pranjić)_ -- <> +- We now use CPack to build modular Debian and Ubuntu packages. _(Robert Sowula)_ - <> - Force `RTLD_NODELETE` on dlopen() when the `ENABLE_ASAN` CMake option is used. This enables ASAN to find symbols which otherwise might be unloaded. _(Mihael Pranjić)_ - <> From 9293bc750079c346df860b4e642f6bbea9e8b9f7 Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Thu, 10 Dec 2020 09:28:47 +0100 Subject: [PATCH 12/32] cmake: add symlink kdb.1 to kdb-static.1 --- scripts/cmake/Modules/LibAddMacros.cmake | 52 +++++++++++++++++++++++- 1 file changed, 51 insertions(+), 1 deletion(-) diff --git a/scripts/cmake/Modules/LibAddMacros.cmake b/scripts/cmake/Modules/LibAddMacros.cmake index 7bb5f9e18e4..99655414883 100644 --- a/scripts/cmake/Modules/LibAddMacros.cmake +++ b/scripts/cmake/Modules/LibAddMacros.cmake @@ -15,7 +15,7 @@ endmacro (copy_file) # - JAVA: install symlink for Java in share/java # - otherwise: install symlink for normal libraries # -# create_lib_symlink src dest - create a symbolic link from src -> dest +# create_lib_symlink src dest component - create a symbolic link from src -> dest # ~~~ macro (create_lib_symlink src dest component) @@ -68,6 +68,50 @@ macro (create_lib_symlink src dest component) COMPONENT "${component}") endmacro (create_lib_symlink src dest component) + +# ~~~ +# Create a symlink for man1 files at installation +# +# create_lib_symlink src dest component - create a symbolic link from src -> dest +# ~~~ +macro (create_doc_symlink src dest component) + + cmake_parse_arguments ( + ARG + "" # optional keywords + "" # one value keywords + "" # multi value keywords + ${ARGN}) + + set (DOC_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}/share/man/man1") + + install ( + CODE " + message (STATUS \"Installing symlink: \$ENV{DESTDIR}${DOC_INSTALL_DIR}/${dest} -> ${src}\") + execute_process (COMMAND \"${CMAKE_COMMAND}\" -E make_directory + \"\$ENV{DESTDIR}${DOC_INSTALL_DIR}\" + RESULT_VARIABLE RET + ) + if (RET) + message (WARNING \"Could not create directory\") + endif () + execute_process (COMMAND \"${CMAKE_COMMAND}\" -E create_symlink + \"${src}\" + \"${dest}\" + WORKING_DIRECTORY \"\$ENV{DESTDIR}${DOC_INSTALL_DIR}\" + RESULT_VARIABLE RET + ) + + # for uninstall: + file (APPEND \"${CMAKE_BINARY_DIR}/extra_install_manifest.txt\" \"\$ENV{DESTDIR}${DOC_INSTALL_DIR}/${dest}\\n\") + + if (RET) + message (WARNING \"Could not install symlink\") + endif () + " + COMPONENT "${component}") +endmacro (create_doc_symlink src dest component) + # ~~~ # Make a directory # @@ -608,6 +652,12 @@ If you do not add this file, then installing Elektra will fail!\n") FILES ${OUTFILE} DESTINATION share/man/man${SECTION} COMPONENT "${ARG_COMPONENT}") + + if (BUILD_STATIC) + if (SECTION EQUAL 1) + create_doc_symlink("kdb.${SECTION}" "kdb-static.${SECTION}" "${ARG_COMPONENT}") + endif() + endif () endif () endif (BUILD_DOCUMENTATION) endfunction () From d7817d405132067ac67e69dce91eafe605353543 Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Fri, 11 Dec 2020 00:14:43 +0100 Subject: [PATCH 13/32] packaging: add copyright file for debian --- scripts/packaging/copyright | 556 ++++++++++++++++++++++++++++++++++++ 1 file changed, 556 insertions(+) create mode 100644 scripts/packaging/copyright diff --git a/scripts/packaging/copyright b/scripts/packaging/copyright new file mode 100644 index 00000000000..8cc0fd8ac77 --- /dev/null +++ b/scripts/packaging/copyright @@ -0,0 +1,556 @@ +Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ +Upstream-Name: Elektra +Upstream-Contact: Markus Raab +Source: http://www.libelektra.org/ftp/elektra/releases/ + +Files: * +Copyright: 2003-2004, 2006-2008, 2010, 2013-2014 Markus Raab + 2003-2005 Avi Alkalay + 2004 Vladimir Shabanov + 2006 Yannick Lecaillez + 2007 Patrick Sabin + 2013 Christian Loose + 2014-2015 Felix Berlakovich +License: BSD-3-clause + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions are met: + . + - Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + . + - Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + . + - Neither the name of Elektra nor the names of its contributors may + be used to endorse or promote products derived from this software without + specific prior written permission. + . + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND + ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR + ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +Files: cmake/Modules/DownloadProject* +Copyright: 2015 Craig Scott +License: MIT + +Files: cmake/Modules/FindAugeas.cmake + cmake/Modules/FindDBus.cmake + cmake/Modules/FindGObjectIntrospection.cmake + cmake/Modules/FindSystemdJournal.cmake +Copyright: 2006 Alexander Neundorf + 2008 Kevin Kofler + 2010 Pino Toscano + 2013 Martin Briza +License: BSD-3-clause-cmake + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + . + 1. Redistributions of source code must retain the copyright + notice, this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + 3. The name of the author may not be used to endorse or promote products + derived from this software without specific prior written permission. + . + THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +Files: cmake/Modules/FindDiscount.cmake +Copyright: 2013-2013 Lars Baehren +License: BSD-2-clause-discount + Redistribution and use in source and binary forms, with or without modification, + are permitted provided that the following conditions are met: + . + * Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + . + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" + AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE + FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +Files: cmake/Modules/FindLua52.cmake + cmake/Modules/FindPython2Interp.cmake + cmake/Modules/FindPython2Libs.cmake +Copyright: 2001-2010 Kitware, Inc. + 2011 Bjoern Ricks + 2012 Rolf Eike Beer +License: BSD-3-clause-cmake-new + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + . + * Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + . + * Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + . + * Neither the names of Kitware, Inc., the Insight Software Consortium, + nor the names of their contributors may be used to endorse or promote + products derived from this software without specific prior written + permission. + . + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +Files: src/plugins/ini/inih-r29/* +Copyright: 2009, Brush Technology +License: BSD-3-clause-inih + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions are met: + * Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + * Neither the name of Brush Technology nor the names of its contributors + may be used to endorse or promote products derived from this software + without specific prior written permission. + . + THIS SOFTWARE IS PROVIDED BY BRUSH TECHNOLOGY ''AS IS'' AND ANY + EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + DISCLAIMED. IN NO EVENT SHALL BRUSH TECHNOLOGY BE LIABLE FOR ANY + DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND + ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +Files: src/plugins/ni/nickel-1.1.0/* +Copyright: 2008 Charles Lindsay +License: Zlib + This software is provided 'as-is', without any express or implied + warranty. In no event will the authors be held liable for any damages + arising from the use of this software. + . + Permission is granted to anyone to use this software for any purpose, + including commercial applications, and to alter it and redistribute it + freely, subject to the following restrictions: + . + 1. The origin of this software must not be misrepresented; you must not + claim that you wrote the original software. If you use this software + in a product, an acknowledgment in the product documentation would be + appreciated but is not required. + . + 2. Altered source versions must be plainly marked as such, and must not be + misrepresented as being the original software. + . + 3. This notice may not be removed or altered from any source + distribution. + +Files: src/plugins/ni/nickel-1.1.0/src/hash.c +Copyright: 2006 Bob Jenkins +License: public-domain + This is a trivially modified public domain hash library, lookup3.c, from: + http://burtleburtle.net/bob/hash/ + . + You can use this free for any purpose. It's in the public domain. + It has no warranty. + +Files: src/tools/rest-frontend/resources/assets/skin/base/util/space.less +Copyright: 2015 Ömer Aslanbakan +License: MIT + +Files: src/tools/rest-frontend/public/assets/fonts/lato/* +Copyright: 2010-2014 by tyPoland Lukasz Dziedzic (team@latofonts.com) with Reserved Font Name "Lato" +License: OFL-1.1 + +Files: src/tools/rest-frontend/public/assets/fonts/libre-franklin/* +Copyright: 2015 Impallari Type (www.impallari.com) +License: OFL-1.1 + +Files: src/tools/rest-frontend/public/assets/fonts/font-awesome/* +Copyright: 2016 Dave Gandy +License: OFL-1.1 + +Files: src/tools/rest-frontend/public/vendor/asciinema/asciinema-player.* +Copyright: 2011-2016 Marcin Kulik +License: Apache-2.0-asciinema + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + . + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + . + 1. Definitions. + . + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + . + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + . + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + . + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + . + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + . + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + . + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + . + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + . + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + . + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + . + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + . + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + . + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + . + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + . + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + . + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + . + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + . + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + . + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + . + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + . + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + . + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + . + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + . + END OF TERMS AND CONDITIONS + . + APPENDIX: How to apply the Apache License to your work. + . + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "{}" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + . + Copyright 2011-2017 Marcin Kulik + . + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + . + http://www.apache.org/licenses/LICENSE-2.0 + . + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +Files: src/tools/rest-frontend/resources/assets/skin/base/fonts/font-awesome/* +Copyright: 2016 Dave Gandy +License: MIT + +Files: src/tools/qt-gui/src/markdownconverter/* +Copyright: 2013 Christian Loose +License: BSD-3-clause-markdownconverter + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions are + met: + . + (1) Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + . + (2) Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in + the documentation and/or other materials provided with the + distribution. + . + (3) The name of the author may not be used to + endorse or promote products derived from this software without + specific prior written permission. + . + THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, + INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, + STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING + IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + +License: OFL-1.1 + This Font Software is licensed under the SIL Open Font License, Version 1.1. + This license is copied below, and is also available with a FAQ at: + http://scripts.sil.org/OFL + . + . + ----------------------------------------------------------- + SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007 + ----------------------------------------------------------- + . + PREAMBLE + The goals of the Open Font License (OFL) are to stimulate worldwide + development of collaborative font projects, to support the font creation + efforts of academic and linguistic communities, and to provide a free and + open framework in which fonts may be shared and improved in partnership + with others. + . + The OFL allows the licensed fonts to be used, studied, modified and + redistributed freely as long as they are not sold by themselves. The + fonts, including any derivative works, can be bundled, embedded, + redistributed and/or sold with any software provided that any reserved + names are not used by derivative works. The fonts and derivatives, + however, cannot be released under any other type of license. The + requirement for fonts to remain under this license does not apply + to any document created using the fonts or their derivatives. + . + DEFINITIONS + "Font Software" refers to the set of files released by the Copyright + Holder(s) under this license and clearly marked as such. This may + include source files, build scripts and documentation. + . + "Reserved Font Name" refers to any names specified as such after the + copyright statement(s). + . + "Original Version" refers to the collection of Font Software components as + distributed by the Copyright Holder(s). + . + "Modified Version" refers to any derivative made by adding to, deleting, + or substituting -- in part or in whole -- any of the components of the + Original Version, by changing formats or by porting the Font Software to a + new environment. + . + "Author" refers to any designer, engineer, programmer, technical + writer or other person who contributed to the Font Software. + . + PERMISSION & CONDITIONS + Permission is hereby granted, free of charge, to any person obtaining + a copy of the Font Software, to use, study, copy, merge, embed, modify, + redistribute, and sell modified and unmodified copies of the Font + Software, subject to the following conditions: + . + 1) Neither the Font Software nor any of its individual components, + in Original or Modified Versions, may be sold by itself. + . + 2) Original or Modified Versions of the Font Software may be bundled, + redistributed and/or sold with any software, provided that each copy + contains the above copyright notice and this license. These can be + included either as stand-alone text files, human-readable headers or + in the appropriate machine-readable metadata fields within text or + binary files as long as those fields can be easily viewed by the user. + . + 3) No Modified Version of the Font Software may use the Reserved Font + Name(s) unless explicit written permission is granted by the corresponding + Copyright Holder. This restriction only applies to the primary font name as + presented to the users. + . + 4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font + Software shall not be used to promote, endorse or advertise any + Modified Version, except to acknowledge the contribution(s) of the + Copyright Holder(s) and the Author(s) or with their explicit written + permission. + . + 5) The Font Software, modified or unmodified, in part or in whole, + must be distributed entirely under this license, and must not be + distributed under any other license. The requirement for fonts to + remain under this license does not apply to any document created + using the Font Software. + . + TERMINATION + This license becomes null and void if any of the above conditions are + not met. + . + DISCLAIMER + THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, + EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF + MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT + OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE + COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, + INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL + DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM + OTHER DEALINGS IN THE FONT SOFTWARE. + +License: MIT + Permission is hereby granted, free of charge, to any person obtaining a copy + of this software and associated documentation files (the "Software"), to deal + in the Software without restriction, including without limitation the rights + to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + . + The above copyright notice and this permission notice shall be included in all + copies or substantial portions of the Software. + . + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + SOFTWARE. From 5d0d079d3eef1de3a76b34fdb129edb7a3a8563c Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Fri, 11 Dec 2020 01:37:10 +0100 Subject: [PATCH 14/32] cpack: install debian copyright file on debian based distros --- scripts/cmake/ElektraPackaging.cmake | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/scripts/cmake/ElektraPackaging.cmake b/scripts/cmake/ElektraPackaging.cmake index 43582f8d108..57589ba04ab 100644 --- a/scripts/cmake/ElektraPackaging.cmake +++ b/scripts/cmake/ElektraPackaging.cmake @@ -339,6 +339,14 @@ if (UNIX) ) set (CPACK_DEBIAN_LIBELEKTRA4-ALL_PACKAGE_RECOMMENDS "elektra-tests, elektra-doc, libelektra-dev") # add all .ddeb packages? + # install copyright file + foreach(component ${CPACK_COMPONENTS_ALL}) + install ( + FILES "${CMAKE_SOURCE_DIR}/scripts/packaging/copyright" + COMPONENT ${component} + DESTINATION "share/doc/${component}/") + endforeach() + # build debug package for each component set (CPACK_DEBIAN_DEBUGINFO_PACKAGE "ON") From 22cf55f897e64e1ae44a4a3472974ffdab976cb5 Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Fri, 11 Dec 2020 03:35:09 +0100 Subject: [PATCH 15/32] cpack: add elektra-dbg package --- scripts/cmake/ElektraPackaging.cmake | 47 ++++++++++++++++++++++++---- 1 file changed, 41 insertions(+), 6 deletions(-) diff --git a/scripts/cmake/ElektraPackaging.cmake b/scripts/cmake/ElektraPackaging.cmake index 57589ba04ab..923cc5cd77e 100644 --- a/scripts/cmake/ElektraPackaging.cmake +++ b/scripts/cmake/ElektraPackaging.cmake @@ -34,12 +34,24 @@ set ( elektra-bin-extra elektra-doc elektra-qt-gui - elektra-tests) + elektra-tests + elektra-dbg) set (ALL_PLUGINS ${CPACK_COMPONENTS_ALL}) list (FILTER ALL_PLUGINS INCLUDE REGEX "^libelektra4-.*") string (REPLACE ";" ", " ALL_PLUGINS_STR "${ALL_PLUGINS}") +set (DBG_PACKAGE_NAMES "") +foreach(component ${CPACK_COMPONENTS_ALL}) + list(APPEND DBG_PACKAGE_NAMES "${component}-dbgsym") +endforeach() +list (FILTER DBG_PACKAGE_NAMES EXCLUDE REGEX "^elektra-doc.*") # elektra-doc doesn't contain dbgsym +list (FILTER DBG_PACKAGE_NAMES EXCLUDE REGEX "^elektra-dbg.*") +list (FILTER DBG_PACKAGE_NAMES EXCLUDE REGEX "^libelektra-dev.*") +list (FILTER DBG_PACKAGE_NAMES EXCLUDE REGEX "^libelektra4-all.*") +list (FILTER DBG_PACKAGE_NAMES EXCLUDE REGEX "^elektra-bin-extra.*") +string (REPLACE ";" ", " DBG_PACKAGE_NAMES_STR "${DBG_PACKAGE_NAMES}") + set ( PACKAGE_DESCRIPTION "Elektra provides a universal and secure framework to store configuration parameters in a global, hierarchical key database. The core is a small library implemented in C. The plugin-based framework fulfills many configuration-related tasks to avoid any unnecessary code duplication across applications while it still allows the core to stay without any external dependency. Elektra abstracts from cross-platform-related issues with an consistent API, and allows applications to be aware of other applications' configurations, leveraging easy application integration.\n." @@ -102,7 +114,6 @@ if (UNIX) set (CPACK_DEB_COMPONENT_INSTALL "ON") set (CPACK_DEB_PACKAGE_COMPONENT "ON") set (CPACK_DEBIAN_ENABLE_COMPONENT_DEPENDS "ON") - set (CPACK_DEBIAN_RUNTIME_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_NAME "libelektra4") set (CPACK_COMPONENT_LIBELEKTRA4_DISPLAY_NAME "libelektra4") @@ -113,6 +124,7 @@ if (UNIX) set (CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_REPLACES "elektra-bin (<< 0.8.14-5~), libelelektra-core4 (<< 0.8.19-1), libelektra-full4 (<< 0.8.19-1)") set (CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_SUGGESTS "elektra-doc, ${ALL_PLUGINS_STR}") + set (CPACK_DEBIAN_LIBELEKTRA4_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_NAME "libelektra4-full") set (CPACK_COMPONENT_LIBELEKTRA4-FULL_DISPLAY_NAME "libelektra4-full") @@ -127,6 +139,7 @@ if (UNIX) set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_CONFLICTS "libelektra4 (<< ${CPACK_DEBIAN_PACKAGE_VERSION}), elektra-tests (<< ${CPACK_DEBIAN_PACKAGE_VERSION})") set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_SUGGESTS "elektra-doc, ${ALL_PLUGINS_STR}") + set (CPACK_DEBIAN_LIBELEKTRA4-FULL_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_PACKAGE_NAME "libelektra4-experimental") set (CPACK_COMPONENT_LIBELEKTRA4-EXPERIMENTAL_DISPLAY_NAME "libelektra4-experimental") @@ -135,6 +148,7 @@ if (UNIX) set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_PACKAGE_BREAKS "elektra-bin (<< 0.8.14-5~), libelektra-core4 (<< 0.8.19-1)") set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_PACKAGE_REPLACES "elektra-bin (<< 0.8.14-5~), libelelektra-core4 (<< 0.8.19-1)") set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_PACKAGE_SUGGESTS "elektra-doc, ${ALL_PLUGINS_STR}") + set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_PACKAGE_NAME "libelektra4-extra") set (CPACK_COMPONENT_LIBELEKTRA4-EXTRA_DISPLAY_NAME "libelektra4-extra") @@ -143,6 +157,7 @@ if (UNIX) set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_PACKAGE_BREAKS "elektra-bin (<< 0.8.14-5~), libelektra-core4 (<< 0.8.19-1)") set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_PACKAGE_REPLACES "elektra-bin (<< 0.8.14-5~), libelelektra-core4 (<< 0.8.19-1)") set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_PACKAGE_SUGGESTS "elektra-doc, ${ALL_PLUGINS_STR}") + set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_NAME "elektra-bin") set (CPACK_COMPONENT_ELEKTRA-BIN_DISPLAY_NAME "elektra-bin") @@ -157,6 +172,7 @@ if (UNIX) file (COPY ${CONTROL_FILES_ELEKTRA-BIN} DESTINATION "${CMAKE_BINARY_DIR}/scripts/packaging/debian-control/elektra-bin/") file (GLOB CONTROL_FILES_ELEKTRA-BIN_BINARY "${CMAKE_BINARY_DIR}/scripts/packaging/debian-control/elektra-bin/*") set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_CONTROL_EXTRA "${CONTROL_FILES_ELEKTRA-BIN_BINARY}") + set (CPACK_DEBIAN_ELEKTRA-BIN_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_LIBELEKTRA4-AUGEAS_PACKAGE_NAME "libelektra4-augeas") set (CPACK_COMPONENT_LIBELEKTRA4-AUGEAS_DISPLAY_NAME "libelektra4-augeas") @@ -165,6 +181,7 @@ if (UNIX) set (CPACK_DEBIAN_LIBELEKTRA4-AUGEAS_PACKAGE_SECTION "libs") set (CPACK_DEBIAN_LIBELEKTRA4-AUGEAS_PACKAGE_BREAKS "libelektra-augeas4 (<< 0.8.19-1)") set (CPACK_DEBIAN_LIBELEKTRA4-AUGEAS_PACKAGE_REPLACES "libelektra-augeas4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-AUGEAS_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_LIBELEKTRA4-DBUS_PACKAGE_NAME "libelektra4-dbus") set (CPACK_COMPONENT_LIBELEKTRA4-DBUS_DISPLAY_NAME "libelektra4-dbus") @@ -173,6 +190,7 @@ if (UNIX) set (CPACK_DEBIAN_LIBELEKTRA4-DBUS_PACKAGE_SECTION "libs") set (CPACK_DEBIAN_LIBELEKTRA4-DBUS_PACKAGE_BREAKS "libelektra-dbus4 (<< 0.8.19-1)") set (CPACK_DEBIAN_LIBELEKTRA4-DBUS_PACKAGE_REPLACES "libelektra-dbus4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-DBUS_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_LIBELEKTRA-DEV_PACKAGE_NAME "libelektra-dev") set (CPACK_COMPONENT_LIBELEKTRA-DEV_DISPLAY_NAME "libelektra-dev") @@ -185,6 +203,7 @@ if (UNIX) set (CPACK_COMPONENT_LIBELEKTRA4-ZEROMQ_DESCRIPTION "This package contains the 'zeromq' plugins.") set (CPACK_COMPONENT_LIBELEKTRA4-ZEROMQ_DEPENDS "libelektra4") set (CPACK_DEBIAN_LIBELEKTRA4-ZEROMQ_PACKAGE_SECTION "libs") + set (CPACK_DEBIAN_LIBELEKTRA4-ZEROMQ_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_LIBELEKTRA4-XMLTOOL_PACKAGE_NAME "libelektra4-xmltool") set (CPACK_COMPONENT_LIBELEKTRA4-XMLTOOL_DISPLAY_NAME "libelektra4-xmltool") @@ -193,6 +212,7 @@ if (UNIX) set (CPACK_DEBIAN_LIBELEKTRA4-XMLTOOL_PACKAGE_SECTION "libs") set (CPACK_DEBIAN_LIBELEKTRA4-XMLTOOL_PACKAGE_BREAKS "libelektra-xmltool4 (<< 0.8.19-1)") set (CPACK_DEBIAN_LIBELEKTRA4-XMLTOOL_PACKAGE_REPLACES "libelektra-xmltool4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-XMLTOOL_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_LIBELEKTRA4-XERCES_PACKAGE_NAME "libelektra4-xerces") set (CPACK_COMPONENT_LIBELEKTRA4-XERCES_DISPLAY_NAME "libelektra4-xerces") @@ -201,6 +221,7 @@ if (UNIX) set (CPACK_DEBIAN_LIBELEKTRA4-XERCES_PACKAGE_SECTION "libs") set (CPACK_DEBIAN_LIBELEKTRA4-XERCES_PACKAGE_BREAKS "libelektra-xerces4 (<< 0.8.19-1)") set (CPACK_DEBIAN_LIBELEKTRA4-XERCES_PACKAGE_REPLACES "libelektra-xerces4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-XERCES_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_LIBELEKTRA4-YAJL_PACKAGE_NAME "libelektra4-yajl") set (CPACK_COMPONENT_LIBELEKTRA4-YAJL_DISPLAY_NAME "libelektra4-yajl") @@ -209,36 +230,42 @@ if (UNIX) set (CPACK_DEBIAN_LIBELEKTRA4-YAJL_PACKAGE_SECTION "libs") set (CPACK_DEBIAN_LIBELEKTRA4-YAJL_PACKAGE_BREAKS "libelektra-yajl4 (<< 0.8.19-1)") set (CPACK_DEBIAN_LIBELEKTRA4-YAJL_PACKAGE_REPLACES "libelektra-yajl4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-YAJL_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_LIBELEKTRA4-CRYPTO_PACKAGE_NAME "libelektra4-crypto") set (CPACK_COMPONENT_LIBELEKTRA4-CRYPTO_DISPLAY_NAME "libelektra4-crypto") set (CPACK_COMPONENT_LIBELEKTRA4-CRYPTO_DESCRIPTION "This package contains the crypto plugins.") set (CPACK_COMPONENT_LIBELEKTRA4-CRYPTO_DEPENDS "libelektra4") set (CPACK_DEBIAN_LIBELEKTRA4-CRYPTO_PACKAGE_SECTION "libs") + set (CPACK_DEBIAN_LIBELEKTRA4-CRYPTO_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_LIBELEKTRA4-CURL_PACKAGE_NAME "libelektra4-curl") set (CPACK_COMPONENT_LIBELEKTRA4-CURL_DISPLAY_NAME "libelektra4-curl") set (CPACK_COMPONENT_LIBELEKTRA4-CURL_DESCRIPTION "This package contains the 'curlget' plugin.") set (CPACK_COMPONENT_LIBELEKTRA4-CURL_DEPENDS "libelektra4") set (CPACK_DEBIAN_LIBELEKTRA4-CURL_PACKAGE_SECTION "libs") + set (CPACK_DEBIAN_LIBELEKTRA4-CURL_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_LIBELEKTRA4-JOURNALD_PACKAGE_NAME "libelektra4-journald") set (CPACK_COMPONENT_LIBELEKTRA4-JOURNALD_DISPLAY_NAME "libelektra4-journald") set (CPACK_COMPONENT_LIBELEKTRA4-JOURNALD_DESCRIPTION "This package contains the 'journald' plugins.") set (CPACK_COMPONENT_LIBELEKTRA4-JOURNALD_DEPENDS "libelektra4") set (CPACK_DEBIAN_LIBELEKTRA4-JOURNALD_PACKAGE_SECTION "libs") + set (CPACK_DEBIAN_LIBELEKTRA4-JOURNALD_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_LIBELEKTRA4-LUA_PACKAGE_NAME "libelektra4-lua") set (CPACK_COMPONENT_LIBELEKTRA4-LUA_DISPLAY_NAME "libelektra4-lua") set (CPACK_COMPONENT_LIBELEKTRA4-LUA_DESCRIPTION "This package contains the 'lua' plugin.") set (CPACK_COMPONENT_LIBELEKTRA4-LUA_DEPENDS "libelektra4") set (CPACK_DEBIAN_LIBELEKTRA4-LUA_PACKAGE_SECTION "libs") + set (CPACK_DEBIAN_LIBELEKTRA4-LUA_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_LUA-ELEKTRA_PACKAGE_NAME "lua-elektra") set (CPACK_COMPONENT_LUA-ELEKTRA_DISPLAY_NAME "lua-elektra") set (CPACK_COMPONENT_LUA-ELEKTRA_DESCRIPTION "This package contains the Lua bindings.") set (CPACK_COMPONENT_LUA-ELEKTRA_DEPENDS "libelektra4") set (CPACK_DEBIAN_LUA-ELEKTRA_PACKAGE_SECTION "interpreters") + set (CPACK_DEBIAN_LUA-ELEKTRA_DEBUGINFO_PACKAGE "ON") # maybe add python3:depends? (see control file) set (CPACK_DEBIAN_PYTHON3-ELEKTRA_PACKAGE_NAME "python3-elektra") @@ -252,6 +279,7 @@ if (UNIX) DESTINATION "${CMAKE_BINARY_DIR}/scripts/packaging/debian-control/python3-elektra/") file (GLOB CONTROL_FILES_PYTHON3-ELEKTRA_BINARY "${CMAKE_BINARY_DIR}/scripts/packaging/debian-control/python3-elektra/*") set (CPACK_DEBIAN_PYTHON3-ELEKTRA_PACKAGE_CONTROL_EXTRA "${CONTROL_FILES_PYTHON3-ELEKTRA_BINARY}") + set (CPACK_DEBIAN_PYTHON3-ELEKTRA_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_LIBELEKTRA4-PYTHON_PACKAGE_NAME "libelektra4-python") set (CPACK_COMPONENT_LIBELEKTRA4-PYTHON_DISPLAY_NAME "libelektra4-python") @@ -260,6 +288,7 @@ if (UNIX) set (CPACK_DEBIAN_LIBELEKTRA4-PYTHON_PACKAGE_SECTION "libs") set (CPACK_DEBIAN_LIBELEKTRA4-PYTHON_PACKAGE_BREAKS "libelelektra-python4 (<< 0.8.19-1)") set (CPACK_DEBIAN_LIBELEKTRA4-PYTHON_PACKAGE_REPLACES "libelelektra-python4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-PYTHON_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_ELEKTRA-BIN-EXTRA_PACKAGE_NAME "elektra-bin-extra") set (CPACK_COMPONENT_ELEKTRA-BIN-EXTRA_DISPLAY_NAME "elektra-bin-extra") @@ -269,6 +298,7 @@ if (UNIX) set (CPACK_DEBIAN_ELEKTRA-BIN-EXTRA_PACKAGE_DEPENDS "python-all") set (CPACK_DEBIAN_ELEKTRA-BIN-EXTRA_PACKAGE_SECTION "misc") set (CPACK_DEBIAN_ELEKTRA-BIN-EXTRA_PACKAGE_CONFLICTS "elektra-bin (<< ${CPACK_DEBIAN_PACKAGE_VERSION})") + set (CPACK_DEBIAN_ELEKTRA-BIN-EXTRA_DEBUGINFO_PACKAGE "OFF") set (CPACK_DEBIAN_ELEKTRA-QT-GUI_PACKAGE_NAME "elektra-qt-gui") set (CPACK_COMPONENT_ELEKTRA-QT-GUI_DISPLAY_NAME "elektra-qt-gui") @@ -287,6 +317,7 @@ if (UNIX) ) endif () set (CPACK_DEBIAN_ELEKTRA-QT-GUI_PACKAGE_SECTION "misc") + set (CPACK_DEBIAN_ELEKTRA-QT-GUI_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_ELEKTRA-TESTS_PACKAGE_NAME "elektra-tests") set (CPACK_COMPONENT_ELEKTRA-TESTS_DISPLAY_NAME "elektra-tests") @@ -296,6 +327,7 @@ if (UNIX) set (CPACK_DEBIAN_ELEKTRA-TESTS_PACKAGE_PRIORITY "extra") set (CPACK_DEBIAN_ELEKTRA-TESTS_PACKAGE_BREAKS "libelektra-test (<< 0.8.19-1), libelektra-full4 (<< 0.8.19-1)") set (CPACK_DEBIAN_ELEKTRA-TESTS_PACKAGE_REPLACES "libelektra-test (<< 0.8.19-1), libelektra-full4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_ELEKTRA-TESTS_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_ELEKTRA-DOC_PACKAGE_NAME "elektra-doc") set (CPACK_COMPONENT_ELEKTRA-DOC_DISPLAY_NAME "elektra-doc") @@ -337,7 +369,13 @@ if (UNIX) CPACK_DEBIAN_LIBELEKTRA4-ALL_PACKAGE_DEPENDS "libelektra4, libelektra4-experimental, libelektra4-augeas, libelektra4-dbus, libelektra4-zeromq, libelektra4-lua, libelektra4-python, libelektra4-xmltool, libelektra4-xerces, libelektra4-yajl, lua-elektra, elektra-bin, elektra-qt-gui, libelektra4-crypto, libelektra4-curl, libelektra4-journald, libelektra4-extra" ) - set (CPACK_DEBIAN_LIBELEKTRA4-ALL_PACKAGE_RECOMMENDS "elektra-tests, elektra-doc, libelektra-dev") # add all .ddeb packages? + set (CPACK_DEBIAN_LIBELEKTRA4-ALL_PACKAGE_RECOMMENDS "elektra-tests, elektra-doc, elektra-dbg, libelektra-dev") + + set (CPACK_DEBIAN_ELEKTRA-DBG_PACKAGE_NAME "elektra-dbg") + set (CPACK_COMPONENT_ELEKTRA-DBG_DISPLAY_NAME "elektra-dbg") + set (CPACK_COMPONENT_ELEKTRA-DBG_DESCRIPTION "This package contains the dependencies to all dbgsym packages of Elektra.") + set (CPACK_DEBIAN_ELEKTRA-DBG_PACKAGE_DEPENDS "${DBG_PACKAGE_NAMES_STR}") + set (CPACK_DEBIAN_ELEKTRA-DBG_PACKAGE_SECTION "debug") # install copyright file foreach(component ${CPACK_COMPONENTS_ALL}) @@ -347,9 +385,6 @@ if (UNIX) DESTINATION "share/doc/${component}/") endforeach() - # build debug package for each component - set (CPACK_DEBIAN_DEBUGINFO_PACKAGE "ON") - set (CPACK_DEBIAN_PACKAGE_SHLIBDEPS "ON") set (CPACK_DEBIAN_PACKAGE_GENERATE_SHLIBS "ON") From ab4a1b1030bf62ef299129a1c807e91fd6eb8b08 Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Fri, 11 Dec 2020 16:55:32 +0100 Subject: [PATCH 16/32] doc: convert THIRD_PARTY_LICENSES into dep5 format --- doc/THIRD-PARTY-LICENSES | 429 ++++++++++++++++++++- scripts/cmake/ElektraPackaging.cmake | 9 +- scripts/packaging/copyright | 556 --------------------------- 3 files changed, 417 insertions(+), 577 deletions(-) delete mode 100644 scripts/packaging/copyright diff --git a/doc/THIRD-PARTY-LICENSES b/doc/THIRD-PARTY-LICENSES index 72f60878ba9..c36d79ed4f1 100644 --- a/doc/THIRD-PARTY-LICENSES +++ b/doc/THIRD-PARTY-LICENSES @@ -1,16 +1,413 @@ -_: BSD-3-Clause -cmake/Modules/DownloadProject.cmake: mit -cmake/Modules/DownloadProject.CMakeLists.cmake.in: mit -cmake/Modules/DownloadProjectLicense.txt: mit -cmake/Modules/FindGLib.cmake: mit -scripts/realpath: mit -src/plugins/ni/nickel-1.1.0/_: zlib -src/plugins/ni/nickel-1.1.0/src/hash.c: public-domain -src/tools/website/public/assets/fonts/font-awesome/_: ofl-1.1 -src/tools/website/public/assets/fonts/lato/_: ofl-1.1 -src/tools/website/public/assets/fonts/libre-franklin/\*: ofl-1.1 -src/tools/website/resources/assets/skin/base/fonts/font-awesome/font-awesome.less: mit, ofl-1.1 -src/tools/website/resources/assets/skin/base/util/space.less: mit -src/tools/web/client/public/Roboto-Light.ttf: apache-2.0 -src/tools/web/client/public/Roboto-Regular.ttf: apache-2.0 -src/tools/kdb/gen/mustache.hpp: BSL-1.0 +Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ +Upstream-Name: Elektra +Upstream-Contact: Markus Raab +Source: http://www.libelektra.org/ftp/elektra/releases/ + +Files: * +Copyright: 2003-2004, 2006-2008, 2010, 2013-2014 Markus Raab + 2003-2005 Avi Alkalay + 2004 Vladimir Shabanov + 2006 Yannick Lecaillez + 2007 Patrick Sabin + 2013 Christian Loose + 2014-2015 Felix Berlakovich +License: BSD-3-clause + +Files: cmake/Modules/DownloadProject* +Copyright: 2015 Craig Scott +License: MIT + +Files: cmake/Modules/FindAugeas.cmake + cmake/Modules/FindDBus.cmake + cmake/Modules/FindGObjectIntrospection.cmake + cmake/Modules/FindSystemdJournal.cmake +Copyright: 2006 Alexander Neundorf + 2008 Kevin Kofler + 2010 Pino Toscano + 2013 Martin Briza +License: BSD-3-clause-cmake + +Files: cmake/Modules/FindDiscount.cmake +Copyright: 2013-2013 Lars Baehren +License: BSD-2-clause-discount + +Files: cmake/Modules/FindLua52.cmake + cmake/Modules/FindPython2Interp.cmake + cmake/Modules/FindPython2Libs.cmake +Copyright: 2001-2010 Kitware, Inc. + 2011 Bjoern Ricks + 2012 Rolf Eike Beer +License: BSD-3-clause-cmake-new + +Files: cmake/Modules/FindGLib.cmake +Copyright: 2016 Evan Nemerson +License: MIT + +Files: src/plugins/ini/inih-r29/* +Copyright: 2009, Brush Technology +License: BSD-3-clause-inih + +Files: src/plugins/ni/nickel-1.1.0/* +Copyright: 2008 Charles Lindsay +License: Zlib + +Files: src/plugins/ni/nickel-1.1.0/src/hash.c +Copyright: 2006 Bob Jenkins +License: public-domain + This is a trivially modified public domain hash library, lookup3.c, from: + http://burtleburtle.net/bob/hash/ + . + You can use this free for any purpose. It's in the public domain. + It has no warranty. + +Files: src/tools/rest-frontend/resources/assets/skin/base/util/space.less +Copyright: 2015 Ömer Aslanbakan +License: MIT + +Files: src/tools/rest-frontend/public/assets/fonts/lato/* +Copyright: 2010-2014 by tyPoland Lukasz Dziedzic (team@latofonts.com) with Reserved Font Name "Lato" +License: OFL-1.1 + +Files: src/tools/rest-frontend/public/assets/fonts/libre-franklin/* +Copyright: 2015 Impallari Type (www.impallari.com) +License: OFL-1.1 + +Files: src/tools/rest-frontend/public/assets/fonts/font-awesome/* +Copyright: 2016 Dave Gandy +License: OFL-1.1 + +Files: src/tools/rest-frontend/public/vendor/asciinema/asciinema-player.* +Copyright: 2011-2016 Marcin Kulik +License: Apache-2.0 + +Files: src/tools/rest-frontend/resources/assets/skin/base/fonts/font-awesome/* +Copyright: 2016 Dave Gandy +License: MIT + +Files: src/tools/qt-gui/src/markdownconverter/* +Copyright: 2013 Christian Loose +License: BSD-3-clause-markdownconverter + +Files: scripts/realpath +Copyright: 2014 Michael Kropat +License: MIT + +Files: src/tools/web/client/public/Roboto-Light.ttf + src/tools/web/client/public/Roboto-Regular.ttf +Copyright: 2012 Google +License: Apache-2.0 + +Files: src/tools/kdb/gen/mustache.hpp: +Copyright: 2015-2018 Kevin Wojniak +License: BSL-1.0 + +License: BSD-3-clause + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions are met: + . + - Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + . + - Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + . + - Neither the name of Elektra nor the names of its contributors may + be used to endorse or promote products derived from this software without + specific prior written permission. + . + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND + ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR + ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +License: OFL-1.1 + This Font Software is licensed under the SIL Open Font License, Version 1.1. + This license is copied below, and is also available with a FAQ at: + http://scripts.sil.org/OFL + . + . + ----------------------------------------------------------- + SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007 + ----------------------------------------------------------- + . + PREAMBLE + The goals of the Open Font License (OFL) are to stimulate worldwide + development of collaborative font projects, to support the font creation + efforts of academic and linguistic communities, and to provide a free and + open framework in which fonts may be shared and improved in partnership + with others. + . + The OFL allows the licensed fonts to be used, studied, modified and + redistributed freely as long as they are not sold by themselves. The + fonts, including any derivative works, can be bundled, embedded, + redistributed and/or sold with any software provided that any reserved + names are not used by derivative works. The fonts and derivatives, + however, cannot be released under any other type of license. The + requirement for fonts to remain under this license does not apply + to any document created using the fonts or their derivatives. + . + DEFINITIONS + "Font Software" refers to the set of files released by the Copyright + Holder(s) under this license and clearly marked as such. This may + include source files, build scripts and documentation. + . + "Reserved Font Name" refers to any names specified as such after the + copyright statement(s). + . + "Original Version" refers to the collection of Font Software components as + distributed by the Copyright Holder(s). + . + "Modified Version" refers to any derivative made by adding to, deleting, + or substituting -- in part or in whole -- any of the components of the + Original Version, by changing formats or by porting the Font Software to a + new environment. + . + "Author" refers to any designer, engineer, programmer, technical + writer or other person who contributed to the Font Software. + . + PERMISSION & CONDITIONS + Permission is hereby granted, free of charge, to any person obtaining + a copy of the Font Software, to use, study, copy, merge, embed, modify, + redistribute, and sell modified and unmodified copies of the Font + Software, subject to the following conditions: + . + 1) Neither the Font Software nor any of its individual components, + in Original or Modified Versions, may be sold by itself. + . + 2) Original or Modified Versions of the Font Software may be bundled, + redistributed and/or sold with any software, provided that each copy + contains the above copyright notice and this license. These can be + included either as stand-alone text files, human-readable headers or + in the appropriate machine-readable metadata fields within text or + binary files as long as those fields can be easily viewed by the user. + . + 3) No Modified Version of the Font Software may use the Reserved Font + Name(s) unless explicit written permission is granted by the corresponding + Copyright Holder. This restriction only applies to the primary font name as + presented to the users. + . + 4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font + Software shall not be used to promote, endorse or advertise any + Modified Version, except to acknowledge the contribution(s) of the + Copyright Holder(s) and the Author(s) or with their explicit written + permission. + . + 5) The Font Software, modified or unmodified, in part or in whole, + must be distributed entirely under this license, and must not be + distributed under any other license. The requirement for fonts to + remain under this license does not apply to any document created + using the Font Software. + . + TERMINATION + This license becomes null and void if any of the above conditions are + not met. + . + DISCLAIMER + THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, + EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF + MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT + OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE + COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, + INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL + DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM + OTHER DEALINGS IN THE FONT SOFTWARE. + +License: MIT + Permission is hereby granted, free of charge, to any person obtaining a copy + of this software and associated documentation files (the "Software"), to deal + in the Software without restriction, including without limitation the rights + to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + . + The above copyright notice and this permission notice shall be included in all + copies or substantial portions of the Software. + . + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + SOFTWARE. + +License: Zlib + This software is provided 'as-is', without any express or implied + warranty. In no event will the authors be held liable for any damages + arising from the use of this software. + . + Permission is granted to anyone to use this software for any purpose, + including commercial applications, and to alter it and redistribute it + freely, subject to the following restrictions: + . + 1. The origin of this software must not be misrepresented; you must not + claim that you wrote the original software. If you use this software + in a product, an acknowledgment in the product documentation would be + appreciated but is not required. + . + 2. Altered source versions must be plainly marked as such, and must not be + misrepresented as being the original software. + . + 3. This notice may not be removed or altered from any source + distribution. + +License: BSL-1.0 + Permission is hereby granted, free of charge, to any person or organization + obtaining a copy of the software and accompanying documentation covered by + this license (the "Software") to use, reproduce, display, distribute, + execute, and transmit the Software, and to prepare derivative works of the + Software, and to permit third-parties to whom the Software is furnished to + do so, all subject to the following: + . + The copyright notices in the Software and this entire statement, including + the above license grant, this restriction and the following disclaimer, + must be included in all copies of the Software, in whole or in part, and + all derivative works of the Software, unless such copies or derivative + works are solely in the form of machine-executable object code generated by + a source language processor. + . + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT + SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE + FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE, + ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER + DEALINGS IN THE SOFTWARE. + +License: Apache-2.0 + On Debian GNU/Linux system you can find the complete text of the + Apache-2.0 license in `/usr/share/common-licenses/Apache-2.0' + +License: BSD-3-clause-cmake + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + . + 1. Redistributions of source code must retain the copyright + notice, this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + 3. The name of the author may not be used to endorse or promote products + derived from this software without specific prior written permission. + . + THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +License: BSD-2-clause-discount + Redistribution and use in source and binary forms, with or without modification, + are permitted provided that the following conditions are met: + . + * Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + . + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" + AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE + FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +License: BSD-3-clause-cmake-new + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + . + * Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + . + * Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + . + * Neither the names of Kitware, Inc., the Insight Software Consortium, + nor the names of their contributors may be used to endorse or promote + products derived from this software without specific prior written + permission. + . + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +License: BSD-3-clause-inih + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions are met: + * Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + * Neither the name of Brush Technology nor the names of its contributors + may be used to endorse or promote products derived from this software + without specific prior written permission. + . + THIS SOFTWARE IS PROVIDED BY BRUSH TECHNOLOGY ''AS IS'' AND ANY + EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + DISCLAIMED. IN NO EVENT SHALL BRUSH TECHNOLOGY BE LIABLE FOR ANY + DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND + ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +License: BSD-3-clause-markdownconverter + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions are + met: + . + (1) Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + . + (2) Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in + the documentation and/or other materials provided with the + distribution. + . + (3) The name of the author may not be used to + endorse or promote products derived from this software without + specific prior written permission. + . + THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, + INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, + STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING + IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. diff --git a/scripts/cmake/ElektraPackaging.cmake b/scripts/cmake/ElektraPackaging.cmake index 923cc5cd77e..bd9524bd5ac 100644 --- a/scripts/cmake/ElektraPackaging.cmake +++ b/scripts/cmake/ElektraPackaging.cmake @@ -107,13 +107,14 @@ if (UNIX) set (CPACK_GENERATOR "DEB") set (CPACK_DEBIAN_PACKAGE_PRIORITY "optional") set (CPACK_DEBIAN_PACKAGE_SOURCE "elektra") - # set (CPACK_DEBIAN_PACKAGE_SECTION "libs") set (CPACK_DEBIAN_PACKAGE_RECOMMENDS "") set (CPACK_DEBIAN_PACKAGE_DEPENDS "") # no dependencies without any PLUGINS set (CPACK_DEB_COMPONENT_INSTALL "ON") set (CPACK_DEB_PACKAGE_COMPONENT "ON") set (CPACK_DEBIAN_ENABLE_COMPONENT_DEPENDS "ON") + set (CPACK_DEBIAN_PACKAGE_SHLIBDEPS "ON") + set (CPACK_DEBIAN_PACKAGE_GENERATE_SHLIBS "ON") set (CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_NAME "libelektra4") set (CPACK_COMPONENT_LIBELEKTRA4_DISPLAY_NAME "libelektra4") @@ -378,16 +379,14 @@ if (UNIX) set (CPACK_DEBIAN_ELEKTRA-DBG_PACKAGE_SECTION "debug") # install copyright file + configure_file ("${CMAKE_SOURCE_DIR}/doc/THIRD-PARTY-LICENSES" "${CMAKE_BINARY_DIR}/doc/copyright" COPYONLY) foreach(component ${CPACK_COMPONENTS_ALL}) install ( - FILES "${CMAKE_SOURCE_DIR}/scripts/packaging/copyright" + FILES "${CMAKE_BINARY_DIR}/doc/copyright" COMPONENT ${component} DESTINATION "share/doc/${component}/") endforeach() - set (CPACK_DEBIAN_PACKAGE_SHLIBDEPS "ON") - set (CPACK_DEBIAN_PACKAGE_GENERATE_SHLIBS "ON") - # We need to alter the architecture names as per distro rules if ("${CPACK_PACKAGE_ARCHITECTURE}" MATCHES "i[3-6]86") set (CPACK_PACKAGE_ARCHITECTURE i386) diff --git a/scripts/packaging/copyright b/scripts/packaging/copyright deleted file mode 100644 index 8cc0fd8ac77..00000000000 --- a/scripts/packaging/copyright +++ /dev/null @@ -1,556 +0,0 @@ -Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ -Upstream-Name: Elektra -Upstream-Contact: Markus Raab -Source: http://www.libelektra.org/ftp/elektra/releases/ - -Files: * -Copyright: 2003-2004, 2006-2008, 2010, 2013-2014 Markus Raab - 2003-2005 Avi Alkalay - 2004 Vladimir Shabanov - 2006 Yannick Lecaillez - 2007 Patrick Sabin - 2013 Christian Loose - 2014-2015 Felix Berlakovich -License: BSD-3-clause - Redistribution and use in source and binary forms, with or without - modification, are permitted provided that the following conditions are met: - . - - Redistributions of source code must retain the above copyright notice, this - list of conditions and the following disclaimer. - . - - Redistributions in binary form must reproduce the above copyright notice, - this list of conditions and the following disclaimer in the documentation - and/or other materials provided with the distribution. - . - - Neither the name of Elektra nor the names of its contributors may - be used to endorse or promote products derived from this software without - specific prior written permission. - . - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND - ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED - WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR - ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES - (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; - LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS - SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -Files: cmake/Modules/DownloadProject* -Copyright: 2015 Craig Scott -License: MIT - -Files: cmake/Modules/FindAugeas.cmake - cmake/Modules/FindDBus.cmake - cmake/Modules/FindGObjectIntrospection.cmake - cmake/Modules/FindSystemdJournal.cmake -Copyright: 2006 Alexander Neundorf - 2008 Kevin Kofler - 2010 Pino Toscano - 2013 Martin Briza -License: BSD-3-clause-cmake - Redistribution and use in source and binary forms, with or without - modification, are permitted provided that the following conditions - are met: - . - 1. Redistributions of source code must retain the copyright - notice, this list of conditions and the following disclaimer. - 2. Redistributions in binary form must reproduce the copyright - notice, this list of conditions and the following disclaimer in the - documentation and/or other materials provided with the distribution. - 3. The name of the author may not be used to endorse or promote products - derived from this software without specific prior written permission. - . - THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR - IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. - IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, - INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT - NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, - DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY - THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF - THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -Files: cmake/Modules/FindDiscount.cmake -Copyright: 2013-2013 Lars Baehren -License: BSD-2-clause-discount - Redistribution and use in source and binary forms, with or without modification, - are permitted provided that the following conditions are met: - . - * Redistributions of source code must retain the above copyright notice, this - list of conditions and the following disclaimer. - * Redistributions in binary form must reproduce the above copyright notice, - this list of conditions and the following disclaimer in the documentation - and/or other materials provided with the distribution. - . - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" - AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE - FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER - CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE - OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -Files: cmake/Modules/FindLua52.cmake - cmake/Modules/FindPython2Interp.cmake - cmake/Modules/FindPython2Libs.cmake -Copyright: 2001-2010 Kitware, Inc. - 2011 Bjoern Ricks - 2012 Rolf Eike Beer -License: BSD-3-clause-cmake-new - Redistribution and use in source and binary forms, with or without - modification, are permitted provided that the following conditions - are met: - . - * Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. - . - * Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in the - documentation and/or other materials provided with the distribution. - . - * Neither the names of Kitware, Inc., the Insight Software Consortium, - nor the names of their contributors may be used to endorse or promote - products derived from this software without specific prior written - permission. - . - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR - A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT - HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, - DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY - THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE - OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -Files: src/plugins/ini/inih-r29/* -Copyright: 2009, Brush Technology -License: BSD-3-clause-inih - Redistribution and use in source and binary forms, with or without - modification, are permitted provided that the following conditions are met: - * Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. - * Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in the - documentation and/or other materials provided with the distribution. - * Neither the name of Brush Technology nor the names of its contributors - may be used to endorse or promote products derived from this software - without specific prior written permission. - . - THIS SOFTWARE IS PROVIDED BY BRUSH TECHNOLOGY ''AS IS'' AND ANY - EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED - WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - DISCLAIMED. IN NO EVENT SHALL BRUSH TECHNOLOGY BE LIABLE FOR ANY - DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES - (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; - LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS - SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -Files: src/plugins/ni/nickel-1.1.0/* -Copyright: 2008 Charles Lindsay -License: Zlib - This software is provided 'as-is', without any express or implied - warranty. In no event will the authors be held liable for any damages - arising from the use of this software. - . - Permission is granted to anyone to use this software for any purpose, - including commercial applications, and to alter it and redistribute it - freely, subject to the following restrictions: - . - 1. The origin of this software must not be misrepresented; you must not - claim that you wrote the original software. If you use this software - in a product, an acknowledgment in the product documentation would be - appreciated but is not required. - . - 2. Altered source versions must be plainly marked as such, and must not be - misrepresented as being the original software. - . - 3. This notice may not be removed or altered from any source - distribution. - -Files: src/plugins/ni/nickel-1.1.0/src/hash.c -Copyright: 2006 Bob Jenkins -License: public-domain - This is a trivially modified public domain hash library, lookup3.c, from: - http://burtleburtle.net/bob/hash/ - . - You can use this free for any purpose. It's in the public domain. - It has no warranty. - -Files: src/tools/rest-frontend/resources/assets/skin/base/util/space.less -Copyright: 2015 Ömer Aslanbakan -License: MIT - -Files: src/tools/rest-frontend/public/assets/fonts/lato/* -Copyright: 2010-2014 by tyPoland Lukasz Dziedzic (team@latofonts.com) with Reserved Font Name "Lato" -License: OFL-1.1 - -Files: src/tools/rest-frontend/public/assets/fonts/libre-franklin/* -Copyright: 2015 Impallari Type (www.impallari.com) -License: OFL-1.1 - -Files: src/tools/rest-frontend/public/assets/fonts/font-awesome/* -Copyright: 2016 Dave Gandy -License: OFL-1.1 - -Files: src/tools/rest-frontend/public/vendor/asciinema/asciinema-player.* -Copyright: 2011-2016 Marcin Kulik -License: Apache-2.0-asciinema - Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - . - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - . - 1. Definitions. - . - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - . - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - . - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - . - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - . - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - . - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - . - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - . - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - . - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - . - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - . - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - . - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - . - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - . - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - . - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - . - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - . - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - . - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - . - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - . - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - . - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - . - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - . - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - . - END OF TERMS AND CONDITIONS - . - APPENDIX: How to apply the Apache License to your work. - . - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "{}" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - . - Copyright 2011-2017 Marcin Kulik - . - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - . - http://www.apache.org/licenses/LICENSE-2.0 - . - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. - -Files: src/tools/rest-frontend/resources/assets/skin/base/fonts/font-awesome/* -Copyright: 2016 Dave Gandy -License: MIT - -Files: src/tools/qt-gui/src/markdownconverter/* -Copyright: 2013 Christian Loose -License: BSD-3-clause-markdownconverter - Redistribution and use in source and binary forms, with or without - modification, are permitted provided that the following conditions are - met: - . - (1) Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. - . - (2) Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in - the documentation and/or other materials provided with the - distribution. - . - (3) The name of the author may not be used to - endorse or promote products derived from this software without - specific prior written permission. - . - THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR - IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED - WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, - INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES - (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, - STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING - IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE. - -License: OFL-1.1 - This Font Software is licensed under the SIL Open Font License, Version 1.1. - This license is copied below, and is also available with a FAQ at: - http://scripts.sil.org/OFL - . - . - ----------------------------------------------------------- - SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007 - ----------------------------------------------------------- - . - PREAMBLE - The goals of the Open Font License (OFL) are to stimulate worldwide - development of collaborative font projects, to support the font creation - efforts of academic and linguistic communities, and to provide a free and - open framework in which fonts may be shared and improved in partnership - with others. - . - The OFL allows the licensed fonts to be used, studied, modified and - redistributed freely as long as they are not sold by themselves. The - fonts, including any derivative works, can be bundled, embedded, - redistributed and/or sold with any software provided that any reserved - names are not used by derivative works. The fonts and derivatives, - however, cannot be released under any other type of license. The - requirement for fonts to remain under this license does not apply - to any document created using the fonts or their derivatives. - . - DEFINITIONS - "Font Software" refers to the set of files released by the Copyright - Holder(s) under this license and clearly marked as such. This may - include source files, build scripts and documentation. - . - "Reserved Font Name" refers to any names specified as such after the - copyright statement(s). - . - "Original Version" refers to the collection of Font Software components as - distributed by the Copyright Holder(s). - . - "Modified Version" refers to any derivative made by adding to, deleting, - or substituting -- in part or in whole -- any of the components of the - Original Version, by changing formats or by porting the Font Software to a - new environment. - . - "Author" refers to any designer, engineer, programmer, technical - writer or other person who contributed to the Font Software. - . - PERMISSION & CONDITIONS - Permission is hereby granted, free of charge, to any person obtaining - a copy of the Font Software, to use, study, copy, merge, embed, modify, - redistribute, and sell modified and unmodified copies of the Font - Software, subject to the following conditions: - . - 1) Neither the Font Software nor any of its individual components, - in Original or Modified Versions, may be sold by itself. - . - 2) Original or Modified Versions of the Font Software may be bundled, - redistributed and/or sold with any software, provided that each copy - contains the above copyright notice and this license. These can be - included either as stand-alone text files, human-readable headers or - in the appropriate machine-readable metadata fields within text or - binary files as long as those fields can be easily viewed by the user. - . - 3) No Modified Version of the Font Software may use the Reserved Font - Name(s) unless explicit written permission is granted by the corresponding - Copyright Holder. This restriction only applies to the primary font name as - presented to the users. - . - 4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font - Software shall not be used to promote, endorse or advertise any - Modified Version, except to acknowledge the contribution(s) of the - Copyright Holder(s) and the Author(s) or with their explicit written - permission. - . - 5) The Font Software, modified or unmodified, in part or in whole, - must be distributed entirely under this license, and must not be - distributed under any other license. The requirement for fonts to - remain under this license does not apply to any document created - using the Font Software. - . - TERMINATION - This license becomes null and void if any of the above conditions are - not met. - . - DISCLAIMER - THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, - EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF - MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT - OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE - COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, - INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL - DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING - FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM - OTHER DEALINGS IN THE FONT SOFTWARE. - -License: MIT - Permission is hereby granted, free of charge, to any person obtaining a copy - of this software and associated documentation files (the "Software"), to deal - in the Software without restriction, including without limitation the rights - to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - copies of the Software, and to permit persons to whom the Software is - furnished to do so, subject to the following conditions: - . - The above copyright notice and this permission notice shall be included in all - copies or substantial portions of the Software. - . - THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - SOFTWARE. From 37aad1eceb8ea3a4c6cdfd77e9b24469437b9341 Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Fri, 11 Dec 2020 17:24:04 +0100 Subject: [PATCH 17/32] cpack: add maintainer and missing package dependency --- scripts/cmake/ElektraPackaging.cmake | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/scripts/cmake/ElektraPackaging.cmake b/scripts/cmake/ElektraPackaging.cmake index bd9524bd5ac..d8ce36d1cc0 100644 --- a/scripts/cmake/ElektraPackaging.cmake +++ b/scripts/cmake/ElektraPackaging.cmake @@ -8,6 +8,7 @@ set (CPACK_PACKAGE_VERSION "${PROJECT_VERSION}") set (CPACK_DEBIAN_PACKAGE_VERSION "${PROJECT_VERSION}") set (CPACK_DEBIAN_PACKAGE_RELEASE "1") set (CPACK_DEBIAN_FILE_NAME DEB-DEFAULT) +set (CPACK_DEBIAN_PACKAGE_MAINTAINER "Pino Toscano ") set ( CPACK_COMPONENTS_ALL @@ -45,7 +46,8 @@ set (DBG_PACKAGE_NAMES "") foreach(component ${CPACK_COMPONENTS_ALL}) list(APPEND DBG_PACKAGE_NAMES "${component}-dbgsym") endforeach() -list (FILTER DBG_PACKAGE_NAMES EXCLUDE REGEX "^elektra-doc.*") # elektra-doc doesn't contain dbgsym +# exclude all packages without dbgsym +list (FILTER DBG_PACKAGE_NAMES EXCLUDE REGEX "^elektra-doc.*") list (FILTER DBG_PACKAGE_NAMES EXCLUDE REGEX "^elektra-dbg.*") list (FILTER DBG_PACKAGE_NAMES EXCLUDE REGEX "^libelektra-dev.*") list (FILTER DBG_PACKAGE_NAMES EXCLUDE REGEX "^libelektra4-all.*") @@ -268,11 +270,11 @@ if (UNIX) set (CPACK_DEBIAN_LUA-ELEKTRA_PACKAGE_SECTION "interpreters") set (CPACK_DEBIAN_LUA-ELEKTRA_DEBUGINFO_PACKAGE "ON") - # maybe add python3:depends? (see control file) set (CPACK_DEBIAN_PYTHON3-ELEKTRA_PACKAGE_NAME "python3-elektra") set (CPACK_COMPONENT_PYTHON3-ELEKTRA_DISPLAY_NAME "python3-elektra") set (CPACK_COMPONENT_PYTHON3-ELEKTRA_DESCRIPTION "This package contains the Python 3 bindings.") set (CPACK_COMPONENT_PYTHON3-ELEKTRA_DEPENDS "libelektra4") + set (CPACK_DEBIAN_PYTHON3-ELEKTRA_PACKAGE_DEPENDS "python3") set (CPACK_DEBIAN_PYTHON3-ELEKTRA_PACKAGE_SECTION "python") set (CPACK_DEBIAN_PYTHON3-ELEKTRA_PACKAGE_CONTROL_STRICT_PERMISSION TRUE) file (GLOB CONTROL_FILES_PYTHON3-ELEKTRA "${CMAKE_SOURCE_DIR}/scripts/packaging/debian-control/python3-elektra/*") From 06877ff8cd4074c420c67ae8b1805c8aefe9e136 Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Fri, 11 Dec 2020 17:51:20 +0100 Subject: [PATCH 18/32] style: reformat --- scripts/cmake/ElektraPackaging.cmake | 16 ++++++++-------- scripts/cmake/Modules/LibAddMacros.cmake | 5 ++--- .../debian-control/elektra-bin/postinst | 2 +- .../packaging/debian-control/elektra-bin/postrm | 2 +- .../packaging/debian-control/elektra-bin/preinst | 2 +- .../debian-control/python3-elektra/postinst | 8 ++++---- .../debian-control/python3-elektra/prerm | 4 ++-- 7 files changed, 19 insertions(+), 20 deletions(-) diff --git a/scripts/cmake/ElektraPackaging.cmake b/scripts/cmake/ElektraPackaging.cmake index d8ce36d1cc0..903aeb3808f 100644 --- a/scripts/cmake/ElektraPackaging.cmake +++ b/scripts/cmake/ElektraPackaging.cmake @@ -43,12 +43,12 @@ list (FILTER ALL_PLUGINS INCLUDE REGEX "^libelektra4-.*") string (REPLACE ";" ", " ALL_PLUGINS_STR "${ALL_PLUGINS}") set (DBG_PACKAGE_NAMES "") -foreach(component ${CPACK_COMPONENTS_ALL}) - list(APPEND DBG_PACKAGE_NAMES "${component}-dbgsym") -endforeach() +foreach (component ${CPACK_COMPONENTS_ALL}) + list (APPEND DBG_PACKAGE_NAMES "${component}-dbgsym") +endforeach () # exclude all packages without dbgsym -list (FILTER DBG_PACKAGE_NAMES EXCLUDE REGEX "^elektra-doc.*") -list (FILTER DBG_PACKAGE_NAMES EXCLUDE REGEX "^elektra-dbg.*") +list (FILTER DBG_PACKAGE_NAMES EXCLUDE REGEX "^elektra-doc.*") +list (FILTER DBG_PACKAGE_NAMES EXCLUDE REGEX "^elektra-dbg.*") list (FILTER DBG_PACKAGE_NAMES EXCLUDE REGEX "^libelektra-dev.*") list (FILTER DBG_PACKAGE_NAMES EXCLUDE REGEX "^libelektra4-all.*") list (FILTER DBG_PACKAGE_NAMES EXCLUDE REGEX "^elektra-bin-extra.*") @@ -372,7 +372,7 @@ if (UNIX) CPACK_DEBIAN_LIBELEKTRA4-ALL_PACKAGE_DEPENDS "libelektra4, libelektra4-experimental, libelektra4-augeas, libelektra4-dbus, libelektra4-zeromq, libelektra4-lua, libelektra4-python, libelektra4-xmltool, libelektra4-xerces, libelektra4-yajl, lua-elektra, elektra-bin, elektra-qt-gui, libelektra4-crypto, libelektra4-curl, libelektra4-journald, libelektra4-extra" ) - set (CPACK_DEBIAN_LIBELEKTRA4-ALL_PACKAGE_RECOMMENDS "elektra-tests, elektra-doc, elektra-dbg, libelektra-dev") + set (CPACK_DEBIAN_LIBELEKTRA4-ALL_PACKAGE_RECOMMENDS "elektra-tests, elektra-doc, elektra-dbg, libelektra-dev") set (CPACK_DEBIAN_ELEKTRA-DBG_PACKAGE_NAME "elektra-dbg") set (CPACK_COMPONENT_ELEKTRA-DBG_DISPLAY_NAME "elektra-dbg") @@ -382,12 +382,12 @@ if (UNIX) # install copyright file configure_file ("${CMAKE_SOURCE_DIR}/doc/THIRD-PARTY-LICENSES" "${CMAKE_BINARY_DIR}/doc/copyright" COPYONLY) - foreach(component ${CPACK_COMPONENTS_ALL}) + foreach (component ${CPACK_COMPONENTS_ALL}) install ( FILES "${CMAKE_BINARY_DIR}/doc/copyright" COMPONENT ${component} DESTINATION "share/doc/${component}/") - endforeach() + endforeach () # We need to alter the architecture names as per distro rules if ("${CPACK_PACKAGE_ARCHITECTURE}" MATCHES "i[3-6]86") diff --git a/scripts/cmake/Modules/LibAddMacros.cmake b/scripts/cmake/Modules/LibAddMacros.cmake index 99655414883..a319198d75e 100644 --- a/scripts/cmake/Modules/LibAddMacros.cmake +++ b/scripts/cmake/Modules/LibAddMacros.cmake @@ -68,7 +68,6 @@ macro (create_lib_symlink src dest component) COMPONENT "${component}") endmacro (create_lib_symlink src dest component) - # ~~~ # Create a symlink for man1 files at installation # @@ -655,8 +654,8 @@ If you do not add this file, then installing Elektra will fail!\n") if (BUILD_STATIC) if (SECTION EQUAL 1) - create_doc_symlink("kdb.${SECTION}" "kdb-static.${SECTION}" "${ARG_COMPONENT}") - endif() + create_doc_symlink ("kdb.${SECTION}" "kdb-static.${SECTION}" "${ARG_COMPONENT}") + endif () endif () endif () endif (BUILD_DOCUMENTATION) diff --git a/scripts/packaging/debian-control/elektra-bin/postinst b/scripts/packaging/debian-control/elektra-bin/postinst index b230b05ea05..55e86b0714e 100644 --- a/scripts/packaging/debian-control/elektra-bin/postinst +++ b/scripts/packaging/debian-control/elektra-bin/postinst @@ -1,4 +1,4 @@ #!/bin/sh set -e -dpkg-maintscript-helper rm_conffile /etc/bash_completion.d/kdb 0.8.11-1~ -- "$@" \ No newline at end of file +dpkg-maintscript-helper rm_conffile /etc/bash_completion.d/kdb 0.8.11-1~ -- "$@" diff --git a/scripts/packaging/debian-control/elektra-bin/postrm b/scripts/packaging/debian-control/elektra-bin/postrm index b230b05ea05..55e86b0714e 100644 --- a/scripts/packaging/debian-control/elektra-bin/postrm +++ b/scripts/packaging/debian-control/elektra-bin/postrm @@ -1,4 +1,4 @@ #!/bin/sh set -e -dpkg-maintscript-helper rm_conffile /etc/bash_completion.d/kdb 0.8.11-1~ -- "$@" \ No newline at end of file +dpkg-maintscript-helper rm_conffile /etc/bash_completion.d/kdb 0.8.11-1~ -- "$@" diff --git a/scripts/packaging/debian-control/elektra-bin/preinst b/scripts/packaging/debian-control/elektra-bin/preinst index b230b05ea05..55e86b0714e 100644 --- a/scripts/packaging/debian-control/elektra-bin/preinst +++ b/scripts/packaging/debian-control/elektra-bin/preinst @@ -1,4 +1,4 @@ #!/bin/sh set -e -dpkg-maintscript-helper rm_conffile /etc/bash_completion.d/kdb 0.8.11-1~ -- "$@" \ No newline at end of file +dpkg-maintscript-helper rm_conffile /etc/bash_completion.d/kdb 0.8.11-1~ -- "$@" diff --git a/scripts/packaging/debian-control/python3-elektra/postinst b/scripts/packaging/debian-control/python3-elektra/postinst index cf00e14be93..e24c09fcf14 100644 --- a/scripts/packaging/debian-control/python3-elektra/postinst +++ b/scripts/packaging/debian-control/python3-elektra/postinst @@ -1,9 +1,9 @@ #!/bin/sh set -e -if which py3compile >/dev/null 2>&1; then - py3compile -p python3-elektra +if which py3compile > /dev/null 2>&1; then + py3compile -p python3-elektra fi -if which pypy3compile >/dev/null 2>&1; then - pypy3compile -p python3-elektra || true +if which pypy3compile > /dev/null 2>&1; then + pypy3compile -p python3-elektra || true fi diff --git a/scripts/packaging/debian-control/python3-elektra/prerm b/scripts/packaging/debian-control/python3-elektra/prerm index b573bc7542d..007cd4519d5 100644 --- a/scripts/packaging/debian-control/python3-elektra/prerm +++ b/scripts/packaging/debian-control/python3-elektra/prerm @@ -1,8 +1,8 @@ #!/bin/sh set -e -if which py3clean >/dev/null 2>&1; then - py3clean -p python3-elektra +if which py3clean > /dev/null 2>&1; then + py3clean -p python3-elektra else dpkg -L python3-elektra | perl -ne 's,/([^/]*)\.py$,/__pycache__/\1.*, or next; unlink $_ or die $! foreach glob($_)' find /usr/lib/python3/dist-packages/ -type d -name __pycache__ -empty -print0 | xargs --null --no-run-if-empty rmdir From 2121a44b7e96d2d042675eb61315d85cc3bebb80 Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Fri, 11 Dec 2020 18:07:07 +0100 Subject: [PATCH 19/32] cmake: add docu for component parameter --- doc/CMakeLists.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/doc/CMakeLists.txt b/doc/CMakeLists.txt index 8b1ba63088d..41fb9a7491a 100644 --- a/doc/CMakeLists.txt +++ b/doc/CMakeLists.txt @@ -9,6 +9,7 @@ find_package (Doxygen QUIET) # folder is the folder where it will be built # file is the file name to set a dependency to # install is where it should be installed +# target_component is the component name for component-specifc installation # ~~~ macro (do_doc target folder file install target_component) From e324b22a9d3a6464e062189fbadafc5b05d57950 Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Fri, 11 Dec 2020 19:23:54 +0100 Subject: [PATCH 20/32] cmake: fix incompatibility with cmake 3.5 remove list(FILTER ..) because it is not availbale on cmake version < 3.6 --- scripts/cmake/ElektraPackaging.cmake | 22 +++++++++++++--------- 1 file changed, 13 insertions(+), 9 deletions(-) diff --git a/scripts/cmake/ElektraPackaging.cmake b/scripts/cmake/ElektraPackaging.cmake index 903aeb3808f..9ed313f857f 100644 --- a/scripts/cmake/ElektraPackaging.cmake +++ b/scripts/cmake/ElektraPackaging.cmake @@ -38,21 +38,25 @@ set ( elektra-tests elektra-dbg) -set (ALL_PLUGINS ${CPACK_COMPONENTS_ALL}) -list (FILTER ALL_PLUGINS INCLUDE REGEX "^libelektra4-.*") +set (COMPONENTS_WITHOUT_DBGSYM elektra-doc elektra-dbg libelektra-dev libelektra4-all elektra-bin-extra) + +set (ALL_PLUGINS "") +foreach(component ${CPACK_COMPONENTS_ALL}) + if (component MATCHES "^libelektra4-.*") + list (APPEND ALL_PLUGINS "${component}") + endif() +endforeach() string (REPLACE ";" ", " ALL_PLUGINS_STR "${ALL_PLUGINS}") +message(STATUS "ALL_PLUGINS_STR: ${ALL_PLUGINS_STR}") set (DBG_PACKAGE_NAMES "") foreach (component ${CPACK_COMPONENTS_ALL}) - list (APPEND DBG_PACKAGE_NAMES "${component}-dbgsym") + if (NOT component IN_LIST COMPONENTS_WITHOUT_DBGSYM) + list (APPEND DBG_PACKAGE_NAMES "${component}-dbgsym") + endif () endforeach () -# exclude all packages without dbgsym -list (FILTER DBG_PACKAGE_NAMES EXCLUDE REGEX "^elektra-doc.*") -list (FILTER DBG_PACKAGE_NAMES EXCLUDE REGEX "^elektra-dbg.*") -list (FILTER DBG_PACKAGE_NAMES EXCLUDE REGEX "^libelektra-dev.*") -list (FILTER DBG_PACKAGE_NAMES EXCLUDE REGEX "^libelektra4-all.*") -list (FILTER DBG_PACKAGE_NAMES EXCLUDE REGEX "^elektra-bin-extra.*") string (REPLACE ";" ", " DBG_PACKAGE_NAMES_STR "${DBG_PACKAGE_NAMES}") +message(STATUS "DBG_PACKAGE_NAMES_STR: ${DBG_PACKAGE_NAMES_STR}") set ( PACKAGE_DESCRIPTION From 7223844cbf14f7065313ca6f1d1c30ce3098bf7e Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Fri, 11 Dec 2020 19:39:31 +0100 Subject: [PATCH 21/32] cmake: fix error on optional macro parameter --- doc/CMakeLists.txt | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/doc/CMakeLists.txt b/doc/CMakeLists.txt index 41fb9a7491a..d4ebcf20427 100644 --- a/doc/CMakeLists.txt +++ b/doc/CMakeLists.txt @@ -9,9 +9,15 @@ find_package (Doxygen QUIET) # folder is the folder where it will be built # file is the file name to set a dependency to # install is where it should be installed -# target_component is the component name for component-specifc installation # ~~~ -macro (do_doc target folder file install target_component) +macro (do_doc target folder file install) + + cmake_parse_arguments ( + ARG + "" # optional keywords + "COMPONENT" # one value keywords + "" # multi value keywords + ${ARGN}) # sometimes doxygen is too slow and fails with "Could not create output directory .../doc/html" file (MAKE_DIRECTORY ${folder}) @@ -23,7 +29,7 @@ macro (do_doc target folder file install target_component) if (INSTALL_DOCUMENTATION) install ( DIRECTORY ${folder} - COMPONENT ${target_component} + COMPONENT "${ARG_COMPONENT}" DESTINATION ${install}) endif (INSTALL_DOCUMENTATION) endmacro (do_doc) @@ -78,8 +84,8 @@ if (DOXYGEN_FOUND) OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile INPUT ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile) - do_doc (html ${OUTPUT_DIRECTORY}/html/ index.html ${TARGET_DOCUMENTATION_HTML_FOLDER} elektra-doc) - do_doc (man3 ${OUTPUT_DIRECTORY}/man/man3elektra/ kdb.3elektra "${TARGET_DOCUMENTATION_MAN_FOLDER};PATTERN;_*;EXCLUDE" elektra-doc) + do_doc (html ${OUTPUT_DIRECTORY}/html/ index.html ${TARGET_DOCUMENTATION_HTML_FOLDER} COMPONENT elektra-doc) + do_doc (man3 ${OUTPUT_DIRECTORY}/man/man3elektra/ kdb.3elektra "${TARGET_DOCUMENTATION_MAN_FOLDER};PATTERN;_*;EXCLUDE" COMPONENT elektra-doc) add_dependencies (man3 html) set (outputs ${OUTPUT_DIRECTORY}/html/index.html ${OUTPUT_DIRECTORY}/man/man3elektra/kdb.3elektra) From 7f02c6b933b1d6cbd8ed4dbef95ae672e592f2ba Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Fri, 11 Dec 2020 20:06:34 +0100 Subject: [PATCH 22/32] style: reformat --- doc/CMakeLists.txt | 3 ++- scripts/cmake/ElektraPackaging.cmake | 8 +++----- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/doc/CMakeLists.txt b/doc/CMakeLists.txt index d4ebcf20427..bbf670c4a26 100644 --- a/doc/CMakeLists.txt +++ b/doc/CMakeLists.txt @@ -85,7 +85,8 @@ if (DOXYGEN_FOUND) INPUT ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile) do_doc (html ${OUTPUT_DIRECTORY}/html/ index.html ${TARGET_DOCUMENTATION_HTML_FOLDER} COMPONENT elektra-doc) - do_doc (man3 ${OUTPUT_DIRECTORY}/man/man3elektra/ kdb.3elektra "${TARGET_DOCUMENTATION_MAN_FOLDER};PATTERN;_*;EXCLUDE" COMPONENT elektra-doc) + do_doc (man3 ${OUTPUT_DIRECTORY}/man/man3elektra/ kdb.3elektra "${TARGET_DOCUMENTATION_MAN_FOLDER};PATTERN;_*;EXCLUDE" COMPONENT + elektra-doc) add_dependencies (man3 html) set (outputs ${OUTPUT_DIRECTORY}/html/index.html ${OUTPUT_DIRECTORY}/man/man3elektra/kdb.3elektra) diff --git a/scripts/cmake/ElektraPackaging.cmake b/scripts/cmake/ElektraPackaging.cmake index 9ed313f857f..cd10fe7828b 100644 --- a/scripts/cmake/ElektraPackaging.cmake +++ b/scripts/cmake/ElektraPackaging.cmake @@ -41,13 +41,12 @@ set ( set (COMPONENTS_WITHOUT_DBGSYM elektra-doc elektra-dbg libelektra-dev libelektra4-all elektra-bin-extra) set (ALL_PLUGINS "") -foreach(component ${CPACK_COMPONENTS_ALL}) +foreach (component ${CPACK_COMPONENTS_ALL}) if (component MATCHES "^libelektra4-.*") list (APPEND ALL_PLUGINS "${component}") - endif() -endforeach() + endif () +endforeach () string (REPLACE ";" ", " ALL_PLUGINS_STR "${ALL_PLUGINS}") -message(STATUS "ALL_PLUGINS_STR: ${ALL_PLUGINS_STR}") set (DBG_PACKAGE_NAMES "") foreach (component ${CPACK_COMPONENTS_ALL}) @@ -56,7 +55,6 @@ foreach (component ${CPACK_COMPONENTS_ALL}) endif () endforeach () string (REPLACE ";" ", " DBG_PACKAGE_NAMES_STR "${DBG_PACKAGE_NAMES}") -message(STATUS "DBG_PACKAGE_NAMES_STR: ${DBG_PACKAGE_NAMES_STR}") set ( PACKAGE_DESCRIPTION From ab6d936e98f0b98ab7f4f7d68e0322a70fbebfa6 Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Sat, 12 Dec 2020 22:37:49 +0100 Subject: [PATCH 23/32] packaging: apply suggestions from review --- scripts/cmake/ElektraPackaging.cmake | 65 +++++++++---------- .../debian-control/elektra-bin/postinst | 4 -- .../debian-control/elektra-bin/postrm | 4 -- .../debian-control/elektra-bin/preinst | 4 -- .../debian-control/elektra-bin/prerm | 4 -- .../debian-control/elektra-bin/triggers | 1 - 6 files changed, 30 insertions(+), 52 deletions(-) delete mode 100644 scripts/packaging/debian-control/elektra-bin/postinst delete mode 100644 scripts/packaging/debian-control/elektra-bin/postrm delete mode 100644 scripts/packaging/debian-control/elektra-bin/preinst delete mode 100644 scripts/packaging/debian-control/elektra-bin/prerm delete mode 100644 scripts/packaging/debian-control/elektra-bin/triggers diff --git a/scripts/cmake/ElektraPackaging.cmake b/scripts/cmake/ElektraPackaging.cmake index cd10fe7828b..48fae9bb8d3 100644 --- a/scripts/cmake/ElektraPackaging.cmake +++ b/scripts/cmake/ElektraPackaging.cmake @@ -7,8 +7,11 @@ set (PROJECT_VERSION "${KDB_VERSION}") set (CPACK_PACKAGE_VERSION "${PROJECT_VERSION}") set (CPACK_DEBIAN_PACKAGE_VERSION "${PROJECT_VERSION}") set (CPACK_DEBIAN_PACKAGE_RELEASE "1") +set (DEBIAN_VERSION_RELEASE "${CPACK_DEBIAN_PACKAGE_VERSION}-${CPACK_DEBIAN_PACKAGE_RELEASE}") set (CPACK_DEBIAN_FILE_NAME DEB-DEFAULT) -set (CPACK_DEBIAN_PACKAGE_MAINTAINER "Pino Toscano ") +set (CPACK_DEBIAN_PACKAGE_MAINTAINER "Robert Sowula ") + +set (CPACK_OUTPUT_FILE_PREFIX "packages") set ( CPACK_COMPONENTS_ALL @@ -61,7 +64,6 @@ set ( "Elektra provides a universal and secure framework to store configuration parameters in a global, hierarchical key database. The core is a small library implemented in C. The plugin-based framework fulfills many configuration-related tasks to avoid any unnecessary code duplication across applications while it still allows the core to stay without any external dependency. Elektra abstracts from cross-platform-related issues with an consistent API, and allows applications to be aware of other applications' configurations, leveraging easy application integration.\n." ) set (CPACK_PACKAGE_DESCRIPTION_SUMMARY "${PACKAGE_DESCRIPTION}") -set (CPACK_PACKAGE_CONTACT "${PACKAGE_URL}") set ( CPACK_SOURCE_IGNORE_FILES "/.cvsignore" @@ -111,8 +113,6 @@ if (UNIX) set (CPACK_GENERATOR "DEB") set (CPACK_DEBIAN_PACKAGE_PRIORITY "optional") set (CPACK_DEBIAN_PACKAGE_SOURCE "elektra") - set (CPACK_DEBIAN_PACKAGE_RECOMMENDS "") - set (CPACK_DEBIAN_PACKAGE_DEPENDS "") # no dependencies without any PLUGINS set (CPACK_DEB_COMPONENT_INSTALL "ON") set (CPACK_DEB_PACKAGE_COMPONENT "ON") @@ -125,9 +125,9 @@ if (UNIX) set (CPACK_COMPONENT_LIBELEKTRA4_DESCRIPTION "This package contains the main elektra library, and most of the core plugins") set (CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_SECTION "libs") set (CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_BREAKS - "elektra-bin (<< 0.8.14-5~), libelektra-core4 (<< 0.8.19-1), libelektra-full4 (<< 0.8.19-1)") + "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelektra-core4 (<< ${DEBIAN_VERSION_RELEASE}), libelektra-full4 (<< ${DEBIAN_VERSION_RELEASE})") set (CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_REPLACES - "elektra-bin (<< 0.8.14-5~), libelelektra-core4 (<< 0.8.19-1), libelektra-full4 (<< 0.8.19-1)") + "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelelektra-core4 (<< ${DEBIAN_VERSION_RELEASE}), libelektra-full4 (<< ${DEBIAN_VERSION_RELEASE})") set (CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_SUGGESTS "elektra-doc, ${ALL_PLUGINS_STR}") set (CPACK_DEBIAN_LIBELEKTRA4_DEBUGINFO_PACKAGE "ON") @@ -138,9 +138,9 @@ if (UNIX) are linked together to a full library. The package is only needed for testing.") set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_SECTION "libs") set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_BREAKS - "elektra-bin (<< 0.8.14-5~), libelektra-core4 (<< 0.8.19-1), libelektra-full4 (<< 0.8.19-1)") + "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelektra-core4 (<< ${DEBIAN_VERSION_RELEASE}), libelektra-full4 (<< ${DEBIAN_VERSION_RELEASE})") set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_REPLACES - "elektra-bin (<< 0.8.14-5~), libelelektra-core4 (<< 0.8.19-1), libelektra-full4 (<< 0.8.19-1)") + "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelelektra-core4 (<< ${DEBIAN_VERSION_RELEASE}), libelektra-full4 (<< ${DEBIAN_VERSION_RELEASE})") set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_CONFLICTS "libelektra4 (<< ${CPACK_DEBIAN_PACKAGE_VERSION}), elektra-tests (<< ${CPACK_DEBIAN_PACKAGE_VERSION})") set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_SUGGESTS "elektra-doc, ${ALL_PLUGINS_STR}") @@ -150,8 +150,8 @@ if (UNIX) set (CPACK_COMPONENT_LIBELEKTRA4-EXPERIMENTAL_DISPLAY_NAME "libelektra4-experimental") set (CPACK_COMPONENT_LIBELEKTRA4-EXPERIMENTAL_DESCRIPTION "This package contains experimental plugins.") set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_PACKAGE_SECTION "libs") - set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_PACKAGE_BREAKS "elektra-bin (<< 0.8.14-5~), libelektra-core4 (<< 0.8.19-1)") - set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_PACKAGE_REPLACES "elektra-bin (<< 0.8.14-5~), libelelektra-core4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_PACKAGE_BREAKS "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelektra-core4 (<< ${DEBIAN_VERSION_RELEASE})") + set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_PACKAGE_REPLACES "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelelektra-core4 (<< ${DEBIAN_VERSION_RELEASE})") set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_PACKAGE_SUGGESTS "elektra-doc, ${ALL_PLUGINS_STR}") set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_DEBUGINFO_PACKAGE "ON") @@ -159,8 +159,8 @@ if (UNIX) set (CPACK_COMPONENT_LIBELEKTRA4-EXTRA_DISPLAY_NAME "libelektra4-extra") set (CPACK_COMPONENT_LIBELEKTRA4-EXTRA_DESCRIPTION "This package contains extra plugins.") set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_PACKAGE_SECTION "libs") - set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_PACKAGE_BREAKS "elektra-bin (<< 0.8.14-5~), libelektra-core4 (<< 0.8.19-1)") - set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_PACKAGE_REPLACES "elektra-bin (<< 0.8.14-5~), libelelektra-core4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_PACKAGE_BREAKS "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelektra-core4 (<< ${DEBIAN_VERSION_RELEASE})") + set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_PACKAGE_REPLACES "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelelektra-core4 (<< ${DEBIAN_VERSION_RELEASE})") set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_PACKAGE_SUGGESTS "elektra-doc, ${ALL_PLUGINS_STR}") set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_DEBUGINFO_PACKAGE "ON") @@ -169,14 +169,9 @@ if (UNIX) set (CPACK_COMPONENT_ELEKTRA-BIN_DESCRIPTION "This package contains command line utilities for Elektra.") set (CPACK_COMPONENT_ELEKTRA-BIN_DEPENDS "libelektra4") set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_SECTION "misc") - set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_BREAKS "elektra-bin (<< 0.8.14-5~),libelektra-full4 (<< 0.8.19-1)") - set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_REPLACES "elektra-bin (<< 0.8.14-5~), libelektra-full4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_BREAKS "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}),libelektra-full4 (<< ${DEBIAN_VERSION_RELEASE})") + set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_REPLACES "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelektra-full4 (<< ${DEBIAN_VERSION_RELEASE})") set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_CONFLICTS "kernel-patch-kdb") - set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_CONTROL_STRICT_PERMISSION TRUE) - file (GLOB CONTROL_FILES_ELEKTRA-BIN "${CMAKE_SOURCE_DIR}/scripts/packaging/debian-control/elektra-bin/*") - file (COPY ${CONTROL_FILES_ELEKTRA-BIN} DESTINATION "${CMAKE_BINARY_DIR}/scripts/packaging/debian-control/elektra-bin/") - file (GLOB CONTROL_FILES_ELEKTRA-BIN_BINARY "${CMAKE_BINARY_DIR}/scripts/packaging/debian-control/elektra-bin/*") - set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_CONTROL_EXTRA "${CONTROL_FILES_ELEKTRA-BIN_BINARY}") set (CPACK_DEBIAN_ELEKTRA-BIN_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_LIBELEKTRA4-AUGEAS_PACKAGE_NAME "libelektra4-augeas") @@ -184,8 +179,8 @@ if (UNIX) set (CPACK_COMPONENT_LIBELEKTRA4-AUGEAS_DESCRIPTION "This package contains the 'augeas' plugin.") set (CPACK_COMPONENT_LIBELEKTRA4-AUGEAS_DEPENDS "libelektra4") set (CPACK_DEBIAN_LIBELEKTRA4-AUGEAS_PACKAGE_SECTION "libs") - set (CPACK_DEBIAN_LIBELEKTRA4-AUGEAS_PACKAGE_BREAKS "libelektra-augeas4 (<< 0.8.19-1)") - set (CPACK_DEBIAN_LIBELEKTRA4-AUGEAS_PACKAGE_REPLACES "libelektra-augeas4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-AUGEAS_PACKAGE_BREAKS "libelektra-augeas4 (<< ${DEBIAN_VERSION_RELEASE})") + set (CPACK_DEBIAN_LIBELEKTRA4-AUGEAS_PACKAGE_REPLACES "libelektra-augeas4 (<< ${DEBIAN_VERSION_RELEASE})") set (CPACK_DEBIAN_LIBELEKTRA4-AUGEAS_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_LIBELEKTRA4-DBUS_PACKAGE_NAME "libelektra4-dbus") @@ -193,8 +188,8 @@ if (UNIX) set (CPACK_COMPONENT_LIBELEKTRA4-DBUS_DESCRIPTION "This package contains the 'dbus' plugins.") set (CPACK_COMPONENT_LIBELEKTRA4-DBUS_DEPENDS "libelektra4") set (CPACK_DEBIAN_LIBELEKTRA4-DBUS_PACKAGE_SECTION "libs") - set (CPACK_DEBIAN_LIBELEKTRA4-DBUS_PACKAGE_BREAKS "libelektra-dbus4 (<< 0.8.19-1)") - set (CPACK_DEBIAN_LIBELEKTRA4-DBUS_PACKAGE_REPLACES "libelektra-dbus4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-DBUS_PACKAGE_BREAKS "libelektra-dbus4 (<< ${DEBIAN_VERSION_RELEASE})") + set (CPACK_DEBIAN_LIBELEKTRA4-DBUS_PACKAGE_REPLACES "libelektra-dbus4 (<< ${DEBIAN_VERSION_RELEASE})") set (CPACK_DEBIAN_LIBELEKTRA4-DBUS_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_LIBELEKTRA-DEV_PACKAGE_NAME "libelektra-dev") @@ -215,8 +210,8 @@ if (UNIX) set (CPACK_COMPONENT_LIBELEKTRA4-XMLTOOL_DESCRIPTION "This package contains the 'xmltool' plugin.") set (CPACK_COMPONENT_LIBELEKTRA4-XMLTOOL_DEPENDS "libelektra4") set (CPACK_DEBIAN_LIBELEKTRA4-XMLTOOL_PACKAGE_SECTION "libs") - set (CPACK_DEBIAN_LIBELEKTRA4-XMLTOOL_PACKAGE_BREAKS "libelektra-xmltool4 (<< 0.8.19-1)") - set (CPACK_DEBIAN_LIBELEKTRA4-XMLTOOL_PACKAGE_REPLACES "libelektra-xmltool4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-XMLTOOL_PACKAGE_BREAKS "libelektra-xmltool4 (<< ${DEBIAN_VERSION_RELEASE})") + set (CPACK_DEBIAN_LIBELEKTRA4-XMLTOOL_PACKAGE_REPLACES "libelektra-xmltool4 (<< ${DEBIAN_VERSION_RELEASE})") set (CPACK_DEBIAN_LIBELEKTRA4-XMLTOOL_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_LIBELEKTRA4-XERCES_PACKAGE_NAME "libelektra4-xerces") @@ -224,8 +219,8 @@ if (UNIX) set (CPACK_COMPONENT_LIBELEKTRA4-XERCES_DESCRIPTION "This package contains the 'xerces' plugin.") set (CPACK_COMPONENT_LIBELEKTRA4-XERCES_DEPENDS "libelektra4") set (CPACK_DEBIAN_LIBELEKTRA4-XERCES_PACKAGE_SECTION "libs") - set (CPACK_DEBIAN_LIBELEKTRA4-XERCES_PACKAGE_BREAKS "libelektra-xerces4 (<< 0.8.19-1)") - set (CPACK_DEBIAN_LIBELEKTRA4-XERCES_PACKAGE_REPLACES "libelektra-xerces4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-XERCES_PACKAGE_BREAKS "libelektra-xerces4 (<< ${DEBIAN_VERSION_RELEASE})") + set (CPACK_DEBIAN_LIBELEKTRA4-XERCES_PACKAGE_REPLACES "libelektra-xerces4 (<< ${DEBIAN_VERSION_RELEASE})") set (CPACK_DEBIAN_LIBELEKTRA4-XERCES_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_LIBELEKTRA4-YAJL_PACKAGE_NAME "libelektra4-yajl") @@ -233,8 +228,8 @@ if (UNIX) set (CPACK_COMPONENT_LIBELEKTRA4-YAJL_DESCRIPTION "This package contains the 'yajl' plugin.") set (CPACK_COMPONENT_LIBELEKTRA4-YAJL_DEPENDS "libelektra4") set (CPACK_DEBIAN_LIBELEKTRA4-YAJL_PACKAGE_SECTION "libs") - set (CPACK_DEBIAN_LIBELEKTRA4-YAJL_PACKAGE_BREAKS "libelektra-yajl4 (<< 0.8.19-1)") - set (CPACK_DEBIAN_LIBELEKTRA4-YAJL_PACKAGE_REPLACES "libelektra-yajl4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-YAJL_PACKAGE_BREAKS "libelektra-yajl4 (<< ${DEBIAN_VERSION_RELEASE})") + set (CPACK_DEBIAN_LIBELEKTRA4-YAJL_PACKAGE_REPLACES "libelektra-yajl4 (<< ${DEBIAN_VERSION_RELEASE})") set (CPACK_DEBIAN_LIBELEKTRA4-YAJL_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_LIBELEKTRA4-CRYPTO_PACKAGE_NAME "libelektra4-crypto") @@ -291,8 +286,8 @@ if (UNIX) set (CPACK_COMPONENT_LIBELEKTRA4-PYTHON_DESCRIPTION "This package contains the 'python' plugin.") set (CPACK_COMPONENT_LIBELEKTRA4-PYTHON_DEPENDS "libelektra4" "python3-elektra") set (CPACK_DEBIAN_LIBELEKTRA4-PYTHON_PACKAGE_SECTION "libs") - set (CPACK_DEBIAN_LIBELEKTRA4-PYTHON_PACKAGE_BREAKS "libelelektra-python4 (<< 0.8.19-1)") - set (CPACK_DEBIAN_LIBELEKTRA4-PYTHON_PACKAGE_REPLACES "libelelektra-python4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_LIBELEKTRA4-PYTHON_PACKAGE_BREAKS "libelelektra-python4 (<< ${DEBIAN_VERSION_RELEASE})") + set (CPACK_DEBIAN_LIBELEKTRA4-PYTHON_PACKAGE_REPLACES "libelelektra-python4 (<< ${DEBIAN_VERSION_RELEASE})") set (CPACK_DEBIAN_LIBELEKTRA4-PYTHON_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_ELEKTRA-BIN-EXTRA_PACKAGE_NAME "elektra-bin-extra") @@ -330,8 +325,8 @@ if (UNIX) set (CPACK_COMPONENT_ELEKTRA-TESTS_DEPENDS "libelektra4-full" "elektra-bin") set (CPACK_DEBIAN_ELEKTRA-TESTS_PACKAGE_SECTION "misc") set (CPACK_DEBIAN_ELEKTRA-TESTS_PACKAGE_PRIORITY "extra") - set (CPACK_DEBIAN_ELEKTRA-TESTS_PACKAGE_BREAKS "libelektra-test (<< 0.8.19-1), libelektra-full4 (<< 0.8.19-1)") - set (CPACK_DEBIAN_ELEKTRA-TESTS_PACKAGE_REPLACES "libelektra-test (<< 0.8.19-1), libelektra-full4 (<< 0.8.19-1)") + set (CPACK_DEBIAN_ELEKTRA-TESTS_PACKAGE_BREAKS "libelektra-test (<<${DEBIAN_VERSION_RELEASE}), libelektra-full4 (<< ${DEBIAN_VERSION_RELEASE})") + set (CPACK_DEBIAN_ELEKTRA-TESTS_PACKAGE_REPLACES "libelektra-test (<< ${DEBIAN_VERSION_RELEASE}), libelektra-full4 (<< ${DEBIAN_VERSION_RELEASE})") set (CPACK_DEBIAN_ELEKTRA-TESTS_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_ELEKTRA-DOC_PACKAGE_NAME "elektra-doc") @@ -339,8 +334,8 @@ if (UNIX) set (CPACK_COMPONENT_ELEKTRA-DOC_DESCRIPTION "This package contains the API documentation for the Elektra libraries.") set (CPACK_DEBIAN_ELEKTRA-DOC_PACKAGE_ARCHITECTURE "all") set (CPACK_DEBIAN_ELEKTRA-DOC_PACKAGE_SECTION "doc") - set (CPACK_DEBIAN_ELEKTRA-DOC_PACKAGE_BREAKS "libelektra-doc (<< 0.8.19-1)") - set (CPACK_DEBIAN_ELEKTRA-DOC_PACKAGE_REPLACES "libelektra-doc (<< 0.8.19-1)") + set (CPACK_DEBIAN_ELEKTRA-DOC_PACKAGE_BREAKS "libelektra-doc (<< ${DEBIAN_VERSION_RELEASE})") + set (CPACK_DEBIAN_ELEKTRA-DOC_PACKAGE_REPLACES "libelektra-doc (<< ${DEBIAN_VERSION_RELEASE})") install ( FILES "${CMAKE_SOURCE_DIR}/scripts/packaging/doc-base/elektra-doc" COMPONENT elektra-doc diff --git a/scripts/packaging/debian-control/elektra-bin/postinst b/scripts/packaging/debian-control/elektra-bin/postinst deleted file mode 100644 index 55e86b0714e..00000000000 --- a/scripts/packaging/debian-control/elektra-bin/postinst +++ /dev/null @@ -1,4 +0,0 @@ -#!/bin/sh -set -e - -dpkg-maintscript-helper rm_conffile /etc/bash_completion.d/kdb 0.8.11-1~ -- "$@" diff --git a/scripts/packaging/debian-control/elektra-bin/postrm b/scripts/packaging/debian-control/elektra-bin/postrm deleted file mode 100644 index 55e86b0714e..00000000000 --- a/scripts/packaging/debian-control/elektra-bin/postrm +++ /dev/null @@ -1,4 +0,0 @@ -#!/bin/sh -set -e - -dpkg-maintscript-helper rm_conffile /etc/bash_completion.d/kdb 0.8.11-1~ -- "$@" diff --git a/scripts/packaging/debian-control/elektra-bin/preinst b/scripts/packaging/debian-control/elektra-bin/preinst deleted file mode 100644 index 55e86b0714e..00000000000 --- a/scripts/packaging/debian-control/elektra-bin/preinst +++ /dev/null @@ -1,4 +0,0 @@ -#!/bin/sh -set -e - -dpkg-maintscript-helper rm_conffile /etc/bash_completion.d/kdb 0.8.11-1~ -- "$@" diff --git a/scripts/packaging/debian-control/elektra-bin/prerm b/scripts/packaging/debian-control/elektra-bin/prerm deleted file mode 100644 index 55e86b0714e..00000000000 --- a/scripts/packaging/debian-control/elektra-bin/prerm +++ /dev/null @@ -1,4 +0,0 @@ -#!/bin/sh -set -e - -dpkg-maintscript-helper rm_conffile /etc/bash_completion.d/kdb 0.8.11-1~ -- "$@" diff --git a/scripts/packaging/debian-control/elektra-bin/triggers b/scripts/packaging/debian-control/elektra-bin/triggers deleted file mode 100644 index dd866036784..00000000000 --- a/scripts/packaging/debian-control/elektra-bin/triggers +++ /dev/null @@ -1 +0,0 @@ -activate-noawait ldconfig From 66810545e50996bff7761db8c78c73665c668f4b Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Sat, 12 Dec 2020 22:38:43 +0100 Subject: [PATCH 24/32] doc: change copyright field to reference authors file --- doc/AUTHORS | 1 - doc/THIRD-PARTY-LICENSES | 12 +++--------- 2 files changed, 3 insertions(+), 10 deletions(-) delete mode 100644 doc/AUTHORS diff --git a/doc/AUTHORS b/doc/AUTHORS deleted file mode 100644 index f39616e5541..00000000000 --- a/doc/AUTHORS +++ /dev/null @@ -1 +0,0 @@ -The list of authors was moved to a new file: AUTHORS.md diff --git a/doc/THIRD-PARTY-LICENSES b/doc/THIRD-PARTY-LICENSES index c36d79ed4f1..4b71e2f3e46 100644 --- a/doc/THIRD-PARTY-LICENSES +++ b/doc/THIRD-PARTY-LICENSES @@ -1,16 +1,10 @@ -Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ +Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Upstream-Name: Elektra Upstream-Contact: Markus Raab -Source: http://www.libelektra.org/ftp/elektra/releases/ +Source: https://www.libelektra.org/ftp/elektra/releases/ Files: * -Copyright: 2003-2004, 2006-2008, 2010, 2013-2014 Markus Raab - 2003-2005 Avi Alkalay - 2004 Vladimir Shabanov - 2006 Yannick Lecaillez - 2007 Patrick Sabin - 2013 Christian Loose - 2014-2015 Felix Berlakovich +Copyright: Elektra contributors (https://www.libelektra.org/developers/authors) License: BSD-3-clause Files: cmake/Modules/DownloadProject* From 97da809b6617bafcdb697f20679ce814310f7e1c Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Sun, 13 Dec 2020 00:15:04 +0100 Subject: [PATCH 25/32] packaging: add debian changelog --- scripts/cmake/ElektraPackaging.cmake | 17 ++ scripts/packaging/debian/changelog | 293 +++++++++++++++++++++++++++ 2 files changed, 310 insertions(+) create mode 100644 scripts/packaging/debian/changelog diff --git a/scripts/cmake/ElektraPackaging.cmake b/scripts/cmake/ElektraPackaging.cmake index 48fae9bb8d3..816a437aae6 100644 --- a/scripts/cmake/ElektraPackaging.cmake +++ b/scripts/cmake/ElektraPackaging.cmake @@ -386,6 +386,23 @@ if (UNIX) DESTINATION "share/doc/${component}/") endforeach () + # compress and install changelog + add_custom_command( + OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/changelog.Debian.gz" + COMMAND gzip -cn9 "debian/changelog" > "${CMAKE_CURRENT_BINARY_DIR}/changelog.Debian.gz" + WORKING_DIRECTORY "${CMAKE_SOURCE_DIR}/scripts/packaging" + COMMENT "Compressing changelog" + ) + + add_custom_target(changelog ALL DEPENDS "${CMAKE_CURRENT_BINARY_DIR}/changelog.Debian.gz") + + foreach (component ${CPACK_COMPONENTS_ALL}) + install ( + FILES "${CMAKE_CURRENT_BINARY_DIR}/changelog.Debian.gz" + COMPONENT ${component} + DESTINATION "share/doc/${component}/") + endforeach () + # We need to alter the architecture names as per distro rules if ("${CPACK_PACKAGE_ARCHITECTURE}" MATCHES "i[3-6]86") set (CPACK_PACKAGE_ARCHITECTURE i386) diff --git a/scripts/packaging/debian/changelog b/scripts/packaging/debian/changelog new file mode 100644 index 00000000000..91bf7e9b94e --- /dev/null +++ b/scripts/packaging/debian/changelog @@ -0,0 +1,293 @@ +elektra (0.9.3-1) unstable; urgency=medium + + * New upstream version. + + -- Jenkins (User for Elektra automated build system) Fri, 30 Oct 2020 20:36:20 +0000 + +elektra (0.9.2-1) unstable; urgency=medium + + * New upstream version. + + -- Mihael Pranjic Tue, 26 May 2020 18:26:23 +0200 + +elektra (0.9.1-2) unstable; urgency=medium + + [ Mihael Pranjic ] + * New upstream version. + + [ Markus Raab ] + * 0.9.1-2 Bump version. + + -- Markus Raab Fri, 22 May 2020 21:42:39 +0200 + +elektra (0.9.0-1) unstable; urgency=medium + + * New upstream version. + + -- Markus Raab Tue, 06 Aug 2019 11:52:57 +0200 + +elektra (0.8.26-1) unstable; urgency=medium + + * New upstream version. + + -- Markus Raab Tue, 26 Feb 2019 14:28:01 +0100 + +elektra (0.8.25-1) unstable; urgency=medium + + * New upstream version. + + -- Markus Raab Sun, 18 Nov 2018 21:02:34 +0100 + +elektra (0.8.24-1) unstable; urgency=medium + + * New upstream version. + + -- Markus Raab Sat, 18 Aug 2018 21:55:30 +0200 + +elektra (0.8.23-1) unstable; urgency=medium + + * New upstream version. + + -- Markus Raab Sun, 13 May 2018 19:12:55 +0200 + +elektra (0.8.22-1) unstable; urgency=medium + + * New upstream version. + + -- Markus Raab Tue, 27 Feb 2018 20:27:03 +0100 + +elektra (0.8.21-1) unstable; urgency=medium + + * New upstream version. + + -- Markus Raab Fri, 22 Dec 2017 09:03:01 +0100 + +elektra (0.8.20-1) unstable; urgency=medium + + * New upstream version. + + -- Markus Raab Tue, 31 Oct 2017 22:44:16 +0100 + +elektra (0.8.19-1) unstable; urgency=medium + + * New upstream version. + + -- Markus Raab Tue, 22 Nov 2016 22:02:22 +0100 + +elektra (0.8.18-1) unstable; urgency=medium + + * New upstream version. + + -- Markus Raab Sat, 17 Sep 2016 01:04:14 +0200 + +elektra (0.8.17-1) unstable; urgency=medium + + * New upstream version. + + -- Markus Raab Tue, 14 Jun 2016 19:28:38 +0200 + +elektra (0.8.16-1) unstable; urgency=medium + + * New upstream version. + + -- Markus Raab Fri, 29 Apr 2016 16:41:05 +0200 + +elektra (0.8.15-1) unstable; urgency=medium + + * New upstream version + + -- Markus Raab Tue, 16 Feb 2016 17:29:41 +0100 + +elektra (0.8.14-1) unstable; urgency=medium + + * New upstream version. + + -- Markus Raab Thu, 19 Nov 2015 20:34:45 +0100 + +elektra (0.8.13-1) unstable; urgency=medium + + * added 3 plugins in debian/libelektra-core4.install (not yet merged/released) + * New upstream version. + + -- Markus Raab Thu, 17 Sep 2015 19:42:21 +0200 + +elektra (0.8.12-1) unstable; urgency=low + + * New upstream version. + + -- Markus Raab Mon, 13 Jul 2015 20:47:01 +0200 + +elektra (0.8.11-1) unstable; urgency=low + + * New upstream version. + + -- Markus Raab Fri, 03 Apr 2015 01:11:43 +0200 + +elektra (0.8.10-1) unstable; urgency=low + + * New upstream version. + + -- Markus Raab Tue, 02 Dec 2014 11:24:13 +0100 + +elektra (0.8.9-2) unstable; urgency=low + + * New upstream version. + + -- Markus Raab Tue, 04 Nov 2014 10:40:50 +0100 + +elektra (0.8.7-2) unstable; urgency=low + + * Fix installation of contextual and other gen templates + + -- Markus Raab Mon, 28 Jul 2014 20:37:07 +0200 + +elektra (0.8.7-1) unstable; urgency=low + + * New upstream version. + + -- Markus Raab Mon, 28 Jul 2014 10:33:00 +0200 + +elektra (0.8.6-2) unstable; urgency=low + + * Add augeas plugin. + * Add python bindings. + + -- Markus Raab Fri, 20 Jun 2014 11:45:40 +0200 + +elektra (0.8.6-1) unstable; urgency=low + + * New upstream version. + + -- Markus Raab Wed, 04 Jun 2014 17:04:27 +0200 + +elektra (0.8.5-2) unstable; urgency=low + + * Add gen and all packages. + + -- Markus Raab Mon, 05 Mar 2014 20:35:12 +0100 + +elektra (0.8.5-1) unstable; urgency=low + + * New upstream version. + + -- Markus Raab Mon, 03 Mar 2014 22:20:32 +0100 + +elektra (0.8.4-2) unstable; urgency=low + + * Fix problems reported by lintian + * Fix which files to install + * Add docu as separate package + + -- Markus Raab Sat, 21 Dec 2013 22:34:06 +0100 + +elektra (0.8.4-1) unstable; urgency=low + + * New upstream version. + + -- Markus Raab Sat, 21 Dec 2013 19:49:33 +0100 + +elektra (0.8.3-2) unstable; urgency=low + + * Add test package (containing unit tests) + * Do not run tests (broken in cowbuilder) + + -- Markus Raab Mon, 01 Oct 2012 20:40:46 +0200 + +elektra (0.8.3-1) unstable; urgency=low + + * New upstream version. + + -- Markus Raab Mon, 01 Oct 2012 19:30:47 +0200 + +elektra (0.8.1-1) unstable; urgency=low + + * New upstream version. + + -- Markus Raab Sat, 09 Jun 2012 14:13:41 +0200 + +elektra (0.8.0-1) unstable; urgency=low + + * New upstream version. + + -- Markus Raab Fri, 04 May 2012 14:31:28 +0200 + +elektra (0.8.0rc5-1) unstable; urgency=low + + * New upstream version. + + -- Markus Raab Fri, 04 May 2012 09:36:29 +0200 + +elektra (0.8.0rc4-1) unstable; urgency=low + + * New upstream version. + + -- Markus Raab Thu, 03 May 2012 10:00:46 +0200 + +elektra (0.8.0rc3-1) unstable; urgency=low + + * New upstream version. + + -- Markus Raab Tue, 01 May 2012 23:15:48 +0200 + +elektra (0.8.0rc1-1) unstable; urgency=low + + * Elektra 0.8.0 repackaging + + -- Markus Raab Thu, 05 Apr 2012 19:01:05 +0200 + +elektra (0.8.0rc0-1) unstable; urgency=low + + * Elektra 0.8.0 packaging with cmake + + -- Markus Raab Wed, 22 Feb 2012 16:42:02 +0100 + +elektra (0.7.0a1-1) unstable; urgency=low + + * New upstream version. + * Repackaged using CDBS. + * Removed menu file, as it makes little sense for kdb(1). + + -- Andreas Rottmann Thu, 22 Mar 2007 13:32:59 +0100 + +elektra (0.5) unstable; urgency=low + + * Split to bin and dev packages. + + -- Pier Luigi Fiorini Mon, 25 Apr 2005 19:44:10 +0200 + +elektra (0.5) unstable; urgency=low + + * Stabilize api. Won't changed during 0.5 development. + + -- Markus Raab Tue, 3 May 2005 08:26:02 +0200 + +elektra (0.4.11-5) unstable; urgency=low + + * Update to 0.4.11-5 + + -- Markus Raab Fri, 25 Mar 2005 09:35:14 +0100 + +elektra (0.4.7-2) unstable; urgency=low + + * Sarge Integrate and Update to 0.4.7 + + -- Markus Raab Thu, 05 Dec 2004 12:55:10 +0200 + +elektra (0.4.4-2) unstable; urgency=low + + * Updated to current Version + + -- Markus Raab Thu, 23 Sep 2004 12:55:10 +0200 + +elektra (0.4.4-1) unstable; urgency=low + + * Some Updates + + -- Markus Raab Thu, 23 Sep 2004 12:55:10 +0200 + +elektra (0.4.2-1) unstable; urgency=low + + * Initial Release. + + -- Markus Raab Thu, 23 Sep 2004 12:55:10 +0200 + From 546d7a0a604c465fb6667c8b28c6812682ec3075 Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Sun, 13 Dec 2020 00:27:06 +0100 Subject: [PATCH 26/32] packaging: change folder structure --- scripts/cmake/ElektraPackaging.cmake | 8 ++++---- .../control}/python3-elektra/postinst | 0 .../control}/python3-elektra/prerm | 0 scripts/packaging/{ => debian}/doc-base/elektra-doc | 0 4 files changed, 4 insertions(+), 4 deletions(-) rename scripts/packaging/{debian-control => debian/control}/python3-elektra/postinst (100%) rename scripts/packaging/{debian-control => debian/control}/python3-elektra/prerm (100%) rename scripts/packaging/{ => debian}/doc-base/elektra-doc (100%) diff --git a/scripts/cmake/ElektraPackaging.cmake b/scripts/cmake/ElektraPackaging.cmake index 816a437aae6..69ed5893b2d 100644 --- a/scripts/cmake/ElektraPackaging.cmake +++ b/scripts/cmake/ElektraPackaging.cmake @@ -274,10 +274,10 @@ if (UNIX) set (CPACK_DEBIAN_PYTHON3-ELEKTRA_PACKAGE_DEPENDS "python3") set (CPACK_DEBIAN_PYTHON3-ELEKTRA_PACKAGE_SECTION "python") set (CPACK_DEBIAN_PYTHON3-ELEKTRA_PACKAGE_CONTROL_STRICT_PERMISSION TRUE) - file (GLOB CONTROL_FILES_PYTHON3-ELEKTRA "${CMAKE_SOURCE_DIR}/scripts/packaging/debian-control/python3-elektra/*") + file (GLOB CONTROL_FILES_PYTHON3-ELEKTRA "${CMAKE_SOURCE_DIR}/scripts/packaging/debian/control/python3-elektra/*") file (COPY ${CONTROL_FILES_PYTHON3-ELEKTRA} - DESTINATION "${CMAKE_BINARY_DIR}/scripts/packaging/debian-control/python3-elektra/") - file (GLOB CONTROL_FILES_PYTHON3-ELEKTRA_BINARY "${CMAKE_BINARY_DIR}/scripts/packaging/debian-control/python3-elektra/*") + DESTINATION "${CMAKE_BINARY_DIR}/scripts/packaging/debian/control/python3-elektra/") + file (GLOB CONTROL_FILES_PYTHON3-ELEKTRA_BINARY "${CMAKE_BINARY_DIR}/scripts/packaging/debian/control/python3-elektra/*") set (CPACK_DEBIAN_PYTHON3-ELEKTRA_PACKAGE_CONTROL_EXTRA "${CONTROL_FILES_PYTHON3-ELEKTRA_BINARY}") set (CPACK_DEBIAN_PYTHON3-ELEKTRA_DEBUGINFO_PACKAGE "ON") @@ -337,7 +337,7 @@ if (UNIX) set (CPACK_DEBIAN_ELEKTRA-DOC_PACKAGE_BREAKS "libelektra-doc (<< ${DEBIAN_VERSION_RELEASE})") set (CPACK_DEBIAN_ELEKTRA-DOC_PACKAGE_REPLACES "libelektra-doc (<< ${DEBIAN_VERSION_RELEASE})") install ( - FILES "${CMAKE_SOURCE_DIR}/scripts/packaging/doc-base/elektra-doc" + FILES "${CMAKE_SOURCE_DIR}/scripts/packaging/debian/doc-base/elektra-doc" COMPONENT elektra-doc DESTINATION ${TARGET_DOCUMENTATION_DOC-BASE_FOLDER}) diff --git a/scripts/packaging/debian-control/python3-elektra/postinst b/scripts/packaging/debian/control/python3-elektra/postinst similarity index 100% rename from scripts/packaging/debian-control/python3-elektra/postinst rename to scripts/packaging/debian/control/python3-elektra/postinst diff --git a/scripts/packaging/debian-control/python3-elektra/prerm b/scripts/packaging/debian/control/python3-elektra/prerm similarity index 100% rename from scripts/packaging/debian-control/python3-elektra/prerm rename to scripts/packaging/debian/control/python3-elektra/prerm diff --git a/scripts/packaging/doc-base/elektra-doc b/scripts/packaging/debian/doc-base/elektra-doc similarity index 100% rename from scripts/packaging/doc-base/elektra-doc rename to scripts/packaging/debian/doc-base/elektra-doc From 882feb32d16d302c1e0c56f1a3712a7bd9608fdd Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Sun, 13 Dec 2020 01:41:18 +0100 Subject: [PATCH 27/32] news: add cpack as highlight to release notes --- doc/news/_preparation_next_release.md | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/doc/news/_preparation_next_release.md b/doc/news/_preparation_next_release.md index 76e4a85e4be..1f6b417f741 100644 --- a/doc/news/_preparation_next_release.md +++ b/doc/news/_preparation_next_release.md @@ -26,7 +26,7 @@ You can also read the news [on our website](https://www.libelektra.org/news/0.9. ## Highlights - Important Changes to Keynames -- <> +- Debian Packaging with CPack - <> ### Important Changes to Keynames @@ -46,7 +46,9 @@ If you rely on specific behaviour of Elektra's Keynames and have already taken t - Fix combining dot-dot parts and escapes in key names. _(Klemens Böswirth)_ - Fix adding more than 10 warnings to a key. _(Klemens Böswirth)_ -### <> +### Debian Packaging with CPack + +We are now using CPack to generate modular Debian and Ubuntu packages. This simplifies the packaging process and solves problems where a PR that introduces changes to installed files, fails. We can now also set distribution specifc dependencies with CPack, which is needed for some packages. _Robert Sowula_ ### <> @@ -162,7 +164,6 @@ you up to date with the multi-language support provided by Elektra. ### CMake - Use Lua 5.4 when available. _(Mihael Pranjić)_ -- We now use CPack to build modular Debian and Ubuntu packages. _(Robert Sowula)_ - <> - Force `RTLD_NODELETE` on dlopen() when the `ENABLE_ASAN` CMake option is used. This enables ASAN to find symbols which otherwise might be unloaded. _(Mihael Pranjić)_ - <> From 9446af276f0bf76b92f90f5d0f4d485828b266a4 Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Sun, 13 Dec 2020 01:56:35 +0100 Subject: [PATCH 28/32] doc: add myself to authors.md --- doc/AUTHORS.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/doc/AUTHORS.md b/doc/AUTHORS.md index 1af35a64a04..c66dceddb23 100644 --- a/doc/AUTHORS.md +++ b/doc/AUTHORS.md @@ -211,3 +211,11 @@ development of KConfig plugin and changes on qt-gui - email: mail@dardan.im - github user: [darddan](https://github.com/darddan) - devel/test on: Arch Linux + +## Robert Sowula + +debian packaging, release automation + +- email: robert@sowula.at +- github user: [robaerd](https://github.com/robaerd) +- devel/test on: Debian, Ubuntu From b72b85a9a48459a4218543d4c5b8a060531479d9 Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Sun, 13 Dec 2020 03:19:08 +0100 Subject: [PATCH 29/32] packaging: add default component elektra-misc All files that are not part of a released package are packaged into the elektra-misc package --- doc/CMakeLists.txt | 8 +++++++- scripts/cmake/ElektraPackaging.cmake | 12 ++++++++++-- scripts/cmake/Modules/LibAddLib.cmake | 8 +++++++- scripts/cmake/Modules/LibAddMacros.cmake | 10 ++++++++-- scripts/cmake/Modules/LibAddPlugin.cmake | 8 +++++++- src/bindings/glib/CMakeLists.txt | 6 +++--- src/bindings/gsettings/CMakeLists.txt | 4 ++-- src/bindings/io/doc/CMakeLists.txt | 4 ++-- src/bindings/io/ev/CMakeLists.txt | 2 +- src/bindings/io/glib/CMakeLists.txt | 2 +- src/bindings/io/uv/CMakeLists.txt | 2 +- src/bindings/jna/CMakeLists.txt | 2 +- src/bindings/swig/ruby/CMakeLists.txt | 4 ++-- src/include/kdbio/CMakeLists.txt | 6 +++--- src/libs/merge/CMakeLists.txt | 2 +- src/plugins/ruby/CMakeLists.txt | 2 +- src/tools/elektrad/CMakeLists.txt | 6 +++--- src/tools/gen-gpg-testkey/CMakeLists.txt | 2 +- src/tools/hub-zeromq/CMakeLists.txt | 4 ++-- src/tools/pythongen/CMakeLists.txt | 6 +++--- src/tools/webd/CMakeLists.txt | 16 +++++++--------- src/tools/website/CMakeLists.txt | 9 ++++----- src/tools/webui/CMakeLists.txt | 14 ++++++-------- 23 files changed, 83 insertions(+), 56 deletions(-) diff --git a/doc/CMakeLists.txt b/doc/CMakeLists.txt index bbf670c4a26..91796924c48 100644 --- a/doc/CMakeLists.txt +++ b/doc/CMakeLists.txt @@ -19,6 +19,12 @@ macro (do_doc target folder file install) "" # multi value keywords ${ARGN}) + if (ARG_COMPONENT) + set (HAS_COMPONENT ${ARG_COMPONENT}) + else () + set (HAS_COMPONENT "elektra-misc") + endif () + # sometimes doxygen is too slow and fails with "Could not create output directory .../doc/html" file (MAKE_DIRECTORY ${folder}) @@ -29,7 +35,7 @@ macro (do_doc target folder file install) if (INSTALL_DOCUMENTATION) install ( DIRECTORY ${folder} - COMPONENT "${ARG_COMPONENT}" + COMPONENT "${HAS_COMPONENT}" DESTINATION ${install}) endif (INSTALL_DOCUMENTATION) endmacro (do_doc) diff --git a/scripts/cmake/ElektraPackaging.cmake b/scripts/cmake/ElektraPackaging.cmake index 69ed5893b2d..b22ab6c6488 100644 --- a/scripts/cmake/ElektraPackaging.cmake +++ b/scripts/cmake/ElektraPackaging.cmake @@ -39,7 +39,8 @@ set ( elektra-doc elektra-qt-gui elektra-tests - elektra-dbg) + elektra-dbg + elektra-misc) set (COMPONENTS_WITHOUT_DBGSYM elektra-doc elektra-dbg libelektra-dev libelektra4-all elektra-bin-extra) @@ -53,7 +54,7 @@ string (REPLACE ";" ", " ALL_PLUGINS_STR "${ALL_PLUGINS}") set (DBG_PACKAGE_NAMES "") foreach (component ${CPACK_COMPONENTS_ALL}) - if (NOT component IN_LIST COMPONENTS_WITHOUT_DBGSYM) + if (NOT component IN_LIST COMPONENTS_WITHOUT_DBGSYM AND NOT component STREQUAL "elektra-misc") list (APPEND DBG_PACKAGE_NAMES "${component}-dbgsym") endif () endforeach () @@ -377,6 +378,13 @@ if (UNIX) set (CPACK_DEBIAN_ELEKTRA-DBG_PACKAGE_DEPENDS "${DBG_PACKAGE_NAMES_STR}") set (CPACK_DEBIAN_ELEKTRA-DBG_PACKAGE_SECTION "debug") + set (CPACK_DEBIAN_ELEKTRA-MISC_PACKAGE_NAME "elektra-misc") + set (CPACK_COMPONENT_ELEKTRA-MISC_DISPLAY_NAME "elektra-misc") + set (CPACK_COMPONENT_ELEKTRA-MISC_DESCRIPTION "This package contains all files not part of any of the released Elektra packages.") + set (CPACK_DEBIAN_ELEKTRA-MISC_PACKAGE_ARCHITECTURE "all") + set (CPACK_DEBIAN_ELEKTRA-MISC_PACKAGE_SECTION "misc") + set (CPACK_DEBIAN_ELEKTRA-MISC_DEBUGINFO_PACKAGE "ON") + # install copyright file configure_file ("${CMAKE_SOURCE_DIR}/doc/THIRD-PARTY-LICENSES" "${CMAKE_BINARY_DIR}/doc/copyright" COPYONLY) foreach (component ${CPACK_COMPONENTS_ALL}) diff --git a/scripts/cmake/Modules/LibAddLib.cmake b/scripts/cmake/Modules/LibAddLib.cmake index 23769d6b2ff..4537e197ca6 100644 --- a/scripts/cmake/Modules/LibAddLib.cmake +++ b/scripts/cmake/Modules/LibAddLib.cmake @@ -23,6 +23,12 @@ function (add_lib name) add_cppheaders (ARG_SOURCES) endif (ARG_CPP) + if (ARG_COMPONENT) + set (HAS_COMPONENT ${ARG_COMPONENT}) + else () + set (HAS_COMPONENT "elektra-misc") + endif () + add_library (elektra-${name}-objects OBJECT ${ARG_SOURCES}) add_dependencies (elektra-${name}-objects generate_version_script) target_include_directories (elektra-${name}-objects PUBLIC ${ARG_INCLUDE_DIRECTORIES}) @@ -58,7 +64,7 @@ function (add_lib name) install ( TARGETS elektra-${name} DESTINATION lib${LIB_SUFFIX} - COMPONENT "${ARG_COMPONENT}" + COMPONENT "${HAS_COMPONENT}" EXPORT ElektraTargetsLibelektra) endif (BUILD_SHARED) diff --git a/scripts/cmake/Modules/LibAddMacros.cmake b/scripts/cmake/Modules/LibAddMacros.cmake index a319198d75e..b462a5219db 100644 --- a/scripts/cmake/Modules/LibAddMacros.cmake +++ b/scripts/cmake/Modules/LibAddMacros.cmake @@ -621,6 +621,12 @@ function (generate_manpage NAME) set (MDFILE ${CMAKE_CURRENT_SOURCE_DIR}/${NAME}.md) endif () + if (ARG_COMPONENT) + set (HAS_COMPONENT ${ARG_COMPONENT}) + else () + set (HAS_COMPONENT "elektra-misc") + endif () + set (MAN_PAGE_LOCATION "doc/man/man${SECTION}/${NAME}.${SECTION}") set (OUTFILE "${CMAKE_SOURCE_DIR}/${MAN_PAGE_LOCATION}") @@ -650,11 +656,11 @@ If you do not add this file, then installing Elektra will fail!\n") install ( FILES ${OUTFILE} DESTINATION share/man/man${SECTION} - COMPONENT "${ARG_COMPONENT}") + COMPONENT "${HAS_COMPONENT}") if (BUILD_STATIC) if (SECTION EQUAL 1) - create_doc_symlink ("kdb.${SECTION}" "kdb-static.${SECTION}" "${ARG_COMPONENT}") + create_doc_symlink ("kdb.${SECTION}" "kdb-static.${SECTION}" "${HAS_COMPONENT}") endif () endif () endif () diff --git a/scripts/cmake/Modules/LibAddPlugin.cmake b/scripts/cmake/Modules/LibAddPlugin.cmake index 3aa2f9cf077..f5f51a1bc3b 100644 --- a/scripts/cmake/Modules/LibAddPlugin.cmake +++ b/scripts/cmake/Modules/LibAddPlugin.cmake @@ -436,6 +436,12 @@ function (add_plugin PLUGIN_SHORT_NAME) message (FATAL_ERROR "Parsed a wrong argument to plugin ${PLUGIN_SHORT_NAME}: ${ARG_UNPARSED_ARGUMENTS}") endif () + if (ARG_COMPONENT) + set (HAS_COMPONENT ${ARG_COMPONENT}) + else () + set (HAS_COMPONENT "elektra-misc") + endif () + if (ADDTESTING_PHASE) if (ARG_INSTALL_TEST_DATA AND NOT ARG_ADD_TEST) if (INSTALL_TESTING) @@ -628,7 +634,7 @@ function (add_plugin PLUGIN_SHORT_NAME) install ( TARGETS ${PLUGIN_NAME} DESTINATION lib${LIB_SUFFIX}/${TARGET_PLUGIN_FOLDER} - COMPONENT "${ARG_COMPONENT}") + COMPONENT "${HAS_COMPONENT}") set_property ( TARGET ${PLUGIN_NAME} APPEND diff --git a/src/bindings/glib/CMakeLists.txt b/src/bindings/glib/CMakeLists.txt index dd2e2a26f03..c4c199ef847 100644 --- a/src/bindings/glib/CMakeLists.txt +++ b/src/bindings/glib/CMakeLists.txt @@ -42,15 +42,15 @@ target_compile_options (${GELEKTRA_LIBRARY} PUBLIC ${GOBJECT_CFLAGS_OTHER}) target_link_libraries (${GELEKTRA_LIBRARY} PUBLIC elektra-core elektra-kdb) target_link_libraries (${GELEKTRA_LIBRARY} PUBLIC ${GOBJECT_LDFLAGS}) -install (TARGETS ${GELEKTRA_LIBRARY} LIBRARY DESTINATION lib${LIB_SUFFIX}) +install (TARGETS ${GELEKTRA_LIBRARY} LIBRARY DESTINATION lib${LIB_SUFFIX} COMPONENT elektra-misc) -install (FILES ${GELEKTRA_HDR_FILES} DESTINATION include/${TARGET_INCLUDE_FOLDER}) +install (FILES ${GELEKTRA_HDR_FILES} DESTINATION include/${TARGET_INCLUDE_FOLDER} COMPONENT elektra-misc) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/gelektra-constants.h.in" "${CMAKE_CURRENT_BINARY_DIR}/gelektra-constants.h" @ONLY) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/gelektra.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/${GELEKTRA_LIBRARY}.pc" @ONLY) -install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${GELEKTRA_LIBRARY}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER}) +install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${GELEKTRA_LIBRARY}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} COMPONENT elektra-misc) if (BUILD_TESTING) add_subdirectory (tests) diff --git a/src/bindings/gsettings/CMakeLists.txt b/src/bindings/gsettings/CMakeLists.txt index c519f3283ca..c0ce0e31674 100644 --- a/src/bindings/gsettings/CMakeLists.txt +++ b/src/bindings/gsettings/CMakeLists.txt @@ -57,7 +57,7 @@ if (GELEKTRA_LIBRARY) include_directories (${CMAKE_BINARY_DIR}/src/include/) target_link_libraries (elektrasettings ${GLIB_LIBRARIES} ${GMODULE_LIBRARIES} ${GIO_LIBRARIES} ${GELEKTRA_LIBRARY} elektra-core) if (INSTALL_SYSTEM_FILES) - install (TARGETS elektrasettings LIBRARY DESTINATION ${GIO_MODULE_DIR}) + install (TARGETS elektrasettings LIBRARY DESTINATION ${GIO_MODULE_DIR} COMPONENT elektra-misc) endif () else () pkg_get_variable (GIO_MODULE_DIR gio-2.0 giomoduledir) @@ -67,7 +67,7 @@ else () endif () include_directories (${GELEKTRA_INCLUDE_DIRS}) target_link_libraries (elektrasettings ${GLIB_LIBRARIES} ${GMODULE_LIBRARIES} ${GIO_LIBRARIES} ${GELEKTRA_LIBRARIES}) - install (TARGETS elektrasettings LIBRARY DESTINATION ${GIO_MODULE_DIR}) + install (TARGETS elektrasettings LIBRARY DESTINATION ${GIO_MODULE_DIR} COMPONENT elektra-misc) endif () if (CMAKE_SOURCE_DIR STREQUAL CMAKE_BINARY_DIR) diff --git a/src/bindings/io/doc/CMakeLists.txt b/src/bindings/io/doc/CMakeLists.txt index 3907b210fd9..3cb1199c34d 100644 --- a/src/bindings/io/doc/CMakeLists.txt +++ b/src/bindings/io/doc/CMakeLists.txt @@ -25,9 +25,9 @@ target_include_directories (${IO_VARIANT_LIBRARY} PUBLIC ${CMAKE_CURRENT_SOURCE_ # ~~~ target_link_elektra (${IO_VARIANT_LIBRARY} elektra-io) -install (TARGETS ${IO_VARIANT_LIBRARY} LIBRARY DESTINATION lib${LIB_SUFFIX}) +install (TARGETS ${IO_VARIANT_LIBRARY} LIBRARY DESTINATION lib${LIB_SUFFIX} COMPONENT elektra-misc) -install (FILES ${IO_VARIANT_HDR_FILES} DESTINATION include/${TARGET_INCLUDE_FOLDER}) +install (FILES ${IO_VARIANT_HDR_FILES} DESTINATION include/${TARGET_INCLUDE_FOLDER} COMPONENT elektra-misc) # configure_file ( "${CMAKE_CURRENT_SOURCE_DIR}/${IO_VARIANT_LIBRARY}.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/${IO_VARIANT_LIBRARY}.pc" @ONLY ) diff --git a/src/bindings/io/ev/CMakeLists.txt b/src/bindings/io/ev/CMakeLists.txt index a3567c85815..73d28ada5cb 100644 --- a/src/bindings/io/ev/CMakeLists.txt +++ b/src/bindings/io/ev/CMakeLists.txt @@ -29,7 +29,7 @@ else () # Build library configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/${IO_VARIANT_LIBRARY}.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/${IO_VARIANT_LIBRARY}.pc" @ONLY) - install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${IO_VARIANT_LIBRARY}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER}) + install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${IO_VARIANT_LIBRARY}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} COMPONENT elektra-misc) # Build test set (testexename testio_${BINDING_VARIANT}) diff --git a/src/bindings/io/glib/CMakeLists.txt b/src/bindings/io/glib/CMakeLists.txt index 3ba7d351e0a..27751302877 100644 --- a/src/bindings/io/glib/CMakeLists.txt +++ b/src/bindings/io/glib/CMakeLists.txt @@ -34,7 +34,7 @@ else () configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/${IO_VARIANT_LIBRARY}.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/${IO_VARIANT_LIBRARY}.pc" @ONLY) - install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${IO_VARIANT_LIBRARY}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER}) + install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${IO_VARIANT_LIBRARY}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} COMPONENT elektra-misc) # Build test set (testexename testio_${BINDING_VARIANT}) diff --git a/src/bindings/io/uv/CMakeLists.txt b/src/bindings/io/uv/CMakeLists.txt index 8be1e279db6..63b448b59e3 100644 --- a/src/bindings/io/uv/CMakeLists.txt +++ b/src/bindings/io/uv/CMakeLists.txt @@ -42,7 +42,7 @@ else () configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/${IO_UV_LIBRARY}.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/${IO_UV_LIBRARY}.pc" @ONLY) - install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${IO_UV_LIBRARY}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER}) + install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${IO_UV_LIBRARY}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} COMPONENT elektra-misc) # Build test set (TESTEXENAME testio_${BINDING_VARIANT}) diff --git a/src/bindings/jna/CMakeLists.txt b/src/bindings/jna/CMakeLists.txt index 48e2220bc06..04f8d6d3034 100644 --- a/src/bindings/jna/CMakeLists.txt +++ b/src/bindings/jna/CMakeLists.txt @@ -110,7 +110,7 @@ if (Java_JAVAC_EXECUTABLE) install (FILES "${CMAKE_CURRENT_BINARY_DIR}/libelektra4j/target/libelektra4j-${KDB_VERSION}.jar" "${CMAKE_CURRENT_BINARY_DIR}/libelektra4j/libelektra4j-${KDB_VERSION}.pom.xml" - DESTINATION "share/java") + DESTINATION "share/java" COMPONENT elektra-misc) # and add maven test to execute with ctest in the testing phase if ((CMAKE_SYSTEM_NAME STREQUAL "Darwin") AND NOT (CMAKE_SYSTEM_VERSION VERSION_LESS 15)) diff --git a/src/bindings/swig/ruby/CMakeLists.txt b/src/bindings/swig/ruby/CMakeLists.txt index 495a275766f..c1d3d4bc71f 100644 --- a/src/bindings/swig/ruby/CMakeLists.txt +++ b/src/bindings/swig/ruby/CMakeLists.txt @@ -151,8 +151,8 @@ else () message (STATUS "Ruby module install path: ${RUBY_MODULE_INSTALL_DIR}") endif () - install (TARGETS swig-ruby swig-ruby-tools LIBRARY DESTINATION ${RUBY_LIB_INSTALL_DIR}) - install (FILES ${CMAKE_CURRENT_SOURCE_DIR}/kdb.rb ${CMAKE_CURRENT_SOURCE_DIR}/kdbtools.rb DESTINATION ${RUBY_MODULE_INSTALL_DIR}) + install (TARGETS swig-ruby swig-ruby-tools LIBRARY DESTINATION ${RUBY_LIB_INSTALL_DIR} COMPONENT elektra-misc) + install (FILES ${CMAKE_CURRENT_SOURCE_DIR}/kdb.rb ${CMAKE_CURRENT_SOURCE_DIR}/kdbtools.rb DESTINATION ${RUBY_MODULE_INSTALL_DIR} COMPONENT elektra-misc) include_directories (${CMAKE_CURRENT_SOURCE_DIR}) if (BUILD_TESTING) diff --git a/src/include/kdbio/CMakeLists.txt b/src/include/kdbio/CMakeLists.txt index b71fabcffa7..14823dee700 100644 --- a/src/include/kdbio/CMakeLists.txt +++ b/src/include/kdbio/CMakeLists.txt @@ -1,14 +1,14 @@ check_binding_included ("io_uv" IO_UV_INCLUDED SUBDIRECTORY "io/uv" SILENT) if (IO_UV_INCLUDED) - install (FILES uv.h DESTINATION include/${TARGET_INCLUDE_FOLDER}/kdbio) + install (FILES uv.h DESTINATION include/${TARGET_INCLUDE_FOLDER}/kdbio COMPONENT elektra-misc) endif () check_binding_included ("io_glib" IO_GLIB_INCLUDED SUBDIRECTORY "io/glib" SILENT) if (IO_GLIB_INCLUDED) - install (FILES glib.h DESTINATION include/${TARGET_INCLUDE_FOLDER}/kdbio) + install (FILES glib.h DESTINATION include/${TARGET_INCLUDE_FOLDER}/kdbio COMPONENT elektra-misc) endif () check_binding_included ("io_ev" IO_EV_INCLUDED SUBDIRECTORY "io/ev" SILENT) if (IO_EV_INCLUDED) - install (FILES ev.h DESTINATION include/${TARGET_INCLUDE_FOLDER}/kdbio) + install (FILES ev.h DESTINATION include/${TARGET_INCLUDE_FOLDER}/kdbio COMPONENT elektra-misc) endif () diff --git a/src/libs/merge/CMakeLists.txt b/src/libs/merge/CMakeLists.txt index a9699caf6e7..aba5543661e 100644 --- a/src/libs/merge/CMakeLists.txt +++ b/src/libs/merge/CMakeLists.txt @@ -32,4 +32,4 @@ set (LIBRARY_NAME elektra-merge) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/${LIBRARY_NAME}.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/${LIBRARY_NAME}.pc" @ONLY) -install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${LIBRARY_NAME}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER}) +install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${LIBRARY_NAME}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} COMPONENT elektra-misc) diff --git a/src/plugins/ruby/CMakeLists.txt b/src/plugins/ruby/CMakeLists.txt index 658dfcc21d7..f71db714788 100644 --- a/src/plugins/ruby/CMakeLists.txt +++ b/src/plugins/ruby/CMakeLists.txt @@ -76,7 +76,7 @@ if (ADDTESTING_PHASE) ENVIRONMENT "RUBYLIB=${CMAKE_BINARY_DIR}/src/bindings/swig/ruby:${CMAKE_SOURCE_DIR}/src/bindings/swig/ruby") if (INSTALL_TESTING) - install (DIRECTORY ruby/ruby_test_scripts DESTINATION ${TARGET_TEST_DATA_FOLDER}) + install (DIRECTORY ruby/ruby_test_scripts DESTINATION ${TARGET_TEST_DATA_FOLDER} COMPONENT elektra-misc) endif () else () message (WARNING "ruby bindings are required for testing, test deactivated") diff --git a/src/tools/elektrad/CMakeLists.txt b/src/tools/elektrad/CMakeLists.txt index c83cb4e7d2c..5cfd656268a 100644 --- a/src/tools/elektrad/CMakeLists.txt +++ b/src/tools/elektrad/CMakeLists.txt @@ -20,7 +20,7 @@ else () # install files to destination install (PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/run-elektrad ${CMAKE_CURRENT_BINARY_DIR}/run-elektrad - ${CMAKE_CURRENT_BINARY_DIR}/build-elektrad DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) + ${CMAKE_CURRENT_BINARY_DIR}/build-elektrad DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-misc) if (BUILD_SHARED) set (ELEKTRA_LIBS_ELEKTRAD elektra-core elektra-kdb elektra-plugin elektra-ease elektra-meta) @@ -43,8 +43,8 @@ else () add_custom_target (elektrad ALL DEPENDS "${CMAKE_CURRENT_BINARY_DIR}/elektrad/elektrad") # build elektra-web - install (CODE "message (\"-- Installing: elektra-web > elektrad\")") - install (PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/elektrad/elektrad" DESTINATION "${install_directory}") + install (CODE "message (\"-- Installing: elektra-web > elektrad\")" COMPONENT elektra-misc) + install (PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/elektrad/elektrad" DESTINATION "${install_directory}" COMPONENT elektra-misc) # generate manpages generate_manpage (kdb-run-elektrad FILENAME ${CMAKE_CURRENT_BINARY_DIR}/README.md) diff --git a/src/tools/gen-gpg-testkey/CMakeLists.txt b/src/tools/gen-gpg-testkey/CMakeLists.txt index 3c39c28cd99..39437f84d52 100644 --- a/src/tools/gen-gpg-testkey/CMakeLists.txt +++ b/src/tools/gen-gpg-testkey/CMakeLists.txt @@ -7,7 +7,7 @@ else () include_directories (${LIBGPGME_INCLUDE_DIRS}) add_executable (gen-gpg-testkey gen-gpg-testkey.c) target_link_libraries (gen-gpg-testkey ${LIBGPGME_LIBRARIES}) - install (TARGETS gen-gpg-testkey DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) + install (TARGETS gen-gpg-testkey DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-misc) else () remove_tool (gen-gpg-testkey "libgpgme version ${LIBGPGME_VERSION} is too old - minimum version required is 1.10") endif () diff --git a/src/tools/hub-zeromq/CMakeLists.txt b/src/tools/hub-zeromq/CMakeLists.txt index 1587a704f84..e898facd8ba 100644 --- a/src/tools/hub-zeromq/CMakeLists.txt +++ b/src/tools/hub-zeromq/CMakeLists.txt @@ -25,11 +25,11 @@ else () # find installation path configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/run.sh" "${CMAKE_CURRENT_BINARY_DIR}/run-${tool}") configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/stop.sh" "${CMAKE_CURRENT_BINARY_DIR}/stop-${tool}") configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/README.md" "${CMAKE_CURRENT_BINARY_DIR}/README.md") # copy hub binary - install (TARGETS ${HUB} DESTINATION ${install_directory}) + install (TARGETS ${HUB} DESTINATION ${install_directory} COMPONENT elektra-misc) # install files to destination install (PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/run-${tool} ${CMAKE_CURRENT_BINARY_DIR}/stop-${tool} - DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-misc) generate_manpage (kdb-run-${tool} FILENAME ${CMAKE_CURRENT_BINARY_DIR}/README.md) endif () diff --git a/src/tools/pythongen/CMakeLists.txt b/src/tools/pythongen/CMakeLists.txt index 24f5dc6c65f..68f0335d504 100644 --- a/src/tools/pythongen/CMakeLists.txt +++ b/src/tools/pythongen/CMakeLists.txt @@ -14,7 +14,7 @@ if (PYTHON2INTERP_FOUND) \"${CMAKE_CURRENT_SOURCE_DIR}/pythongen\" -p tests/lift.ini \"${CMAKE_CURRENT_SOURCE_DIR}/util/util.c\" - -o \"${CMAKE_CURRENT_BINARY_DIR}/util.py\")") + -o \"${CMAKE_CURRENT_BINARY_DIR}/util.py\")" COMPONENT elektra-misc) install ( CODE "execute_process(COMMAND @@ -22,7 +22,7 @@ if (PYTHON2INTERP_FOUND) \"${CMAKE_CURRENT_SOURCE_DIR}/pythongen\" -p tests/lift.ini \"${CMAKE_CURRENT_SOURCE_DIR}/util/util.cpp\" - -o \"${CMAKE_CURRENT_BINARY_DIR}/cpp_util.py\")") + -o \"${CMAKE_CURRENT_BINARY_DIR}/cpp_util.py\")" COMPONENT elektra-misc) install ( CODE "execute_process(COMMAND @@ -34,7 +34,7 @@ if (PYTHON2INTERP_FOUND) --root=\$ENV{DESTDIR} --install-scripts=${CMAKE_INSTALL_PREFIX}/${TARGET_TOOL_EXEC_FOLDER} ${INSTALL_OPTIONS} - )") + )" COMPONENT elektra-misc) function (pythongen_util TEMPLATE OUTPUT) diff --git a/src/tools/webd/CMakeLists.txt b/src/tools/webd/CMakeLists.txt index 31af8ee504f..4cd7679e279 100644 --- a/src/tools/webd/CMakeLists.txt +++ b/src/tools/webd/CMakeLists.txt @@ -24,24 +24,22 @@ else () install ( DIRECTORY . DESTINATION ${install_directory} + COMPONENT elektra-misc PATTERN "node_modules" EXCLUDE PATTERN "build" EXCLUDE) - install (FILES README.md DESTINATION ${install_directory}) + install (FILES README.md DESTINATION ${install_directory} COMPONENT elektra-misc) install (PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/run-webd ${CMAKE_CURRENT_BINARY_DIR}/build-webd - DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-misc) # build elektra-web - install (CODE "message (\"-- Installing: elektra-web > webd\")") + install (CODE "message (\"-- Installing: elektra-web > webd\")" COMPONENT elektra-misc) install ( - CODE "execute_process (COMMAND npm install --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" - ) + CODE "execute_process (COMMAND npm install --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" COMPONENT elektra-misc) install ( - CODE "execute_process (COMMAND npm run build --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" - ) + CODE "execute_process (COMMAND npm run build --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" COMPONENT elektra-misc) install ( - CODE "execute_process (COMMAND npm prune --production --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" - ) + CODE "execute_process (COMMAND npm prune --production --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" COMPONENT elektra-misc) # generate manpages generate_manpage (kdb-run-webd FILENAME ${CMAKE_CURRENT_BINARY_DIR}/README.md) diff --git a/src/tools/website/CMakeLists.txt b/src/tools/website/CMakeLists.txt index f2952fecd91..6ccc73931ff 100644 --- a/src/tools/website/CMakeLists.txt +++ b/src/tools/website/CMakeLists.txt @@ -26,17 +26,16 @@ else () configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/README.md" "${CMAKE_CURRENT_BINARY_DIR}/README.md") # install files to destination - install (DIRECTORY public resources DESTINATION ${install_directory}) + install (DIRECTORY public resources DESTINATION ${install_directory} COMPONENT elektra-misc) install (FILES package.json README.md ${CMAKE_CURRENT_BINARY_DIR}/Gruntfile.js application-config.json.tpl - DESTINATION ${install_directory}) + DESTINATION ${install_directory} COMPONENT elektra-misc) install (PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/run-${tool} ${CMAKE_CURRENT_BINARY_DIR}/stop-${tool} ${CMAKE_CURRENT_BINARY_DIR}/build-${tool} ${CMAKE_CURRENT_BINARY_DIR}/mount-${tool}-config - DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-misc) # attempt to install npm dependencies install ( - CODE "execute_process (COMMAND npm install --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" - ) + CODE "execute_process (COMMAND npm install --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" COMPONENT elektra-misc) generate_manpage (kdb-run-${tool} FILENAME ${CMAKE_CURRENT_BINARY_DIR}/README.md) diff --git a/src/tools/webui/CMakeLists.txt b/src/tools/webui/CMakeLists.txt index 3e4261c463d..c1e81376637 100644 --- a/src/tools/webui/CMakeLists.txt +++ b/src/tools/webui/CMakeLists.txt @@ -14,20 +14,18 @@ else () install ( DIRECTORY . DESTINATION ${install_directory} + COMPONENT elektra-misc PATTERN "node_modules" EXCLUDE PATTERN "build" EXCLUDE) - install (FILES README.md DESTINATION ${install_directory}) + install (FILES README.md DESTINATION ${install_directory} COMPONENT elektra-misc) - install (CODE "message (\"-- Installing: elektra-web > webui\")") + install (CODE "message (\"-- Installing: elektra-web > webui\")" COMPONENT elektra-misc) install ( - CODE "execute_process (COMMAND npm install --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" - ) + CODE "execute_process (COMMAND npm install --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" COMPONENT elektra-misc) install ( - CODE "execute_process (COMMAND npm run build --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" - ) + CODE "execute_process (COMMAND npm run build --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" COMPONENT elektra-misc) install ( - CODE "execute_process (COMMAND npm prune --production --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" - ) + CODE "execute_process (COMMAND npm prune --production --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" COMPONENT elektra-misc) endif () From 959ac98dca166be51687c4a33e4b4b1bf578ff58 Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Sun, 13 Dec 2020 03:22:57 +0100 Subject: [PATCH 30/32] style: reformat --- scripts/cmake/ElektraPackaging.cmake | 60 +++++++++++++++--------- src/bindings/glib/CMakeLists.txt | 10 +++- src/bindings/io/doc/CMakeLists.txt | 5 +- src/bindings/io/ev/CMakeLists.txt | 5 +- src/bindings/io/glib/CMakeLists.txt | 5 +- src/bindings/io/uv/CMakeLists.txt | 5 +- src/bindings/jna/CMakeLists.txt | 8 ++-- src/bindings/swig/ruby/CMakeLists.txt | 5 +- src/include/kdbio/CMakeLists.txt | 15 ++++-- src/libs/merge/CMakeLists.txt | 5 +- src/plugins/ruby/CMakeLists.txt | 5 +- src/tools/elektrad/CMakeLists.txt | 12 +++-- src/tools/gen-gpg-testkey/CMakeLists.txt | 5 +- src/tools/hub-zeromq/CMakeLists.txt | 11 +++-- src/tools/pythongen/CMakeLists.txt | 9 ++-- src/tools/webd/CMakeLists.txt | 20 +++++--- src/tools/website/CMakeLists.txt | 22 ++++++--- src/tools/webui/CMakeLists.txt | 14 ++++-- 18 files changed, 157 insertions(+), 64 deletions(-) diff --git a/scripts/cmake/ElektraPackaging.cmake b/scripts/cmake/ElektraPackaging.cmake index b22ab6c6488..bcbdff01ff0 100644 --- a/scripts/cmake/ElektraPackaging.cmake +++ b/scripts/cmake/ElektraPackaging.cmake @@ -7,7 +7,7 @@ set (PROJECT_VERSION "${KDB_VERSION}") set (CPACK_PACKAGE_VERSION "${PROJECT_VERSION}") set (CPACK_DEBIAN_PACKAGE_VERSION "${PROJECT_VERSION}") set (CPACK_DEBIAN_PACKAGE_RELEASE "1") -set (DEBIAN_VERSION_RELEASE "${CPACK_DEBIAN_PACKAGE_VERSION}-${CPACK_DEBIAN_PACKAGE_RELEASE}") +set (DEBIAN_VERSION_RELEASE "${CPACK_DEBIAN_PACKAGE_VERSION}-${CPACK_DEBIAN_PACKAGE_RELEASE}") set (CPACK_DEBIAN_FILE_NAME DEB-DEFAULT) set (CPACK_DEBIAN_PACKAGE_MAINTAINER "Robert Sowula ") @@ -125,10 +125,14 @@ if (UNIX) set (CPACK_COMPONENT_LIBELEKTRA4_DISPLAY_NAME "libelektra4") set (CPACK_COMPONENT_LIBELEKTRA4_DESCRIPTION "This package contains the main elektra library, and most of the core plugins") set (CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_SECTION "libs") - set (CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_BREAKS - "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelektra-core4 (<< ${DEBIAN_VERSION_RELEASE}), libelektra-full4 (<< ${DEBIAN_VERSION_RELEASE})") - set (CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_REPLACES - "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelelektra-core4 (<< ${DEBIAN_VERSION_RELEASE}), libelektra-full4 (<< ${DEBIAN_VERSION_RELEASE})") + set ( + CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_BREAKS + "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelektra-core4 (<< ${DEBIAN_VERSION_RELEASE}), libelektra-full4 (<< ${DEBIAN_VERSION_RELEASE})" + ) + set ( + CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_REPLACES + "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelelektra-core4 (<< ${DEBIAN_VERSION_RELEASE}), libelektra-full4 (<< ${DEBIAN_VERSION_RELEASE})" + ) set (CPACK_DEBIAN_LIBELEKTRA4_PACKAGE_SUGGESTS "elektra-doc, ${ALL_PLUGINS_STR}") set (CPACK_DEBIAN_LIBELEKTRA4_DEBUGINFO_PACKAGE "ON") @@ -138,10 +142,14 @@ if (UNIX) "This package contains an variant of the Elektra library in which all plugins are linked together to a full library. The package is only needed for testing.") set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_SECTION "libs") - set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_BREAKS - "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelektra-core4 (<< ${DEBIAN_VERSION_RELEASE}), libelektra-full4 (<< ${DEBIAN_VERSION_RELEASE})") - set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_REPLACES - "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelelektra-core4 (<< ${DEBIAN_VERSION_RELEASE}), libelektra-full4 (<< ${DEBIAN_VERSION_RELEASE})") + set ( + CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_BREAKS + "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelektra-core4 (<< ${DEBIAN_VERSION_RELEASE}), libelektra-full4 (<< ${DEBIAN_VERSION_RELEASE})" + ) + set ( + CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_REPLACES + "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelelektra-core4 (<< ${DEBIAN_VERSION_RELEASE}), libelektra-full4 (<< ${DEBIAN_VERSION_RELEASE})" + ) set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_CONFLICTS "libelektra4 (<< ${CPACK_DEBIAN_PACKAGE_VERSION}), elektra-tests (<< ${CPACK_DEBIAN_PACKAGE_VERSION})") set (CPACK_DEBIAN_LIBELEKTRA4-FULL_PACKAGE_SUGGESTS "elektra-doc, ${ALL_PLUGINS_STR}") @@ -151,8 +159,10 @@ if (UNIX) set (CPACK_COMPONENT_LIBELEKTRA4-EXPERIMENTAL_DISPLAY_NAME "libelektra4-experimental") set (CPACK_COMPONENT_LIBELEKTRA4-EXPERIMENTAL_DESCRIPTION "This package contains experimental plugins.") set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_PACKAGE_SECTION "libs") - set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_PACKAGE_BREAKS "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelektra-core4 (<< ${DEBIAN_VERSION_RELEASE})") - set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_PACKAGE_REPLACES "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelelektra-core4 (<< ${DEBIAN_VERSION_RELEASE})") + set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_PACKAGE_BREAKS + "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelektra-core4 (<< ${DEBIAN_VERSION_RELEASE})") + set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_PACKAGE_REPLACES + "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelelektra-core4 (<< ${DEBIAN_VERSION_RELEASE})") set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_PACKAGE_SUGGESTS "elektra-doc, ${ALL_PLUGINS_STR}") set (CPACK_DEBIAN_LIBELEKTRA4-EXPERIMENTAL_DEBUGINFO_PACKAGE "ON") @@ -160,8 +170,10 @@ if (UNIX) set (CPACK_COMPONENT_LIBELEKTRA4-EXTRA_DISPLAY_NAME "libelektra4-extra") set (CPACK_COMPONENT_LIBELEKTRA4-EXTRA_DESCRIPTION "This package contains extra plugins.") set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_PACKAGE_SECTION "libs") - set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_PACKAGE_BREAKS "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelektra-core4 (<< ${DEBIAN_VERSION_RELEASE})") - set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_PACKAGE_REPLACES "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelelektra-core4 (<< ${DEBIAN_VERSION_RELEASE})") + set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_PACKAGE_BREAKS + "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelektra-core4 (<< ${DEBIAN_VERSION_RELEASE})") + set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_PACKAGE_REPLACES + "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelelektra-core4 (<< ${DEBIAN_VERSION_RELEASE})") set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_PACKAGE_SUGGESTS "elektra-doc, ${ALL_PLUGINS_STR}") set (CPACK_DEBIAN_LIBELEKTRA4-EXTRA_DEBUGINFO_PACKAGE "ON") @@ -170,8 +182,10 @@ if (UNIX) set (CPACK_COMPONENT_ELEKTRA-BIN_DESCRIPTION "This package contains command line utilities for Elektra.") set (CPACK_COMPONENT_ELEKTRA-BIN_DEPENDS "libelektra4") set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_SECTION "misc") - set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_BREAKS "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}),libelektra-full4 (<< ${DEBIAN_VERSION_RELEASE})") - set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_REPLACES "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelektra-full4 (<< ${DEBIAN_VERSION_RELEASE})") + set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_BREAKS + "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}),libelektra-full4 (<< ${DEBIAN_VERSION_RELEASE})") + set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_REPLACES + "elektra-bin (<< ${DEBIAN_VERSION_RELEASE}), libelektra-full4 (<< ${DEBIAN_VERSION_RELEASE})") set (CPACK_DEBIAN_ELEKTRA-BIN_PACKAGE_CONFLICTS "kernel-patch-kdb") set (CPACK_DEBIAN_ELEKTRA-BIN_DEBUGINFO_PACKAGE "ON") @@ -326,8 +340,10 @@ if (UNIX) set (CPACK_COMPONENT_ELEKTRA-TESTS_DEPENDS "libelektra4-full" "elektra-bin") set (CPACK_DEBIAN_ELEKTRA-TESTS_PACKAGE_SECTION "misc") set (CPACK_DEBIAN_ELEKTRA-TESTS_PACKAGE_PRIORITY "extra") - set (CPACK_DEBIAN_ELEKTRA-TESTS_PACKAGE_BREAKS "libelektra-test (<<${DEBIAN_VERSION_RELEASE}), libelektra-full4 (<< ${DEBIAN_VERSION_RELEASE})") - set (CPACK_DEBIAN_ELEKTRA-TESTS_PACKAGE_REPLACES "libelektra-test (<< ${DEBIAN_VERSION_RELEASE}), libelektra-full4 (<< ${DEBIAN_VERSION_RELEASE})") + set (CPACK_DEBIAN_ELEKTRA-TESTS_PACKAGE_BREAKS + "libelektra-test (<<${DEBIAN_VERSION_RELEASE}), libelektra-full4 (<< ${DEBIAN_VERSION_RELEASE})") + set (CPACK_DEBIAN_ELEKTRA-TESTS_PACKAGE_REPLACES + "libelektra-test (<< ${DEBIAN_VERSION_RELEASE}), libelektra-full4 (<< ${DEBIAN_VERSION_RELEASE})") set (CPACK_DEBIAN_ELEKTRA-TESTS_DEBUGINFO_PACKAGE "ON") set (CPACK_DEBIAN_ELEKTRA-DOC_PACKAGE_NAME "elektra-doc") @@ -380,7 +396,8 @@ if (UNIX) set (CPACK_DEBIAN_ELEKTRA-MISC_PACKAGE_NAME "elektra-misc") set (CPACK_COMPONENT_ELEKTRA-MISC_DISPLAY_NAME "elektra-misc") - set (CPACK_COMPONENT_ELEKTRA-MISC_DESCRIPTION "This package contains all files not part of any of the released Elektra packages.") + set (CPACK_COMPONENT_ELEKTRA-MISC_DESCRIPTION + "This package contains all files not part of any of the released Elektra packages.") set (CPACK_DEBIAN_ELEKTRA-MISC_PACKAGE_ARCHITECTURE "all") set (CPACK_DEBIAN_ELEKTRA-MISC_PACKAGE_SECTION "misc") set (CPACK_DEBIAN_ELEKTRA-MISC_DEBUGINFO_PACKAGE "ON") @@ -395,14 +412,13 @@ if (UNIX) endforeach () # compress and install changelog - add_custom_command( + add_custom_command ( OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/changelog.Debian.gz" COMMAND gzip -cn9 "debian/changelog" > "${CMAKE_CURRENT_BINARY_DIR}/changelog.Debian.gz" WORKING_DIRECTORY "${CMAKE_SOURCE_DIR}/scripts/packaging" - COMMENT "Compressing changelog" - ) + COMMENT "Compressing changelog") - add_custom_target(changelog ALL DEPENDS "${CMAKE_CURRENT_BINARY_DIR}/changelog.Debian.gz") + add_custom_target (changelog ALL DEPENDS "${CMAKE_CURRENT_BINARY_DIR}/changelog.Debian.gz") foreach (component ${CPACK_COMPONENTS_ALL}) install ( diff --git a/src/bindings/glib/CMakeLists.txt b/src/bindings/glib/CMakeLists.txt index c4c199ef847..774c0b0a373 100644 --- a/src/bindings/glib/CMakeLists.txt +++ b/src/bindings/glib/CMakeLists.txt @@ -44,13 +44,19 @@ target_link_libraries (${GELEKTRA_LIBRARY} PUBLIC ${GOBJECT_LDFLAGS}) install (TARGETS ${GELEKTRA_LIBRARY} LIBRARY DESTINATION lib${LIB_SUFFIX} COMPONENT elektra-misc) -install (FILES ${GELEKTRA_HDR_FILES} DESTINATION include/${TARGET_INCLUDE_FOLDER} COMPONENT elektra-misc) +install ( + FILES ${GELEKTRA_HDR_FILES} + DESTINATION include/${TARGET_INCLUDE_FOLDER} + COMPONENT elektra-misc) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/gelektra-constants.h.in" "${CMAKE_CURRENT_BINARY_DIR}/gelektra-constants.h" @ONLY) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/gelektra.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/${GELEKTRA_LIBRARY}.pc" @ONLY) -install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${GELEKTRA_LIBRARY}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} COMPONENT elektra-misc) +install ( + FILES "${CMAKE_CURRENT_BINARY_DIR}/${GELEKTRA_LIBRARY}.pc" + DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} + COMPONENT elektra-misc) if (BUILD_TESTING) add_subdirectory (tests) diff --git a/src/bindings/io/doc/CMakeLists.txt b/src/bindings/io/doc/CMakeLists.txt index 3cb1199c34d..b23d9a2d380 100644 --- a/src/bindings/io/doc/CMakeLists.txt +++ b/src/bindings/io/doc/CMakeLists.txt @@ -27,7 +27,10 @@ target_link_elektra (${IO_VARIANT_LIBRARY} elektra-io) install (TARGETS ${IO_VARIANT_LIBRARY} LIBRARY DESTINATION lib${LIB_SUFFIX} COMPONENT elektra-misc) -install (FILES ${IO_VARIANT_HDR_FILES} DESTINATION include/${TARGET_INCLUDE_FOLDER} COMPONENT elektra-misc) +install ( + FILES ${IO_VARIANT_HDR_FILES} + DESTINATION include/${TARGET_INCLUDE_FOLDER} + COMPONENT elektra-misc) # configure_file ( "${CMAKE_CURRENT_SOURCE_DIR}/${IO_VARIANT_LIBRARY}.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/${IO_VARIANT_LIBRARY}.pc" @ONLY ) diff --git a/src/bindings/io/ev/CMakeLists.txt b/src/bindings/io/ev/CMakeLists.txt index 73d28ada5cb..72f98d5a8d4 100644 --- a/src/bindings/io/ev/CMakeLists.txt +++ b/src/bindings/io/ev/CMakeLists.txt @@ -29,7 +29,10 @@ else () # Build library configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/${IO_VARIANT_LIBRARY}.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/${IO_VARIANT_LIBRARY}.pc" @ONLY) - install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${IO_VARIANT_LIBRARY}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} COMPONENT elektra-misc) + install ( + FILES "${CMAKE_CURRENT_BINARY_DIR}/${IO_VARIANT_LIBRARY}.pc" + DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} + COMPONENT elektra-misc) # Build test set (testexename testio_${BINDING_VARIANT}) diff --git a/src/bindings/io/glib/CMakeLists.txt b/src/bindings/io/glib/CMakeLists.txt index 27751302877..822c9e5e3fb 100644 --- a/src/bindings/io/glib/CMakeLists.txt +++ b/src/bindings/io/glib/CMakeLists.txt @@ -34,7 +34,10 @@ else () configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/${IO_VARIANT_LIBRARY}.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/${IO_VARIANT_LIBRARY}.pc" @ONLY) - install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${IO_VARIANT_LIBRARY}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} COMPONENT elektra-misc) + install ( + FILES "${CMAKE_CURRENT_BINARY_DIR}/${IO_VARIANT_LIBRARY}.pc" + DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} + COMPONENT elektra-misc) # Build test set (testexename testio_${BINDING_VARIANT}) diff --git a/src/bindings/io/uv/CMakeLists.txt b/src/bindings/io/uv/CMakeLists.txt index 63b448b59e3..84a63076822 100644 --- a/src/bindings/io/uv/CMakeLists.txt +++ b/src/bindings/io/uv/CMakeLists.txt @@ -42,7 +42,10 @@ else () configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/${IO_UV_LIBRARY}.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/${IO_UV_LIBRARY}.pc" @ONLY) - install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${IO_UV_LIBRARY}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} COMPONENT elektra-misc) + install ( + FILES "${CMAKE_CURRENT_BINARY_DIR}/${IO_UV_LIBRARY}.pc" + DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} + COMPONENT elektra-misc) # Build test set (TESTEXENAME testio_${BINDING_VARIANT}) diff --git a/src/bindings/jna/CMakeLists.txt b/src/bindings/jna/CMakeLists.txt index 04f8d6d3034..751865a2a32 100644 --- a/src/bindings/jna/CMakeLists.txt +++ b/src/bindings/jna/CMakeLists.txt @@ -108,9 +108,11 @@ if (Java_JAVAC_EXECUTABLE) add_custom_target (jna ALL DEPENDS "${CMAKE_CURRENT_BINARY_DIR}/libelektra4j/target/libelektra4j-${KDB_VERSION}.jar") - install (FILES "${CMAKE_CURRENT_BINARY_DIR}/libelektra4j/target/libelektra4j-${KDB_VERSION}.jar" - "${CMAKE_CURRENT_BINARY_DIR}/libelektra4j/libelektra4j-${KDB_VERSION}.pom.xml" - DESTINATION "share/java" COMPONENT elektra-misc) + install ( + FILES "${CMAKE_CURRENT_BINARY_DIR}/libelektra4j/target/libelektra4j-${KDB_VERSION}.jar" + "${CMAKE_CURRENT_BINARY_DIR}/libelektra4j/libelektra4j-${KDB_VERSION}.pom.xml" + DESTINATION "share/java" + COMPONENT elektra-misc) # and add maven test to execute with ctest in the testing phase if ((CMAKE_SYSTEM_NAME STREQUAL "Darwin") AND NOT (CMAKE_SYSTEM_VERSION VERSION_LESS 15)) diff --git a/src/bindings/swig/ruby/CMakeLists.txt b/src/bindings/swig/ruby/CMakeLists.txt index c1d3d4bc71f..9da44e7386a 100644 --- a/src/bindings/swig/ruby/CMakeLists.txt +++ b/src/bindings/swig/ruby/CMakeLists.txt @@ -152,7 +152,10 @@ else () endif () install (TARGETS swig-ruby swig-ruby-tools LIBRARY DESTINATION ${RUBY_LIB_INSTALL_DIR} COMPONENT elektra-misc) - install (FILES ${CMAKE_CURRENT_SOURCE_DIR}/kdb.rb ${CMAKE_CURRENT_SOURCE_DIR}/kdbtools.rb DESTINATION ${RUBY_MODULE_INSTALL_DIR} COMPONENT elektra-misc) + install ( + FILES ${CMAKE_CURRENT_SOURCE_DIR}/kdb.rb ${CMAKE_CURRENT_SOURCE_DIR}/kdbtools.rb + DESTINATION ${RUBY_MODULE_INSTALL_DIR} + COMPONENT elektra-misc) include_directories (${CMAKE_CURRENT_SOURCE_DIR}) if (BUILD_TESTING) diff --git a/src/include/kdbio/CMakeLists.txt b/src/include/kdbio/CMakeLists.txt index 14823dee700..820ac0348b1 100644 --- a/src/include/kdbio/CMakeLists.txt +++ b/src/include/kdbio/CMakeLists.txt @@ -1,14 +1,23 @@ check_binding_included ("io_uv" IO_UV_INCLUDED SUBDIRECTORY "io/uv" SILENT) if (IO_UV_INCLUDED) - install (FILES uv.h DESTINATION include/${TARGET_INCLUDE_FOLDER}/kdbio COMPONENT elektra-misc) + install ( + FILES uv.h + DESTINATION include/${TARGET_INCLUDE_FOLDER}/kdbio + COMPONENT elektra-misc) endif () check_binding_included ("io_glib" IO_GLIB_INCLUDED SUBDIRECTORY "io/glib" SILENT) if (IO_GLIB_INCLUDED) - install (FILES glib.h DESTINATION include/${TARGET_INCLUDE_FOLDER}/kdbio COMPONENT elektra-misc) + install ( + FILES glib.h + DESTINATION include/${TARGET_INCLUDE_FOLDER}/kdbio + COMPONENT elektra-misc) endif () check_binding_included ("io_ev" IO_EV_INCLUDED SUBDIRECTORY "io/ev" SILENT) if (IO_EV_INCLUDED) - install (FILES ev.h DESTINATION include/${TARGET_INCLUDE_FOLDER}/kdbio COMPONENT elektra-misc) + install ( + FILES ev.h + DESTINATION include/${TARGET_INCLUDE_FOLDER}/kdbio + COMPONENT elektra-misc) endif () diff --git a/src/libs/merge/CMakeLists.txt b/src/libs/merge/CMakeLists.txt index aba5543661e..8d0ae391c63 100644 --- a/src/libs/merge/CMakeLists.txt +++ b/src/libs/merge/CMakeLists.txt @@ -32,4 +32,7 @@ set (LIBRARY_NAME elektra-merge) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/${LIBRARY_NAME}.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/${LIBRARY_NAME}.pc" @ONLY) -install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${LIBRARY_NAME}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} COMPONENT elektra-misc) +install ( + FILES "${CMAKE_CURRENT_BINARY_DIR}/${LIBRARY_NAME}.pc" + DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} + COMPONENT elektra-misc) diff --git a/src/plugins/ruby/CMakeLists.txt b/src/plugins/ruby/CMakeLists.txt index f71db714788..c93ff0802ca 100644 --- a/src/plugins/ruby/CMakeLists.txt +++ b/src/plugins/ruby/CMakeLists.txt @@ -76,7 +76,10 @@ if (ADDTESTING_PHASE) ENVIRONMENT "RUBYLIB=${CMAKE_BINARY_DIR}/src/bindings/swig/ruby:${CMAKE_SOURCE_DIR}/src/bindings/swig/ruby") if (INSTALL_TESTING) - install (DIRECTORY ruby/ruby_test_scripts DESTINATION ${TARGET_TEST_DATA_FOLDER} COMPONENT elektra-misc) + install ( + DIRECTORY ruby/ruby_test_scripts + DESTINATION ${TARGET_TEST_DATA_FOLDER} + COMPONENT elektra-misc) endif () else () message (WARNING "ruby bindings are required for testing, test deactivated") diff --git a/src/tools/elektrad/CMakeLists.txt b/src/tools/elektrad/CMakeLists.txt index 5cfd656268a..ac8eb6a0b5d 100644 --- a/src/tools/elektrad/CMakeLists.txt +++ b/src/tools/elektrad/CMakeLists.txt @@ -19,8 +19,11 @@ else () configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/temp-elektra.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/elektra.pc" @ONLY) # install files to destination - install (PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/run-elektrad ${CMAKE_CURRENT_BINARY_DIR}/run-elektrad - ${CMAKE_CURRENT_BINARY_DIR}/build-elektrad DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-misc) + install ( + PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/run-elektrad ${CMAKE_CURRENT_BINARY_DIR}/run-elektrad + ${CMAKE_CURRENT_BINARY_DIR}/build-elektrad + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} + COMPONENT elektra-misc) if (BUILD_SHARED) set (ELEKTRA_LIBS_ELEKTRAD elektra-core elektra-kdb elektra-plugin elektra-ease elektra-meta) @@ -44,7 +47,10 @@ else () # build elektra-web install (CODE "message (\"-- Installing: elektra-web > elektrad\")" COMPONENT elektra-misc) - install (PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/elektrad/elektrad" DESTINATION "${install_directory}" COMPONENT elektra-misc) + install ( + PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/elektrad/elektrad" + DESTINATION "${install_directory}" + COMPONENT elektra-misc) # generate manpages generate_manpage (kdb-run-elektrad FILENAME ${CMAKE_CURRENT_BINARY_DIR}/README.md) diff --git a/src/tools/gen-gpg-testkey/CMakeLists.txt b/src/tools/gen-gpg-testkey/CMakeLists.txt index 39437f84d52..392fe5c5760 100644 --- a/src/tools/gen-gpg-testkey/CMakeLists.txt +++ b/src/tools/gen-gpg-testkey/CMakeLists.txt @@ -7,7 +7,10 @@ else () include_directories (${LIBGPGME_INCLUDE_DIRS}) add_executable (gen-gpg-testkey gen-gpg-testkey.c) target_link_libraries (gen-gpg-testkey ${LIBGPGME_LIBRARIES}) - install (TARGETS gen-gpg-testkey DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-misc) + install ( + TARGETS gen-gpg-testkey + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} + COMPONENT elektra-misc) else () remove_tool (gen-gpg-testkey "libgpgme version ${LIBGPGME_VERSION} is too old - minimum version required is 1.10") endif () diff --git a/src/tools/hub-zeromq/CMakeLists.txt b/src/tools/hub-zeromq/CMakeLists.txt index e898facd8ba..40a1abc85ea 100644 --- a/src/tools/hub-zeromq/CMakeLists.txt +++ b/src/tools/hub-zeromq/CMakeLists.txt @@ -25,11 +25,16 @@ else () # find installation path configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/run.sh" "${CMAKE_CURRENT_BINARY_DIR}/run-${tool}") configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/stop.sh" "${CMAKE_CURRENT_BINARY_DIR}/stop-${tool}") configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/README.md" "${CMAKE_CURRENT_BINARY_DIR}/README.md") # copy hub binary - install (TARGETS ${HUB} DESTINATION ${install_directory} COMPONENT elektra-misc) + install ( + TARGETS ${HUB} + DESTINATION ${install_directory} + COMPONENT elektra-misc) # install files to destination - install (PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/run-${tool} ${CMAKE_CURRENT_BINARY_DIR}/stop-${tool} - DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-misc) + install ( + PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/run-${tool} ${CMAKE_CURRENT_BINARY_DIR}/stop-${tool} + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} + COMPONENT elektra-misc) generate_manpage (kdb-run-${tool} FILENAME ${CMAKE_CURRENT_BINARY_DIR}/README.md) endif () diff --git a/src/tools/pythongen/CMakeLists.txt b/src/tools/pythongen/CMakeLists.txt index 68f0335d504..b4b9b44738d 100644 --- a/src/tools/pythongen/CMakeLists.txt +++ b/src/tools/pythongen/CMakeLists.txt @@ -14,7 +14,8 @@ if (PYTHON2INTERP_FOUND) \"${CMAKE_CURRENT_SOURCE_DIR}/pythongen\" -p tests/lift.ini \"${CMAKE_CURRENT_SOURCE_DIR}/util/util.c\" - -o \"${CMAKE_CURRENT_BINARY_DIR}/util.py\")" COMPONENT elektra-misc) + -o \"${CMAKE_CURRENT_BINARY_DIR}/util.py\")" + COMPONENT elektra-misc) install ( CODE "execute_process(COMMAND @@ -22,7 +23,8 @@ if (PYTHON2INTERP_FOUND) \"${CMAKE_CURRENT_SOURCE_DIR}/pythongen\" -p tests/lift.ini \"${CMAKE_CURRENT_SOURCE_DIR}/util/util.cpp\" - -o \"${CMAKE_CURRENT_BINARY_DIR}/cpp_util.py\")" COMPONENT elektra-misc) + -o \"${CMAKE_CURRENT_BINARY_DIR}/cpp_util.py\")" + COMPONENT elektra-misc) install ( CODE "execute_process(COMMAND @@ -34,7 +36,8 @@ if (PYTHON2INTERP_FOUND) --root=\$ENV{DESTDIR} --install-scripts=${CMAKE_INSTALL_PREFIX}/${TARGET_TOOL_EXEC_FOLDER} ${INSTALL_OPTIONS} - )" COMPONENT elektra-misc) + )" + COMPONENT elektra-misc) function (pythongen_util TEMPLATE OUTPUT) diff --git a/src/tools/webd/CMakeLists.txt b/src/tools/webd/CMakeLists.txt index 4cd7679e279..4d33b065cab 100644 --- a/src/tools/webd/CMakeLists.txt +++ b/src/tools/webd/CMakeLists.txt @@ -28,18 +28,26 @@ else () PATTERN "node_modules" EXCLUDE PATTERN "build" EXCLUDE) - install (FILES README.md DESTINATION ${install_directory} COMPONENT elektra-misc) - install (PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/run-webd ${CMAKE_CURRENT_BINARY_DIR}/build-webd - DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-misc) + install ( + FILES README.md + DESTINATION ${install_directory} + COMPONENT elektra-misc) + install ( + PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/run-webd ${CMAKE_CURRENT_BINARY_DIR}/build-webd + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} + COMPONENT elektra-misc) # build elektra-web install (CODE "message (\"-- Installing: elektra-web > webd\")" COMPONENT elektra-misc) install ( - CODE "execute_process (COMMAND npm install --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" COMPONENT elektra-misc) + CODE "execute_process (COMMAND npm install --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" + COMPONENT elektra-misc) install ( - CODE "execute_process (COMMAND npm run build --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" COMPONENT elektra-misc) + CODE "execute_process (COMMAND npm run build --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" + COMPONENT elektra-misc) install ( - CODE "execute_process (COMMAND npm prune --production --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" COMPONENT elektra-misc) + CODE "execute_process (COMMAND npm prune --production --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" + COMPONENT elektra-misc) # generate manpages generate_manpage (kdb-run-webd FILENAME ${CMAKE_CURRENT_BINARY_DIR}/README.md) diff --git a/src/tools/website/CMakeLists.txt b/src/tools/website/CMakeLists.txt index 6ccc73931ff..45c956ffc4f 100644 --- a/src/tools/website/CMakeLists.txt +++ b/src/tools/website/CMakeLists.txt @@ -26,16 +26,24 @@ else () configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/README.md" "${CMAKE_CURRENT_BINARY_DIR}/README.md") # install files to destination - install (DIRECTORY public resources DESTINATION ${install_directory} COMPONENT elektra-misc) - install (FILES package.json README.md ${CMAKE_CURRENT_BINARY_DIR}/Gruntfile.js application-config.json.tpl - DESTINATION ${install_directory} COMPONENT elektra-misc) - install (PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/run-${tool} ${CMAKE_CURRENT_BINARY_DIR}/stop-${tool} - ${CMAKE_CURRENT_BINARY_DIR}/build-${tool} ${CMAKE_CURRENT_BINARY_DIR}/mount-${tool}-config - DESTINATION ${TARGET_TOOL_EXEC_FOLDER} COMPONENT elektra-misc) + install ( + DIRECTORY public resources + DESTINATION ${install_directory} + COMPONENT elektra-misc) + install ( + FILES package.json README.md ${CMAKE_CURRENT_BINARY_DIR}/Gruntfile.js application-config.json.tpl + DESTINATION ${install_directory} + COMPONENT elektra-misc) + install ( + PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/run-${tool} ${CMAKE_CURRENT_BINARY_DIR}/stop-${tool} + ${CMAKE_CURRENT_BINARY_DIR}/build-${tool} ${CMAKE_CURRENT_BINARY_DIR}/mount-${tool}-config + DESTINATION ${TARGET_TOOL_EXEC_FOLDER} + COMPONENT elektra-misc) # attempt to install npm dependencies install ( - CODE "execute_process (COMMAND npm install --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" COMPONENT elektra-misc) + CODE "execute_process (COMMAND npm install --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" + COMPONENT elektra-misc) generate_manpage (kdb-run-${tool} FILENAME ${CMAKE_CURRENT_BINARY_DIR}/README.md) diff --git a/src/tools/webui/CMakeLists.txt b/src/tools/webui/CMakeLists.txt index c1e81376637..cbda5fae865 100644 --- a/src/tools/webui/CMakeLists.txt +++ b/src/tools/webui/CMakeLists.txt @@ -18,14 +18,20 @@ else () PATTERN "node_modules" EXCLUDE PATTERN "build" EXCLUDE) - install (FILES README.md DESTINATION ${install_directory} COMPONENT elektra-misc) + install ( + FILES README.md + DESTINATION ${install_directory} + COMPONENT elektra-misc) install (CODE "message (\"-- Installing: elektra-web > webui\")" COMPONENT elektra-misc) install ( - CODE "execute_process (COMMAND npm install --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" COMPONENT elektra-misc) + CODE "execute_process (COMMAND npm install --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" + COMPONENT elektra-misc) install ( - CODE "execute_process (COMMAND npm run build --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" COMPONENT elektra-misc) + CODE "execute_process (COMMAND npm run build --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" + COMPONENT elektra-misc) install ( - CODE "execute_process (COMMAND npm prune --production --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" COMPONENT elektra-misc) + CODE "execute_process (COMMAND npm prune --production --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" + COMPONENT elektra-misc) endif () From 71bc1ce9c7b8a8c1ab7918f0cbf79cbe903402d5 Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Sun, 13 Dec 2020 04:40:26 +0100 Subject: [PATCH 31/32] news: fix release notes format --- doc/news/_preparation_next_release.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/news/_preparation_next_release.md b/doc/news/_preparation_next_release.md index 1f6b417f741..f3f0a76298d 100644 --- a/doc/news/_preparation_next_release.md +++ b/doc/news/_preparation_next_release.md @@ -48,7 +48,7 @@ If you rely on specific behaviour of Elektra's Keynames and have already taken t ### Debian Packaging with CPack -We are now using CPack to generate modular Debian and Ubuntu packages. This simplifies the packaging process and solves problems where a PR that introduces changes to installed files, fails. We can now also set distribution specifc dependencies with CPack, which is needed for some packages. _Robert Sowula_ +- We are now using CPack to generate modular Debian and Ubuntu packages. This simplifies the packaging process and solves problems where a PR that introduces changes to installed files, fails. We can now also set distribution specifc dependencies with CPack, which is needed for some packages. _(Robert Sowula)_ ### <> From e9f83c4af32e6e90e86f3196dcbfaa310b8f5269 Mon Sep 17 00:00:00 2001 From: Robert Sowula Date: Tue, 15 Dec 2020 21:00:47 +0100 Subject: [PATCH 32/32] packaging: apply suggestions from review --- CMakeLists.txt | 11 ++-- doc/CMakeLists.txt | 4 +- scripts/cmake/ElektraPackaging.cmake | 61 +++++++++++++++++++---- scripts/cmake/Modules/LibAddLib.cmake | 2 +- scripts/cmake/Modules/LibAddMacros.cmake | 2 +- scripts/cmake/Modules/LibAddPlugin.cmake | 2 +- scripts/kdb/CMakeLists.txt | 4 -- scripts/packaging/package.sh | 4 +- src/bindings/glib/CMakeLists.txt | 9 ++-- src/bindings/gsettings/CMakeLists.txt | 4 +- src/bindings/intercept/env/CMakeLists.txt | 2 +- src/bindings/io/doc/CMakeLists.txt | 7 +-- src/bindings/io/ev/CMakeLists.txt | 2 +- src/bindings/io/glib/CMakeLists.txt | 2 +- src/bindings/io/uv/CMakeLists.txt | 2 +- src/bindings/jna/CMakeLists.txt | 6 +-- src/bindings/swig/ruby/CMakeLists.txt | 7 +-- src/include/kdbio/CMakeLists.txt | 15 ++---- src/libs/merge/CMakeLists.txt | 2 +- src/plugins/jni/CMakeLists.txt | 2 +- src/plugins/resolver/CMakeLists.txt | 1 - src/plugins/ruby/CMakeLists.txt | 5 +- src/plugins/yamlcpp/CMakeLists.txt | 2 +- src/tools/elektrad/CMakeLists.txt | 14 ++---- src/tools/gen-gpg-testkey/CMakeLists.txt | 2 +- src/tools/hub-zeromq/CMakeLists.txt | 11 ++-- src/tools/pythongen/CMakeLists.txt | 9 ++-- src/tools/qt-gui/CMakeLists.txt | 2 +- src/tools/webd/CMakeLists.txt | 20 +++----- src/tools/website/CMakeLists.txt | 21 +++----- src/tools/webui/CMakeLists.txt | 14 ++---- 31 files changed, 120 insertions(+), 131 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index bd03651c402..b4f270b057b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -31,6 +31,11 @@ endif (CMAKE_VERSION VERSION_LESS 3.9) set (CMAKE_MACOSX_RPATH 1) set (CMAKE_INSTALL_RPATH "${CMAKE_INSTALL_PREFIX}/lib") +set ( + CMAKE_INSTALL_DEFAULT_COMPONENT_NAME + "elektra-misc" + CACHE STRING "Default component name" FORCE) + # additional modules for loading libraries set (CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/scripts/cmake/Modules/") @@ -85,9 +90,6 @@ set (SO_VERSION 4) set (SO_VERSION_TOOLS 2) set (SO_VERSION_GETENV 0) -# needs version above -include (scripts/cmake/ElektraPackaging.cmake) - # ensure KDB_DB_SYSTEM is an absolute path if (NOT IS_ABSOLUTE "${KDB_DB_SYSTEM}") set (KDB_DB_SYSTEM "${CMAKE_INSTALL_PREFIX}/${KDB_DB_SYSTEM}") @@ -129,3 +131,6 @@ install ( FILES LICENSE.md DESTINATION ${TARGET_DOCUMENTATION_TEXT_FOLDER} COMPONENT libelektra4) + +# needs to be included last to collect all install components +include (scripts/cmake/ElektraPackaging.cmake) diff --git a/doc/CMakeLists.txt b/doc/CMakeLists.txt index 91796924c48..a097769e277 100644 --- a/doc/CMakeLists.txt +++ b/doc/CMakeLists.txt @@ -22,7 +22,7 @@ macro (do_doc target folder file install) if (ARG_COMPONENT) set (HAS_COMPONENT ${ARG_COMPONENT}) else () - set (HAS_COMPONENT "elektra-misc") + set (HAS_COMPONENT ${CMAKE_INSTALL_DEFAULT_COMPONENT_NAME}) endif () # sometimes doxygen is too slow and fails with "Could not create output directory .../doc/html" @@ -97,7 +97,7 @@ if (DOXYGEN_FOUND) set (outputs ${OUTPUT_DIRECTORY}/html/index.html ${OUTPUT_DIRECTORY}/man/man3elektra/kdb.3elektra) if (WITH_LATEX) - do_doc (latex ${OUTPUT_DIRECTORY}/latex/ refman.tex ${TARGET_DOCUMENTATION_LATEX_FOLDER}) + do_doc (latex ${OUTPUT_DIRECTORY}/latex/ refman.tex ${TARGET_DOCUMENTATION_LATEX_FOLDER} COMPONENT elektra-doc) add_dependencies (latex man3 html) list (APPEND outputs ${OUTPUT_DIRECTORY}/latex/refman.tex) diff --git a/scripts/cmake/ElektraPackaging.cmake b/scripts/cmake/ElektraPackaging.cmake index bcbdff01ff0..ba5efe5fa6c 100644 --- a/scripts/cmake/ElektraPackaging.cmake +++ b/scripts/cmake/ElektraPackaging.cmake @@ -1,5 +1,4 @@ set (PACKAGE_NAME "elektra") -set (CPACK_PACKAGE_NAME "${PACKAGE_NAME}") set (PACKAGE_URL "https://www.libelektra.org/") set (PACKAGE_BUGREPORT "https://bugs.libelektra.org/") @@ -14,7 +13,7 @@ set (CPACK_DEBIAN_PACKAGE_MAINTAINER "Robert Sowula ") set (CPACK_OUTPUT_FILE_PREFIX "packages") set ( - CPACK_COMPONENTS_ALL + DEBIAN_PACKAGES libelektra4 libelektra4-all libelektra4-full @@ -25,13 +24,16 @@ set ( libelektra4-curl libelektra4-dbus libelektra-dev + libelektra4-java libelektra4-journald libelektra4-lua libelektra4-python libelektra4-xerces libelektra4-xmltool libelektra4-yajl + libelektra4-yamlcpp libelektra4-zeromq + java-elektra lua-elektra python3-elektra elektra-bin @@ -40,12 +42,21 @@ set ( elektra-qt-gui elektra-tests elektra-dbg - elektra-misc) + ${CMAKE_INSTALL_DEFAULT_COMPONENT_NAME}) -set (COMPONENTS_WITHOUT_DBGSYM elektra-doc elektra-dbg libelektra-dev libelektra4-all elektra-bin-extra) +set ( + COMPONENTS_WITHOUT_DBGSYM + elektra-doc + elektra-dbg + libelektra-dev + libelektra4-all + libelektra4-yamlcpp + elektra-bin-extra + java-elektra + ${CMAKE_INSTALL_DEFAULT_COMPONENT_NAME}) set (ALL_PLUGINS "") -foreach (component ${CPACK_COMPONENTS_ALL}) +foreach (component ${DEBIAN_PACKAGES}) if (component MATCHES "^libelektra4-.*") list (APPEND ALL_PLUGINS "${component}") endif () @@ -53,8 +64,8 @@ endforeach () string (REPLACE ";" ", " ALL_PLUGINS_STR "${ALL_PLUGINS}") set (DBG_PACKAGE_NAMES "") -foreach (component ${CPACK_COMPONENTS_ALL}) - if (NOT component IN_LIST COMPONENTS_WITHOUT_DBGSYM AND NOT component STREQUAL "elektra-misc") +foreach (component ${DEBIAN_PACKAGES}) + if (NOT component IN_LIST COMPONENTS_WITHOUT_DBGSYM) list (APPEND DBG_PACKAGE_NAMES "${component}-dbgsym") endif () endforeach () @@ -108,6 +119,7 @@ if (UNIX) if (NOT LSB_DISTRIB) set (LSB_DISTRIB "unix") endif (NOT LSB_DISTRIB) + message (STATUS "CMAKE_INSTALL_DEFAULT_COMPONENT_NAME: ${CMAKE_INSTALL_DEFAULT_COMPONENT_NAME}") # For Debian-based distros we want to create DEB packages. if ("${LSB_DISTRIB}" MATCHES "Ubuntu|Debian") @@ -268,6 +280,12 @@ if (UNIX) set (CPACK_DEBIAN_LIBELEKTRA4-JOURNALD_PACKAGE_SECTION "libs") set (CPACK_DEBIAN_LIBELEKTRA4-JOURNALD_DEBUGINFO_PACKAGE "ON") + set (CPACK_DEBIAN_LIBELEKTRA4-YAMLCPP_PACKAGE_NAME "libelektra4-yamlcpp") + set (CPACK_COMPONENT_LIBELEKTRA4-YAMLCPP_DISPLAY_NAME "libelektra4-yamlcpp") + set (CPACK_COMPONENT_LIBELEKTRA4-YAMLCPP_DESCRIPTION "This package contains the 'yamlcpp' plugin.") + set (CPACK_COMPONENT_LIBELEKTRA4-YAMLCPP_DEPENDS "libelektra4") + set (CPACK_DEBIAN_LIBELEKTRA4-YAMLCPP_PACKAGE_SECTION "libs") + set (CPACK_DEBIAN_LIBELEKTRA4-LUA_PACKAGE_NAME "libelektra4-lua") set (CPACK_COMPONENT_LIBELEKTRA4-LUA_DISPLAY_NAME "libelektra4-lua") set (CPACK_COMPONENT_LIBELEKTRA4-LUA_DESCRIPTION "This package contains the 'lua' plugin.") @@ -275,6 +293,21 @@ if (UNIX) set (CPACK_DEBIAN_LIBELEKTRA4-LUA_PACKAGE_SECTION "libs") set (CPACK_DEBIAN_LIBELEKTRA4-LUA_DEBUGINFO_PACKAGE "ON") + set (CPACK_DEBIAN_LIBELEKTRA4-JAVA_PACKAGE_NAME "libelektra4-java") + set (CPACK_COMPONENT_LIBELEKTRA4-JAVA_DISPLAY_NAME "libelektra4-java") + set (CPACK_COMPONENT_LIBELEKTRA4-JAVA_DESCRIPTION "This package contains the 'jni' plugin.") + set (CPACK_COMPONENT_LIBELEKTRA4-JAVA_DEPENDS "libelektra4" "java-elektra") + set (CPACK_DEBIAN_LIBELEKTRA4-JAVA_PACKAGE_DEPENDS "default-jdk") + set (CPACK_DEBIAN_LIBELEKTRA4-JAVA_PACKAGE_SECTION "libs") + set (CPACK_DEBIAN_LIBELEKTRA4-JAVA_DEBUGINFO_PACKAGE "ON") + + set (CPACK_DEBIAN_JAVA-ELEKTRA_PACKAGE_NAME "java-elektra") + set (CPACK_COMPONENT_JAVA-ELEKTRA_DISPLAY_NAME "java-elektra") + set (CPACK_COMPONENT_JAVA-ELEKTRA_DESCRIPTION "This package contains the Java bindings.") + set (CPACK_COMPONENT_JAVA-ELEKTRA_DEPENDS "libelektra4") + set (CPACK_DEBIAN_JAVA-ELEKTRA_PACKAGE_DEPENDS "default-jdk") + set (CPACK_DEBIAN_JAVA-ELEKTRA_PACKAGE_SECTION "java") + set (CPACK_DEBIAN_LUA-ELEKTRA_PACKAGE_NAME "lua-elektra") set (CPACK_COMPONENT_LUA-ELEKTRA_DISPLAY_NAME "lua-elektra") set (CPACK_COMPONENT_LUA-ELEKTRA_DESCRIPTION "This package contains the Lua bindings.") @@ -369,11 +402,13 @@ if (UNIX) "libelektra4-augeas" "libelektra4-dbus" "libelektra4-zeromq" + "libelektra4-java" "libelektra4-lua" "libelektra4-python" "libelektra4-xmltool" "libelektra4-xerces" "libelektra4-yajl" + "libelektra4-yamlcpp" "lua-elektra" "elektra-bin" "elektra-qt-gui" @@ -400,11 +435,10 @@ if (UNIX) "This package contains all files not part of any of the released Elektra packages.") set (CPACK_DEBIAN_ELEKTRA-MISC_PACKAGE_ARCHITECTURE "all") set (CPACK_DEBIAN_ELEKTRA-MISC_PACKAGE_SECTION "misc") - set (CPACK_DEBIAN_ELEKTRA-MISC_DEBUGINFO_PACKAGE "ON") # install copyright file configure_file ("${CMAKE_SOURCE_DIR}/doc/THIRD-PARTY-LICENSES" "${CMAKE_BINARY_DIR}/doc/copyright" COPYONLY) - foreach (component ${CPACK_COMPONENTS_ALL}) + foreach (component ${DEBIAN_PACKAGES}) install ( FILES "${CMAKE_BINARY_DIR}/doc/copyright" COMPONENT ${component} @@ -420,7 +454,7 @@ if (UNIX) add_custom_target (changelog ALL DEPENDS "${CMAKE_CURRENT_BINARY_DIR}/changelog.Debian.gz") - foreach (component ${CPACK_COMPONENTS_ALL}) + foreach (component ${DEBIAN_PACKAGES}) install ( FILES "${CMAKE_CURRENT_BINARY_DIR}/changelog.Debian.gz" COMPONENT ${component} @@ -473,3 +507,10 @@ set ( "%ignore /usr/share/man") include (CPack) + +foreach (component ${CPACK_COMPONENTS_ALL}) + if (NOT component IN_LIST DEBIAN_PACKAGES) + message (SEND_ERROR "Component ${component} is not +part of DEBIAN_PACKAGES (ElektraPackaging.cmake). Please add it to this list, so the dependencies can be derived correctly.") + endif () +endforeach () diff --git a/scripts/cmake/Modules/LibAddLib.cmake b/scripts/cmake/Modules/LibAddLib.cmake index 4537e197ca6..7fe92015820 100644 --- a/scripts/cmake/Modules/LibAddLib.cmake +++ b/scripts/cmake/Modules/LibAddLib.cmake @@ -26,7 +26,7 @@ function (add_lib name) if (ARG_COMPONENT) set (HAS_COMPONENT ${ARG_COMPONENT}) else () - set (HAS_COMPONENT "elektra-misc") + set (HAS_COMPONENT "${CMAKE_INSTALL_DEFAULT_COMPONENT_NAME}") endif () add_library (elektra-${name}-objects OBJECT ${ARG_SOURCES}) diff --git a/scripts/cmake/Modules/LibAddMacros.cmake b/scripts/cmake/Modules/LibAddMacros.cmake index b462a5219db..eed08cfcd80 100644 --- a/scripts/cmake/Modules/LibAddMacros.cmake +++ b/scripts/cmake/Modules/LibAddMacros.cmake @@ -624,7 +624,7 @@ function (generate_manpage NAME) if (ARG_COMPONENT) set (HAS_COMPONENT ${ARG_COMPONENT}) else () - set (HAS_COMPONENT "elektra-misc") + set (HAS_COMPONENT ${CMAKE_INSTALL_DEFAULT_COMPONENT_NAME}) endif () set (MAN_PAGE_LOCATION "doc/man/man${SECTION}/${NAME}.${SECTION}") diff --git a/scripts/cmake/Modules/LibAddPlugin.cmake b/scripts/cmake/Modules/LibAddPlugin.cmake index f5f51a1bc3b..7a07bbde9ce 100644 --- a/scripts/cmake/Modules/LibAddPlugin.cmake +++ b/scripts/cmake/Modules/LibAddPlugin.cmake @@ -439,7 +439,7 @@ function (add_plugin PLUGIN_SHORT_NAME) if (ARG_COMPONENT) set (HAS_COMPONENT ${ARG_COMPONENT}) else () - set (HAS_COMPONENT "elektra-misc") + set (HAS_COMPONENT "${CMAKE_INSTALL_DEFAULT_COMPONENT_NAME}") endif () if (ADDTESTING_PHASE) diff --git a/scripts/kdb/CMakeLists.txt b/scripts/kdb/CMakeLists.txt index ada845647b4..a4ecc2e41ee 100644 --- a/scripts/kdb/CMakeLists.txt +++ b/scripts/kdb/CMakeLists.txt @@ -12,8 +12,6 @@ endforeach (file ${IN_FILES}) set (COMPONENT_BIN_EXTRA_FILES "find-tools" "mount-list-all-files" "mountpoint-info") -set (NOT_INCLUDE "cmerge-config-files" "install-config-file") - file (GLOB ALL_FILES *) list (REMOVE_ITEM ALL_FILES ${IN_FILES}) list (REMOVE_ITEM ALL_FILES "${CMAKE_CURRENT_SOURCE_DIR}/CMakeLists.txt") @@ -21,8 +19,6 @@ foreach (file ${ALL_FILES}) get_filename_component (file_we "${file}" NAME_WE) if ("${file_we}" IN_LIST COMPONENT_BIN_EXTRA_FILES) set (HAS_COMPONENT elektra-bin-extra) - elseif ("${file_we}" IN_LIST NOT_INCLUDE) - set (HAS_COMPONENT "") else () set (HAS_COMPONENT elektra-bin) endif () diff --git a/scripts/packaging/package.sh b/scripts/packaging/package.sh index 6ac529f2849..9232ce2dfe8 100644 --- a/scripts/packaging/package.sh +++ b/scripts/packaging/package.sh @@ -1,8 +1,8 @@ #!/bin/sh -ELEKTRA_PLUGINS='ALL;mozprefs;multifile;-gitresolver;-jni;-ruby;-haskell;-yamlcpp;toml' +ELEKTRA_PLUGINS='ALL;mozprefs;multifile;-gitresolver;jni;-ruby;-haskell;yamlcpp;toml' ELEKTRA_TOOLS='ALL' -ELEKTRA_BINDINGS='cpp;lua;python;INTERCEPT' +ELEKTRA_BINDINGS='cpp;lua;python;jna;INTERCEPT' # workaround for hardening flags CPPFLAGS=$(dpkg-buildflags --get CPPFLAGS) diff --git a/src/bindings/glib/CMakeLists.txt b/src/bindings/glib/CMakeLists.txt index 774c0b0a373..722be2c4d5b 100644 --- a/src/bindings/glib/CMakeLists.txt +++ b/src/bindings/glib/CMakeLists.txt @@ -42,12 +42,9 @@ target_compile_options (${GELEKTRA_LIBRARY} PUBLIC ${GOBJECT_CFLAGS_OTHER}) target_link_libraries (${GELEKTRA_LIBRARY} PUBLIC elektra-core elektra-kdb) target_link_libraries (${GELEKTRA_LIBRARY} PUBLIC ${GOBJECT_LDFLAGS}) -install (TARGETS ${GELEKTRA_LIBRARY} LIBRARY DESTINATION lib${LIB_SUFFIX} COMPONENT elektra-misc) +install (TARGETS ${GELEKTRA_LIBRARY} LIBRARY DESTINATION lib${LIB_SUFFIX}) -install ( - FILES ${GELEKTRA_HDR_FILES} - DESTINATION include/${TARGET_INCLUDE_FOLDER} - COMPONENT elektra-misc) +install (FILES ${GELEKTRA_HDR_FILES} DESTINATION include/${TARGET_INCLUDE_FOLDER}) configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/gelektra-constants.h.in" "${CMAKE_CURRENT_BINARY_DIR}/gelektra-constants.h" @ONLY) @@ -56,7 +53,7 @@ configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/gelektra.pc.in" "${CMAKE_CURRENT_BI install ( FILES "${CMAKE_CURRENT_BINARY_DIR}/${GELEKTRA_LIBRARY}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} - COMPONENT elektra-misc) + COMPONENT libelektra-dev) if (BUILD_TESTING) add_subdirectory (tests) diff --git a/src/bindings/gsettings/CMakeLists.txt b/src/bindings/gsettings/CMakeLists.txt index c0ce0e31674..c519f3283ca 100644 --- a/src/bindings/gsettings/CMakeLists.txt +++ b/src/bindings/gsettings/CMakeLists.txt @@ -57,7 +57,7 @@ if (GELEKTRA_LIBRARY) include_directories (${CMAKE_BINARY_DIR}/src/include/) target_link_libraries (elektrasettings ${GLIB_LIBRARIES} ${GMODULE_LIBRARIES} ${GIO_LIBRARIES} ${GELEKTRA_LIBRARY} elektra-core) if (INSTALL_SYSTEM_FILES) - install (TARGETS elektrasettings LIBRARY DESTINATION ${GIO_MODULE_DIR} COMPONENT elektra-misc) + install (TARGETS elektrasettings LIBRARY DESTINATION ${GIO_MODULE_DIR}) endif () else () pkg_get_variable (GIO_MODULE_DIR gio-2.0 giomoduledir) @@ -67,7 +67,7 @@ else () endif () include_directories (${GELEKTRA_INCLUDE_DIRS}) target_link_libraries (elektrasettings ${GLIB_LIBRARIES} ${GMODULE_LIBRARIES} ${GIO_LIBRARIES} ${GELEKTRA_LIBRARIES}) - install (TARGETS elektrasettings LIBRARY DESTINATION ${GIO_MODULE_DIR} COMPONENT elektra-misc) + install (TARGETS elektrasettings LIBRARY DESTINATION ${GIO_MODULE_DIR}) endif () if (CMAKE_SOURCE_DIR STREQUAL CMAKE_BINARY_DIR) diff --git a/src/bindings/intercept/env/CMakeLists.txt b/src/bindings/intercept/env/CMakeLists.txt index 5476cc811df..abc5517388b 100644 --- a/src/bindings/intercept/env/CMakeLists.txt +++ b/src/bindings/intercept/env/CMakeLists.txt @@ -14,7 +14,7 @@ else () set (NAME elektrify-getenv) generate_readme (${NAME}) - generate_manpage (kdb-${NAME} FILENAME ${CMAKE_CURRENT_SOURCE_DIR}/README.md) + generate_manpage (kdb-${NAME} FILENAME ${CMAKE_CURRENT_SOURCE_DIR}/README.md COMPONENT elektra-bin) include_directories (${CMAKE_CURRENT_BINARY_DIR}) add_subdirectory (src) diff --git a/src/bindings/io/doc/CMakeLists.txt b/src/bindings/io/doc/CMakeLists.txt index b23d9a2d380..3907b210fd9 100644 --- a/src/bindings/io/doc/CMakeLists.txt +++ b/src/bindings/io/doc/CMakeLists.txt @@ -25,12 +25,9 @@ target_include_directories (${IO_VARIANT_LIBRARY} PUBLIC ${CMAKE_CURRENT_SOURCE_ # ~~~ target_link_elektra (${IO_VARIANT_LIBRARY} elektra-io) -install (TARGETS ${IO_VARIANT_LIBRARY} LIBRARY DESTINATION lib${LIB_SUFFIX} COMPONENT elektra-misc) +install (TARGETS ${IO_VARIANT_LIBRARY} LIBRARY DESTINATION lib${LIB_SUFFIX}) -install ( - FILES ${IO_VARIANT_HDR_FILES} - DESTINATION include/${TARGET_INCLUDE_FOLDER} - COMPONENT elektra-misc) +install (FILES ${IO_VARIANT_HDR_FILES} DESTINATION include/${TARGET_INCLUDE_FOLDER}) # configure_file ( "${CMAKE_CURRENT_SOURCE_DIR}/${IO_VARIANT_LIBRARY}.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/${IO_VARIANT_LIBRARY}.pc" @ONLY ) diff --git a/src/bindings/io/ev/CMakeLists.txt b/src/bindings/io/ev/CMakeLists.txt index 72f98d5a8d4..17f5c77e3ad 100644 --- a/src/bindings/io/ev/CMakeLists.txt +++ b/src/bindings/io/ev/CMakeLists.txt @@ -32,7 +32,7 @@ else () # Build library install ( FILES "${CMAKE_CURRENT_BINARY_DIR}/${IO_VARIANT_LIBRARY}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} - COMPONENT elektra-misc) + COMPONENT libelektra-dev) # Build test set (testexename testio_${BINDING_VARIANT}) diff --git a/src/bindings/io/glib/CMakeLists.txt b/src/bindings/io/glib/CMakeLists.txt index 822c9e5e3fb..5615687f6c3 100644 --- a/src/bindings/io/glib/CMakeLists.txt +++ b/src/bindings/io/glib/CMakeLists.txt @@ -37,7 +37,7 @@ else () install ( FILES "${CMAKE_CURRENT_BINARY_DIR}/${IO_VARIANT_LIBRARY}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} - COMPONENT elektra-misc) + COMPONENT libelektra-dev) # Build test set (testexename testio_${BINDING_VARIANT}) diff --git a/src/bindings/io/uv/CMakeLists.txt b/src/bindings/io/uv/CMakeLists.txt index 84a63076822..73cb451e2de 100644 --- a/src/bindings/io/uv/CMakeLists.txt +++ b/src/bindings/io/uv/CMakeLists.txt @@ -45,7 +45,7 @@ else () install ( FILES "${CMAKE_CURRENT_BINARY_DIR}/${IO_UV_LIBRARY}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} - COMPONENT elektra-misc) + COMPONENT libelektra-dev) # Build test set (TESTEXENAME testio_${BINDING_VARIANT}) diff --git a/src/bindings/jna/CMakeLists.txt b/src/bindings/jna/CMakeLists.txt index 751865a2a32..529718d8d5c 100644 --- a/src/bindings/jna/CMakeLists.txt +++ b/src/bindings/jna/CMakeLists.txt @@ -102,8 +102,8 @@ if (Java_JAVAC_EXECUTABLE) WORKING_DIRECTORY libelektra4j DEPENDS "${CMAKE_CURRENT_BINARY_DIR}/libelektra4j/pom.xml" ${JNA_BINDING_SOURCE_FILES}) - create_lib_symlink (libelektra4j-${KDB_VERSION}.jar libelektra4j.jar JAVA) - create_lib_symlink (libelektra4j-${KDB_VERSION}.pom.xml libelektra4j.pom.xml JAVA) + create_lib_symlink (libelektra4j-${KDB_VERSION}.jar libelektra4j.jar java-elektra JAVA) + create_lib_symlink (libelektra4j-${KDB_VERSION}.pom.xml libelektra4j.pom.xml java-elektra JAVA) add_custom_target (jna ALL DEPENDS "${CMAKE_CURRENT_BINARY_DIR}/libelektra4j/target/libelektra4j-${KDB_VERSION}.jar") @@ -112,7 +112,7 @@ if (Java_JAVAC_EXECUTABLE) FILES "${CMAKE_CURRENT_BINARY_DIR}/libelektra4j/target/libelektra4j-${KDB_VERSION}.jar" "${CMAKE_CURRENT_BINARY_DIR}/libelektra4j/libelektra4j-${KDB_VERSION}.pom.xml" DESTINATION "share/java" - COMPONENT elektra-misc) + COMPONENT java-elektra) # and add maven test to execute with ctest in the testing phase if ((CMAKE_SYSTEM_NAME STREQUAL "Darwin") AND NOT (CMAKE_SYSTEM_VERSION VERSION_LESS 15)) diff --git a/src/bindings/swig/ruby/CMakeLists.txt b/src/bindings/swig/ruby/CMakeLists.txt index 9da44e7386a..495a275766f 100644 --- a/src/bindings/swig/ruby/CMakeLists.txt +++ b/src/bindings/swig/ruby/CMakeLists.txt @@ -151,11 +151,8 @@ else () message (STATUS "Ruby module install path: ${RUBY_MODULE_INSTALL_DIR}") endif () - install (TARGETS swig-ruby swig-ruby-tools LIBRARY DESTINATION ${RUBY_LIB_INSTALL_DIR} COMPONENT elektra-misc) - install ( - FILES ${CMAKE_CURRENT_SOURCE_DIR}/kdb.rb ${CMAKE_CURRENT_SOURCE_DIR}/kdbtools.rb - DESTINATION ${RUBY_MODULE_INSTALL_DIR} - COMPONENT elektra-misc) + install (TARGETS swig-ruby swig-ruby-tools LIBRARY DESTINATION ${RUBY_LIB_INSTALL_DIR}) + install (FILES ${CMAKE_CURRENT_SOURCE_DIR}/kdb.rb ${CMAKE_CURRENT_SOURCE_DIR}/kdbtools.rb DESTINATION ${RUBY_MODULE_INSTALL_DIR}) include_directories (${CMAKE_CURRENT_SOURCE_DIR}) if (BUILD_TESTING) diff --git a/src/include/kdbio/CMakeLists.txt b/src/include/kdbio/CMakeLists.txt index 820ac0348b1..b71fabcffa7 100644 --- a/src/include/kdbio/CMakeLists.txt +++ b/src/include/kdbio/CMakeLists.txt @@ -1,23 +1,14 @@ check_binding_included ("io_uv" IO_UV_INCLUDED SUBDIRECTORY "io/uv" SILENT) if (IO_UV_INCLUDED) - install ( - FILES uv.h - DESTINATION include/${TARGET_INCLUDE_FOLDER}/kdbio - COMPONENT elektra-misc) + install (FILES uv.h DESTINATION include/${TARGET_INCLUDE_FOLDER}/kdbio) endif () check_binding_included ("io_glib" IO_GLIB_INCLUDED SUBDIRECTORY "io/glib" SILENT) if (IO_GLIB_INCLUDED) - install ( - FILES glib.h - DESTINATION include/${TARGET_INCLUDE_FOLDER}/kdbio - COMPONENT elektra-misc) + install (FILES glib.h DESTINATION include/${TARGET_INCLUDE_FOLDER}/kdbio) endif () check_binding_included ("io_ev" IO_EV_INCLUDED SUBDIRECTORY "io/ev" SILENT) if (IO_EV_INCLUDED) - install ( - FILES ev.h - DESTINATION include/${TARGET_INCLUDE_FOLDER}/kdbio - COMPONENT elektra-misc) + install (FILES ev.h DESTINATION include/${TARGET_INCLUDE_FOLDER}/kdbio) endif () diff --git a/src/libs/merge/CMakeLists.txt b/src/libs/merge/CMakeLists.txt index 8d0ae391c63..ce50ec34e35 100644 --- a/src/libs/merge/CMakeLists.txt +++ b/src/libs/merge/CMakeLists.txt @@ -35,4 +35,4 @@ configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/${LIBRARY_NAME}.pc.in" "${CMAKE_CUR install ( FILES "${CMAKE_CURRENT_BINARY_DIR}/${LIBRARY_NAME}.pc" DESTINATION lib${LIB_SUFFIX}/${TARGET_PKGCONFIG_FOLDER} - COMPONENT elektra-misc) + COMPONENT libelektra-dev) diff --git a/src/plugins/jni/CMakeLists.txt b/src/plugins/jni/CMakeLists.txt index 5033e3f96cb..ec983362adb 100644 --- a/src/plugins/jni/CMakeLists.txt +++ b/src/plugins/jni/CMakeLists.txt @@ -32,7 +32,7 @@ add_plugin ( jni SOURCES jni.c INCLUDE_DIRECTORIES ${DIRS} - LINK_LIBRARIES ${LIBS} + LINK_LIBRARIES ${LIBS} COMPONENT libelektra4-java ONLY_SHARED) if (ADDTESTING_PHASE) diff --git a/src/plugins/resolver/CMakeLists.txt b/src/plugins/resolver/CMakeLists.txt index e7182f05747..b572806d6d4 100644 --- a/src/plugins/resolver/CMakeLists.txt +++ b/src/plugins/resolver/CMakeLists.txt @@ -60,7 +60,6 @@ foreach (plugin ${RESOLVERS}) set (SOURCES resolver.h resolver.c filename.c) - set (HAS_COMPONENT "") if (plugin MATCHES "resolver_fm_hpu_b") set (HAS_COMPONENT "libelektra4") else () diff --git a/src/plugins/ruby/CMakeLists.txt b/src/plugins/ruby/CMakeLists.txt index c93ff0802ca..658dfcc21d7 100644 --- a/src/plugins/ruby/CMakeLists.txt +++ b/src/plugins/ruby/CMakeLists.txt @@ -76,10 +76,7 @@ if (ADDTESTING_PHASE) ENVIRONMENT "RUBYLIB=${CMAKE_BINARY_DIR}/src/bindings/swig/ruby:${CMAKE_SOURCE_DIR}/src/bindings/swig/ruby") if (INSTALL_TESTING) - install ( - DIRECTORY ruby/ruby_test_scripts - DESTINATION ${TARGET_TEST_DATA_FOLDER} - COMPONENT elektra-misc) + install (DIRECTORY ruby/ruby_test_scripts DESTINATION ${TARGET_TEST_DATA_FOLDER}) endif () else () message (WARNING "ruby bindings are required for testing, test deactivated") diff --git a/src/plugins/yamlcpp/CMakeLists.txt b/src/plugins/yamlcpp/CMakeLists.txt index 5788ef30eac..b0b903269ce 100644 --- a/src/plugins/yamlcpp/CMakeLists.txt +++ b/src/plugins/yamlcpp/CMakeLists.txt @@ -53,4 +53,4 @@ add_plugin ( log.hpp INCLUDE_SYSTEM_DIRECTORIES ${yaml-cpp_INCLUDE_DIRS} LINK_LIBRARIES ${yaml-cpp_LIBRARIES} - LINK_ELEKTRA elektra-ease) + LINK_ELEKTRA elektra-ease COMPONENT libelektra4-yamlcpp) diff --git a/src/tools/elektrad/CMakeLists.txt b/src/tools/elektrad/CMakeLists.txt index ac8eb6a0b5d..c83cb4e7d2c 100644 --- a/src/tools/elektrad/CMakeLists.txt +++ b/src/tools/elektrad/CMakeLists.txt @@ -19,11 +19,8 @@ else () configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/temp-elektra.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/elektra.pc" @ONLY) # install files to destination - install ( - PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/run-elektrad ${CMAKE_CURRENT_BINARY_DIR}/run-elektrad - ${CMAKE_CURRENT_BINARY_DIR}/build-elektrad - DESTINATION ${TARGET_TOOL_EXEC_FOLDER} - COMPONENT elektra-misc) + install (PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/run-elektrad ${CMAKE_CURRENT_BINARY_DIR}/run-elektrad + ${CMAKE_CURRENT_BINARY_DIR}/build-elektrad DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) if (BUILD_SHARED) set (ELEKTRA_LIBS_ELEKTRAD elektra-core elektra-kdb elektra-plugin elektra-ease elektra-meta) @@ -46,11 +43,8 @@ else () add_custom_target (elektrad ALL DEPENDS "${CMAKE_CURRENT_BINARY_DIR}/elektrad/elektrad") # build elektra-web - install (CODE "message (\"-- Installing: elektra-web > elektrad\")" COMPONENT elektra-misc) - install ( - PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/elektrad/elektrad" - DESTINATION "${install_directory}" - COMPONENT elektra-misc) + install (CODE "message (\"-- Installing: elektra-web > elektrad\")") + install (PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/elektrad/elektrad" DESTINATION "${install_directory}") # generate manpages generate_manpage (kdb-run-elektrad FILENAME ${CMAKE_CURRENT_BINARY_DIR}/README.md) diff --git a/src/tools/gen-gpg-testkey/CMakeLists.txt b/src/tools/gen-gpg-testkey/CMakeLists.txt index 392fe5c5760..ed890d35d99 100644 --- a/src/tools/gen-gpg-testkey/CMakeLists.txt +++ b/src/tools/gen-gpg-testkey/CMakeLists.txt @@ -10,7 +10,7 @@ else () install ( TARGETS gen-gpg-testkey DESTINATION ${TARGET_TOOL_EXEC_FOLDER} - COMPONENT elektra-misc) + COMPONENT elektra-tests) else () remove_tool (gen-gpg-testkey "libgpgme version ${LIBGPGME_VERSION} is too old - minimum version required is 1.10") endif () diff --git a/src/tools/hub-zeromq/CMakeLists.txt b/src/tools/hub-zeromq/CMakeLists.txt index 40a1abc85ea..1587a704f84 100644 --- a/src/tools/hub-zeromq/CMakeLists.txt +++ b/src/tools/hub-zeromq/CMakeLists.txt @@ -25,16 +25,11 @@ else () # find installation path configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/run.sh" "${CMAKE_CURRENT_BINARY_DIR}/run-${tool}") configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/stop.sh" "${CMAKE_CURRENT_BINARY_DIR}/stop-${tool}") configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/README.md" "${CMAKE_CURRENT_BINARY_DIR}/README.md") # copy hub binary - install ( - TARGETS ${HUB} - DESTINATION ${install_directory} - COMPONENT elektra-misc) + install (TARGETS ${HUB} DESTINATION ${install_directory}) # install files to destination - install ( - PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/run-${tool} ${CMAKE_CURRENT_BINARY_DIR}/stop-${tool} - DESTINATION ${TARGET_TOOL_EXEC_FOLDER} - COMPONENT elektra-misc) + install (PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/run-${tool} ${CMAKE_CURRENT_BINARY_DIR}/stop-${tool} + DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) generate_manpage (kdb-run-${tool} FILENAME ${CMAKE_CURRENT_BINARY_DIR}/README.md) endif () diff --git a/src/tools/pythongen/CMakeLists.txt b/src/tools/pythongen/CMakeLists.txt index b4b9b44738d..24f5dc6c65f 100644 --- a/src/tools/pythongen/CMakeLists.txt +++ b/src/tools/pythongen/CMakeLists.txt @@ -14,8 +14,7 @@ if (PYTHON2INTERP_FOUND) \"${CMAKE_CURRENT_SOURCE_DIR}/pythongen\" -p tests/lift.ini \"${CMAKE_CURRENT_SOURCE_DIR}/util/util.c\" - -o \"${CMAKE_CURRENT_BINARY_DIR}/util.py\")" - COMPONENT elektra-misc) + -o \"${CMAKE_CURRENT_BINARY_DIR}/util.py\")") install ( CODE "execute_process(COMMAND @@ -23,8 +22,7 @@ if (PYTHON2INTERP_FOUND) \"${CMAKE_CURRENT_SOURCE_DIR}/pythongen\" -p tests/lift.ini \"${CMAKE_CURRENT_SOURCE_DIR}/util/util.cpp\" - -o \"${CMAKE_CURRENT_BINARY_DIR}/cpp_util.py\")" - COMPONENT elektra-misc) + -o \"${CMAKE_CURRENT_BINARY_DIR}/cpp_util.py\")") install ( CODE "execute_process(COMMAND @@ -36,8 +34,7 @@ if (PYTHON2INTERP_FOUND) --root=\$ENV{DESTDIR} --install-scripts=${CMAKE_INSTALL_PREFIX}/${TARGET_TOOL_EXEC_FOLDER} ${INSTALL_OPTIONS} - )" - COMPONENT elektra-misc) + )") function (pythongen_util TEMPLATE OUTPUT) diff --git a/src/tools/qt-gui/CMakeLists.txt b/src/tools/qt-gui/CMakeLists.txt index cb51cc063a1..88a5c74e88c 100644 --- a/src/tools/qt-gui/CMakeLists.txt +++ b/src/tools/qt-gui/CMakeLists.txt @@ -108,6 +108,6 @@ else () RENAME elektra-symbolic.svg COMPONENT elektra-qt-gui) - generate_manpage (kdb-qt-gui FILENAME ${CMAKE_CURRENT_SOURCE_DIR}/README.md) + generate_manpage (kdb-qt-gui FILENAME ${CMAKE_CURRENT_SOURCE_DIR}/README.md COMPONENT elektra-qt-gui) endif () diff --git a/src/tools/webd/CMakeLists.txt b/src/tools/webd/CMakeLists.txt index 4d33b065cab..31af8ee504f 100644 --- a/src/tools/webd/CMakeLists.txt +++ b/src/tools/webd/CMakeLists.txt @@ -24,30 +24,24 @@ else () install ( DIRECTORY . DESTINATION ${install_directory} - COMPONENT elektra-misc PATTERN "node_modules" EXCLUDE PATTERN "build" EXCLUDE) - install ( - FILES README.md - DESTINATION ${install_directory} - COMPONENT elektra-misc) - install ( - PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/run-webd ${CMAKE_CURRENT_BINARY_DIR}/build-webd - DESTINATION ${TARGET_TOOL_EXEC_FOLDER} - COMPONENT elektra-misc) + install (FILES README.md DESTINATION ${install_directory}) + install (PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/run-webd ${CMAKE_CURRENT_BINARY_DIR}/build-webd + DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) # build elektra-web - install (CODE "message (\"-- Installing: elektra-web > webd\")" COMPONENT elektra-misc) + install (CODE "message (\"-- Installing: elektra-web > webd\")") install ( CODE "execute_process (COMMAND npm install --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" - COMPONENT elektra-misc) + ) install ( CODE "execute_process (COMMAND npm run build --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" - COMPONENT elektra-misc) + ) install ( CODE "execute_process (COMMAND npm prune --production --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" - COMPONENT elektra-misc) + ) # generate manpages generate_manpage (kdb-run-webd FILENAME ${CMAKE_CURRENT_BINARY_DIR}/README.md) diff --git a/src/tools/website/CMakeLists.txt b/src/tools/website/CMakeLists.txt index 45c956ffc4f..f2952fecd91 100644 --- a/src/tools/website/CMakeLists.txt +++ b/src/tools/website/CMakeLists.txt @@ -26,24 +26,17 @@ else () configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/README.md" "${CMAKE_CURRENT_BINARY_DIR}/README.md") # install files to destination - install ( - DIRECTORY public resources - DESTINATION ${install_directory} - COMPONENT elektra-misc) - install ( - FILES package.json README.md ${CMAKE_CURRENT_BINARY_DIR}/Gruntfile.js application-config.json.tpl - DESTINATION ${install_directory} - COMPONENT elektra-misc) - install ( - PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/run-${tool} ${CMAKE_CURRENT_BINARY_DIR}/stop-${tool} - ${CMAKE_CURRENT_BINARY_DIR}/build-${tool} ${CMAKE_CURRENT_BINARY_DIR}/mount-${tool}-config - DESTINATION ${TARGET_TOOL_EXEC_FOLDER} - COMPONENT elektra-misc) + install (DIRECTORY public resources DESTINATION ${install_directory}) + install (FILES package.json README.md ${CMAKE_CURRENT_BINARY_DIR}/Gruntfile.js application-config.json.tpl + DESTINATION ${install_directory}) + install (PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/run-${tool} ${CMAKE_CURRENT_BINARY_DIR}/stop-${tool} + ${CMAKE_CURRENT_BINARY_DIR}/build-${tool} ${CMAKE_CURRENT_BINARY_DIR}/mount-${tool}-config + DESTINATION ${TARGET_TOOL_EXEC_FOLDER}) # attempt to install npm dependencies install ( CODE "execute_process (COMMAND npm install --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" - COMPONENT elektra-misc) + ) generate_manpage (kdb-run-${tool} FILENAME ${CMAKE_CURRENT_BINARY_DIR}/README.md) diff --git a/src/tools/webui/CMakeLists.txt b/src/tools/webui/CMakeLists.txt index cbda5fae865..3e4261c463d 100644 --- a/src/tools/webui/CMakeLists.txt +++ b/src/tools/webui/CMakeLists.txt @@ -14,24 +14,20 @@ else () install ( DIRECTORY . DESTINATION ${install_directory} - COMPONENT elektra-misc PATTERN "node_modules" EXCLUDE PATTERN "build" EXCLUDE) - install ( - FILES README.md - DESTINATION ${install_directory} - COMPONENT elektra-misc) + install (FILES README.md DESTINATION ${install_directory}) - install (CODE "message (\"-- Installing: elektra-web > webui\")" COMPONENT elektra-misc) + install (CODE "message (\"-- Installing: elektra-web > webui\")") install ( CODE "execute_process (COMMAND npm install --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" - COMPONENT elektra-misc) + ) install ( CODE "execute_process (COMMAND npm run build --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" - COMPONENT elektra-misc) + ) install ( CODE "execute_process (COMMAND npm prune --production --unsafe-perm WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${install_directory} OUTPUT_QUIET)" - COMPONENT elektra-misc) + ) endif ()