Build: Add the tfm NS log library
This part is missed for the new build system.
The NS log implementations have been seperated from the TF-M.
The NS is using the one in TF-M.
This patch adds the NS log library.
Corresponding changes are required in TF-M repo to
1. Add the NS log library to build
2. Remove the build for the log implementation in NS interface
Change-Id: Ic71b244fb93651974422b49a24d08e5a270dd5f5
Signed-off-by: Kevin Peng <kevin.peng@arm.com>
diff --git a/log/CMakeLists.txt b/log/CMakeLists.txt
new file mode 100644
index 0000000..1993428
--- /dev/null
+++ b/log/CMakeLists.txt
@@ -0,0 +1,34 @@
+#-------------------------------------------------------------------------------
+# Copyright (c) 2020, Arm Limited. All rights reserved.
+#
+# SPDX-License-Identifier: BSD-3-Clause
+#
+#-------------------------------------------------------------------------------
+
+cmake_minimum_required(VERSION 3.13)
+
+# For multi-core projects, the NS app can be run on a different CPU to the
+# Secure code. To facilitate this, we once again reload the compiler to load the
+# setting for the NS CPU. Cmake settings are directory scoped so this affects
+# anything loaded from or declared in this dir.
+if (TFM_MULTI_CORE_TOPOLOGY)
+ include(${CMAKE_SOURCE_DIR}/platform/ext/target/${TFM_PLATFORM}/preload_ns.cmake)
+endif()
+
+############################# Ns Log ###########################################
+add_library(tfm_ns_log STATIC EXCLUDE_FROM_ALL)
+
+target_sources(tfm_ns_log
+ PRIVATE
+ tfm_log_raw.c
+)
+
+target_include_directories(tfm_ns_log
+ PUBLIC
+ .
+)
+
+target_link_libraries(tfm_ns_log
+ PRIVATE
+ platform_ns
+)