-
Notifications
You must be signed in to change notification settings - Fork 89
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into feature/511-remove-resolver
# Conflicts: # libs/framework/CMakeLists.txt
- Loading branch information
Showing
313 changed files
with
5,152 additions
and
2,199 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
name: Conan Create | ||
|
||
on: | ||
push: | ||
pull_request: | ||
schedule: | ||
- cron: '0 0 * * *' | ||
|
||
jobs: | ||
|
||
ubuntu-build: | ||
runs-on: ubuntu-20.04 | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
compiler: [ [gcc,g++], [clang,clang++] ] | ||
type: [ Debug ] | ||
timeout-minutes: 120 | ||
steps: | ||
- name: Checkout source code | ||
uses: actions/checkout@v3.3.0 | ||
- name: Install build dependencies | ||
run: | | ||
sudo pip install -U conan==1.59.0 | ||
sudo apt-get install -yq --no-install-recommends ninja-build | ||
- name: Setup Conan Profile | ||
env: | ||
CC: ${{ matrix.compiler[0] }} | ||
CXX: ${{ matrix.compiler[1] }} | ||
run: | | ||
# build profile | ||
conan profile new release --detect | ||
conan profile update settings.build_type=Release release | ||
#Note no backwards compatiblity for gcc5 needed, setting libcxx to c++11. | ||
conan profile update settings.compiler.libcxx=libstdc++11 release | ||
conan profile show release | ||
# host profile | ||
conan profile new default --detect | ||
conan profile update settings.build_type=${{ matrix.type }} default | ||
#Note no backwards compatiblity for gcc5 needed, setting libcxx to c++11. | ||
conan profile update settings.compiler.libcxx=libstdc++11 default | ||
conan profile show default | ||
- name: Create Celix | ||
env: | ||
CC: ${{ matrix.compiler[0] }} | ||
CXX: ${{ matrix.compiler[1] }} | ||
CONAN_CMAKE_GENERATOR: Ninja | ||
run: | | ||
conan inspect . -a options | awk 'BEGIN { FS="[\t:]+" } /build/ && !/build_all/ { print $1}' | while read option; do conan create . -b missing -o celix:${option}=True -pr:b release -pr:h default -tf examples/conan_test_package -tbf test-build -o celix:celix_cxx17=True -o celix:celix_install_deprecated_api=True --require-override=libcurl/7.64.1 --require-override=openssl/1.1.1s --require-override=zlib/1.2.13 || exit 1; done | ||
mac-build: | ||
runs-on: macOS-11 | ||
timeout-minutes: 120 | ||
steps: | ||
- name: Checkout source code | ||
uses: actions/checkout@v3.3.0 | ||
- name: Install build dependencies | ||
run: | | ||
brew install python ninja | ||
pip3 install -U conan==1.59.0 | ||
- name: Setup Conan Profile | ||
run: | | ||
conan profile new default --detect | ||
conan profile update settings.build_type=Release default | ||
- name: Create Celix | ||
env: | ||
CC: ${{ matrix.compiler[0] }} | ||
CXX: ${{ matrix.compiler[1] }} | ||
CONAN_CMAKE_GENERATOR: Ninja | ||
run: | | ||
conan inspect . -a options | awk 'BEGIN { FS="[\t:]+" } /build/ && !/build_all/ { print $1}' | while read option; do conan create . -b missing -o celix:${option}=True -pr:b default -pr:h default -tf examples/conan_test_package -tbf test-build -o celix:celix_cxx17=True -o celix:celix_install_deprecated_api=True --require-override=libcurl/7.64.1 --require-override=openssl/1.1.1s --require-override=zlib/1.2.13 || exit 1; done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
# Licensed to the Apache Software Foundation (ASF) under one | ||
# or more contributor license agreements. See the NOTICE file | ||
# distributed with this work for additional information | ||
# regarding copyright ownership. The ASF licenses this file | ||
# to you 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. | ||
|
||
celix_subproject(COMPONENTS_READY_CHECK "Bundle that checks if all components becomes active and reports this using a condition service" ON) | ||
if (COMPONENTS_READY_CHECK) | ||
|
||
add_library(components_ready_api INTERFACE) | ||
target_include_directories(components_ready_api INTERFACE $<BUILD_INTERFACE:${CMAKE_CURRENT_LIST_DIR}/api>) | ||
add_library(Celix::components_ready_api ALIAS components_ready_api) | ||
install(TARGETS components_ready_api EXPORT celix DESTINATION ${CMAKE_INSTALL_LIBDIR} COMPONENT components_ready | ||
INCLUDES DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/celix_components_ready_api) | ||
install(DIRECTORY api/ DESTINATION include/celix_components_ready_api COMPONENT components_ready) | ||
|
||
|
||
set(COMPONENTS_READY_CHECK_SRC src/celix_components_ready_check.c) | ||
set(COMPONENTS_READY_CHECK_DEPS Celix::framework Celix::components_ready_api) | ||
add_celix_bundle(components_ready_check | ||
SOURCES src/celix_components_ready_check_activator.c ${COMPONENTS_READY_CHECK_SRC} | ||
VERSION 1.0.0 | ||
SYMBOLIC_NAME "apache_celix_components_ready_check" | ||
GROUP "Celix/Conditions" | ||
NAME "Apache Celix Components Ready Check" | ||
FILENAME celix_components_ready_check | ||
) | ||
target_include_directories(components_ready_check PRIVATE src) | ||
target_link_libraries(components_ready_check PRIVATE ${COMPONENTS_READY_CHECK_DEPS}) | ||
add_library(Celix::components_ready_check ALIAS components_ready_check) | ||
install_celix_bundle(components_ready_check EXPORT celix COMPONENT components_ready) | ||
|
||
if (ENABLE_TESTING) | ||
add_library(components_ready_cut STATIC ${COMPONENTS_READY_CHECK_SRC}) | ||
target_include_directories(components_ready_cut PUBLIC src) | ||
target_link_libraries(components_ready_cut PUBLIC ${COMPONENTS_READY_CHECK_DEPS}) | ||
add_subdirectory(gtest) | ||
endif() | ||
endif () |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
--- | ||
title: Shell | ||
--- | ||
|
||
<!-- | ||
Licensed to the Apache Software Foundation (ASF) under one or more | ||
contributor license agreements. See the NOTICE file distributed with | ||
this work for additional information regarding copyright ownership. | ||
The ASF licenses this file to You 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. | ||
--> | ||
|
||
# Apache Celix Component Ready | ||
|
||
## Intro | ||
The Apache Celix Component Ready provides an api and bundle which can be used to check if all components are ready. | ||
|
||
## API library | ||
The Apache Celix Component Ready Check provides a single api library `Celix::component_ready_api` which contains | ||
the condition id constant used to register the "components.ready" condition service. | ||
|
||
## Bundle | ||
The Apache Celix Component Ready Check provides the `Celix::components_ready_check` bundle which registers the | ||
"components.ready" condition service. | ||
|
||
The "components.ready" condition service will be registered when the "framework.ready" service is registered, | ||
all components have become active and the event queue is empty. | ||
|
||
If the "components.ready" condition service is registered and some components become inactive or the event queue is | ||
not empty, the "components.ready" condition is **not** removed. The "components.ready" condition is meant to indicate | ||
that the components in the initial framework startup phase are ready. | ||
|
||
## CMake options | ||
|
||
- COMPONENTS_READY_CHECK=ON | ||
|
||
## Using info | ||
|
||
If the Apache Celix Component Ready is installed, `find_package(Celix)` will set: | ||
- The `Celix::component_ready_api` interface (i.e. header only) library target | ||
- The `Celix::components_ready_check` bundle target |
39 changes: 39 additions & 0 deletions
39
bundles/components_ready_check/api/celix_components_ready_constants.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
/* | ||
* Licensed to the Apache Software Foundation (ASF) under one | ||
* or more contributor license agreements. See the NOTICE file | ||
* distributed with this work for additional information | ||
* regarding copyright ownership. The ASF licenses this file | ||
* to you 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. | ||
*/ | ||
|
||
#ifndef CELIX_COMPONENTS_READY_CONSTANTS_H_ | ||
#define CELIX_COMPONENTS_READY_CONSTANTS_H_ | ||
|
||
#ifdef __cplusplus | ||
extern "C" { | ||
#endif | ||
|
||
/*! | ||
* @brief The unique identifier for the components.ready condition. | ||
* | ||
* The components ready condition is registered by the framework if the framework.ready condition is registered | ||
* and all components active. | ||
*/ | ||
#define CELIX_CONDITION_ID_COMPONENTS_READY "components.ready" | ||
|
||
#ifdef __cplusplus | ||
} | ||
#endif | ||
|
||
#endif /* CELIX_COMPONENTS_READY_CONSTANTS_H_ */ |
Oops, something went wrong.