Enhance standard library integration
This change makes the split between standard library related and non
standard library related build settings cleaner. This may make
enabling other standard libraries to be used in SPs easier
Changes:
- the standard library target is renamed to stdlib::c
- newlib specific files moved to newlib component
- GCC flags changing standard library related search paths moved to
newlib component
- modified newlib targets to use transitive dependencies to get
libnosys.a linked
- newlib component defines the -nostdinc flag again
Change-Id: I5e9ef72cc42454c70d234a15d516634eea51d494
Signed-off-by: Gyorgy Szing <Gyorgy.Szing@arm.com>
diff --git a/environments/opteesp/component.cmake b/environments/opteesp/component.cmake
index f6a65cd..1b7c418 100644
--- a/environments/opteesp/component.cmake
+++ b/environments/opteesp/component.cmake
@@ -11,9 +11,6 @@
target_sources(${TGT} PRIVATE
"${CMAKE_CURRENT_LIST_DIR}/optee_sp_header.c"
- "${CMAKE_CURRENT_LIST_DIR}/newlib_init.c"
- "${CMAKE_CURRENT_LIST_DIR}/newlib_sp_assert.c"
- "${CMAKE_CURRENT_LIST_DIR}/newlib_sp_heap.c"
"${CMAKE_CURRENT_LIST_DIR}/sp_entry.c"
"${CMAKE_CURRENT_LIST_DIR}/sp_trace.c"
)
@@ -36,8 +33,7 @@
include(../../../external/newlib/newlib.cmake)
target_link_libraries(${TGT} PRIVATE
- c
- nosys
+ stdlib::c
)
target_link_options(${TGT} PRIVATE