From e9786e30389829d73f4926ba0698551dd599b867 Mon Sep 17 00:00:00 2001 From: Renz Christian Bagaporo Date: Tue, 25 Jun 2019 11:00:30 +0800 Subject: [PATCH] cmake: make COMPONENT_TARGET available in components --- tools/cmake/components.cmake | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tools/cmake/components.cmake b/tools/cmake/components.cmake index bafad5c42..7bc4e3584 100644 --- a/tools/cmake/components.cmake +++ b/tools/cmake/components.cmake @@ -107,6 +107,8 @@ function(register_component) target_link_libraries(${component} "-L${CMAKE_CURRENT_BINARY_DIR}") target_link_libraries(${component} "-Wl,--whole-archive -l${component} -Wl,--no-whole-archive") endif() + + set(COMPONENT_TARGET ${COMPONENT_NAME} PARENT_SCOPE) endfunction() function(register_config_only_component)