blob: 1631332dbc72bae20a066e3c10b05e5a08a51dec [file] [log] [blame]
Soby Mathewb4c6df42022-11-09 11:13:29 +00001#
2# SPDX-License-Identifier: BSD-3-Clause
3# SPDX-FileCopyrightText: Copyright TF-RMM Contributors.
4#
5
6if(NOT RMM_ARCH STREQUAL fake_host)
7 add_library(rmm-lib-libc)
8
9 target_link_libraries(rmm-lib-libc
10 PUBLIC rmm-lib-arch
11 rmm-lib-common
12 rmm-lib-debug)
13
14 target_include_directories(rmm-lib-libc SYSTEM
15 PUBLIC "include")
16
17 target_sources(rmm-lib-libc
18 PRIVATE "src/abort.c"
19 "src/assert.c"
20 "src/memcmp.c"
21 "src/memcpy.c"
22 "src/memmove.c"
23 "src/printf.c"
24 "src/strlen.c"
25 "src/strcmp.c"
26 "src/strlcpy.c"
27 "src/strncmp.c"
28 "src/strnlen.c")
29
30 target_sources(rmm-lib-libc
31 PRIVATE
32 "src/aarch64/memset.S")
33
34target_compile_definitions(rmm-lib-libc
35 PRIVATE "PRINTF_DISABLE_SUPPORT_FLOAT")
36else()
37 add_library(rmm-lib-libc INTERFACE)
38endif()