This is an automated email from the ASF dual-hosted git repository.
abroekhuis pushed a commit to branch feature/support_multiple_build_types
in repository https://gitbox.apache.org/repos/asf/celix.git
The following commit(s) were added to
refs/heads/feature/support_multiple_build_types by this push:
new dc49710 Updated Config to use build type specific CelixTargets.
dc49710 is described below
commit dc4971036d54418a41de1b1547ff3d902703841e
Author: Alexander Broekhuis <[email protected]>
AuthorDate: Mon Apr 20 16:25:23 2020 +0200
Updated Config to use build type specific CelixTargets.
---
cmake/CelixConfig.cmake | 2 +-
cmake/cmake_celix/BundlePackaging.cmake | 10 +++++-----
2 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/cmake/CelixConfig.cmake b/cmake/CelixConfig.cmake
index 5dae9be..3f60854 100644
--- a/cmake/CelixConfig.cmake
+++ b/cmake/CelixConfig.cmake
@@ -30,7 +30,7 @@ get_filename_component(REL_INSTALL_DIR "${REL_INSTALL_DIR}"
PATH)
include("${REL_INSTALL_DIR}/share/celix/cmake/cmake_celix/UseCelix.cmake")
#adds celix commands (e.g. add_celix_bundle)
include("${REL_INSTALL_DIR}/share/celix/cmake/Targets.cmake") #imports lib and
exe targets (e.g. Celix::framework)
-include("${REL_INSTALL_DIR}/share/celix/cmake/CelixTargets.cmake") #imports
bundle targets (e.g. Celix::shell)
+include("${REL_INSTALL_DIR}/share/celix/cmake/CelixTargets-${CMAKE_BUILD_TYPE}.cmake")
#imports bundle targets (e.g. Celix::shell)
# The rest is added to ensure backwards compatiblity with project using the
cmake lib/include var instead of targets.
set(CELIX_CMAKE_MODULES_DIR ${REL_INSTALL_DIR}/share/celix/cmake/Modules)
diff --git a/cmake/cmake_celix/BundlePackaging.cmake
b/cmake/cmake_celix/BundlePackaging.cmake
index 2f22b5b..b34fa13 100644
--- a/cmake/cmake_celix/BundlePackaging.cmake
+++ b/cmake/cmake_celix/BundlePackaging.cmake
@@ -107,7 +107,7 @@ Optional arguments are:
- GROUP: The group the bundle is part of. This will be used as Bundle-Group
manifest entry. Default this is empty (no group).
- VERSION: The bundle version. This will be used for the Bundle-Version
manifest entry. In combination with SOURCES the version will also be used to
set the activator library target property VERSION and SOVERSION.
For SOVERSION only the major part is used. Expected scheme is
"<major>.<minor>.<path>". Default version is "0.0.0"
-- FILENAME: The filename of the bundle file. Default is
<bundle_target_name>.zip.
+- FILENAME: The filename of the bundle file, without extension. Default is
<bundle_target_name>.zip.
- PRIVATE_LIBRARIES: private libraries to be included in the bundle. Specified
libraries are added to the "Private-Library" manifest statement and added in
the root of the bundle. libraries can be cmake library targets or absolute
paths to existing libraries.
- HEADERS: Additional headers values that are appended to the bundle manifest.
@@ -190,12 +190,12 @@ function(add_celix_bundle)
set(BUNDLE_SYMBOLIC_NAME ${BUNDLE_TARGET_NAME})
endif ()
- if (NOT DEFINED BUNDLE_FILENAME AND NOT CMAKE_BUILD_TYPE STREQUAL
"Release")
- set(BUNDLE_FILENAME ${BUNDLE_TARGET_NAME}-${CMAKE_BUILD_TYPE}.zip)
- elseif(NOT DEFINED BUNDLE_FILENAME)
- set(BUNDLE_FILENAME ${BUNDLE_TARGET_NAME}.zip)
+ if (NOT DEFINED BUNDLE_FILENAME)
+ set(BUNDLE_FILENAME ${BUNDLE_TARGET_NAME})
endif ()
+ set(BUNDLE_FILENAME ${BUNDLE_FILENAME}-${CMAKE_BUILD_TYPE}.zip)
+
set(BUNDLE_FILE "${CMAKE_CURRENT_BINARY_DIR}/${BUNDLE_FILENAME}")
#set(BUNDLE_CONTENT_DIR
"${CMAKE_CURRENT_BINARY_DIR}/${BUNDLE_TARGET_NAME}_content")
#set(BUNDLE_GEN_DIR
"${CMAKE_CURRENT_BINARY_DIR}/${BUNDLE_TARGET_NAME}_gen")