Build: Update app_broker build
Update app_broker build to make dependencies more stable.
- Sort NS library folder structure.
Move common library folders out of app_broker. Place them under lib
folder. Move CMSIS to lib/ext.
It is expected that users can re-use those library in other NS
integration with TF-M.
- NS libraries depend on each other and therefore the dependencies are
complicated. Build those NS libraries under app_broker to more
easily sort out dependencies. Remove build files from library
folders.
Signed-off-by: David Hu <david.hu@arm.com>
Change-Id: I8c2ff7bbec6c03738b9cbe49fd286a5147293ba5
diff --git a/tests_reg/CMakeLists.txt b/tests_reg/CMakeLists.txt
index ef95cca..a60f744 100644
--- a/tests_reg/CMakeLists.txt
+++ b/tests_reg/CMakeLists.txt
@@ -38,14 +38,13 @@
# Test configurations
include(${CMAKE_CURRENT_LIST_DIR}/test/config/default_test_config.cmake)
-add_subdirectory(${CMAKE_CURRENT_LIST_DIR}/../lib/ext ${CMAKE_BINARY_DIR}/lib/ext)
-
include(${TFM_TOOLCHAIN_FILE})
project(tfm_ns LANGUAGES C ASM)
tfm_toolchain_reload_compiler()
add_executable(tfm_ns)
+add_subdirectory(${CMAKE_CURRENT_LIST_DIR}/../lib/ext ${CMAKE_BINARY_DIR}/lib/ext)
add_subdirectory(../app_broker ${CMAKE_BINARY_DIR}/app_broker)
add_subdirectory(test)
diff --git a/tests_reg/test/CMakeLists.txt b/tests_reg/test/CMakeLists.txt
index a9558a5..aa2025f 100644
--- a/tests_reg/test/CMakeLists.txt
+++ b/tests_reg/test/CMakeLists.txt
@@ -19,7 +19,6 @@
target_include_directories(tfm_test_framework_common
INTERFACE
framework
- ${CMAKE_CURRENT_LIST_DIR}/../../app_broker/log
)
add_subdirectory(secure_fw)
diff --git a/tests_reg/test/bl2/mcuboot/CMakeLists.txt b/tests_reg/test/bl2/mcuboot/CMakeLists.txt
index fa83278..4dd1028 100644
--- a/tests_reg/test/bl2/mcuboot/CMakeLists.txt
+++ b/tests_reg/test/bl2/mcuboot/CMakeLists.txt
@@ -11,7 +11,7 @@
# So a dedicated library is duplicated here, and it links the platform_s instead of platform_ns.
# TO-DO: find a better approach to reference the directory
-set(LOG_SOURCE_ROOT ${CMAKE_CURRENT_LIST_DIR}/../../../../app_broker/log)
+set(LOG_SOURCE_ROOT ${CMAKE_CURRENT_LIST_DIR}/../../../../lib/log)
add_library(mcuboot_test_log INTERFACE)
add_library(mcuboot_test_log_interface INTERFACE)
diff --git a/tests_reg/test/secure_fw/suites/multi_core/non_secure/CMakeLists.txt b/tests_reg/test/secure_fw/suites/multi_core/non_secure/CMakeLists.txt
index 9b15af1..9f65ff2 100644
--- a/tests_reg/test/secure_fw/suites/multi_core/non_secure/CMakeLists.txt
+++ b/tests_reg/test/secure_fw/suites/multi_core/non_secure/CMakeLists.txt
@@ -33,14 +33,11 @@
target_link_libraries(tfm_test_suite_multi_core_ns
PRIVATE
tfm_test_framework_ns
+ ns_multi_core
+ os_wrapper
)
target_link_libraries(tfm_ns_tests
INTERFACE
tfm_test_suite_multi_core_ns
)
-
-target_compile_definitions(tfm_api_ns
- PUBLIC
- TFM_MULTI_CORE_TEST
-)