PengZheng commented on code in PR #453:
URL: https://github.com/apache/celix/pull/453#discussion_r1044184355


##########
documents/cmake_commands/README.md:
##########
@@ -499,6 +501,10 @@ Optional Arguments:
 - LEVEL: The run level for the added bundles. Default is 3.
 - INSTALL: If this option is present, the bundles will only be installed 
instead of the default install and start.
   The bundles will be installed after all bundle in LEVEL 0..6 are installed 
and started.
+- COPY: If this option is present, the bundles will be copied to the container 
build dir. This option overrides the
+  NO_COPY option used in the add_celix_container call.
+- NO_COPY: If this option is present, the install/start bundles will be 
configured using a absolute path to the
+  bundle. This option overrides optional NO_COPY option used in the 
add_celix_container call.

Review Comment:
   ```suggestion
     bundle. This option overrides optional COPY option used in the 
add_celix_container call.
   ```
   
   A typo?



##########
examples/celix-examples/bundles_copy_example/CMakeLists.txt:
##########
@@ -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.
+
+######################## Examples for the COPY / NO_COPY option in 
celix_container_bundles work #######################
+
+if (TARGET Celix::log_admin AND TARGET Celix::shell AND TARGET 
Celix::shell_tui AND TARGET Celix::syslog_writer)
+    #By default bundles in a container will be copied to the bundles dir in 
the container dir
+    add_celix_container(copy_bundles_example1 BUNDLES Celix::log_admin)
+    #The shell bundle will also be copied, because of the container copy config
+    celix_container_bundles(copy_bundles_example1 LEVEL 1 Celix::shell)
+    #The shell_tui bundle will not be copied, because of the NO_COPY option
+    celix_container_bundles(copy_bundles_example1 NO_COPY LEVEL 1 
Celix::shell_tui)
+    #The log_writer_syslog bundle will be copied, because of the COPY option
+    celix_container_bundles(copy_bundles_example1 LEVEL 2 COPY 
Celix::syslog_writer)
+
+
+    #Bundles in this container will not be copied to the bundles dir in the 
container dir, because of the NO_COPY option
+    add_celix_container(copy_bundles_example2 NO_COPY BUNDLES Celix::log_admin)
+    #The shell bundle will also mpt be copied, because of the container copy 
config

Review Comment:
   ```suggestion
       #The shell bundle will also not be copied, because of the container copy 
config
   ```
   
   typo?



##########
cmake/cmake_celix/ContainerPackaging.cmake:
##########
@@ -263,7 +264,16 @@ 
$<JOIN:$<TARGET_PROPERTY:${CONTAINER_TARGET},CONTAINER_EMBEDDED_PROPERTIES>,\\n\
 "
         )
 
-        file(GENERATE OUTPUT "${LAUNCHER_SRC}" INPUT "${STAGE1_LAUNCHER_SRC}")
+        #Rerun generate to do a second parsing of generator expressions
+        file(GENERATE OUTPUT "${STAGE2_LAUNCHER_SRC}" INPUT 
"${STAGE1_LAUNCHER_SRC}")

Review Comment:
   I'm also curious about this.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscr...@celix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to