mirror of
https://github.com/ARM-software/arm-trusted-firmware.git
synced 2025-04-21 20:14:29 +00:00
fix(libc): add memcpy_s source file to libc_asm mk
Change [1] introduced the memcpy_s function and added the source file to lib/libc/libc.mk but omitted to update lib/libc/libc_asm.mk Arm platforms (and platforms from one partner) use OVERRIDE_LIBC=1 option as a platform default hence consume libc_asm.mk To prevent this confusion to happen again, create libc_common.mk for the common set of C files to build. libc_common.mk is included by both libc.mk and libc_asm.mk The latter adds asm implementations of libc functions. [1] https://review.trustedfirmware.org/c/TF-A/trusted-firmware-a/+/21450 Signed-off-by: Olivier Deprez <olivier.deprez@arm.com> Change-Id: Ibd36ea5c561e35f268048ccbefc8f47485f64bdf
This commit is contained in:
parent
c9f05a326f
commit
99db13bfaa
3 changed files with 49 additions and 69 deletions
lib/libc
|
@ -1,42 +1,8 @@
|
||||||
#
|
#
|
||||||
# Copyright (c) 2016-2021, Arm Limited and Contributors. All rights reserved.
|
# Copyright (c) 2016-2024, Arm Limited and Contributors. All rights reserved.
|
||||||
#
|
#
|
||||||
# SPDX-License-Identifier: BSD-3-Clause
|
# SPDX-License-Identifier: BSD-3-Clause
|
||||||
#
|
#
|
||||||
|
#
|
||||||
|
|
||||||
LIBC_SRCS := $(addprefix lib/libc/, \
|
include lib/libc/libc_common.mk
|
||||||
abort.c \
|
|
||||||
assert.c \
|
|
||||||
exit.c \
|
|
||||||
memchr.c \
|
|
||||||
memcmp.c \
|
|
||||||
memcpy.c \
|
|
||||||
memcpy_s.c \
|
|
||||||
memmove.c \
|
|
||||||
memrchr.c \
|
|
||||||
memset.c \
|
|
||||||
printf.c \
|
|
||||||
putchar.c \
|
|
||||||
puts.c \
|
|
||||||
snprintf.c \
|
|
||||||
strchr.c \
|
|
||||||
strcmp.c \
|
|
||||||
strlcat.c \
|
|
||||||
strlcpy.c \
|
|
||||||
strlen.c \
|
|
||||||
strncmp.c \
|
|
||||||
strnlen.c \
|
|
||||||
strrchr.c \
|
|
||||||
strtok.c \
|
|
||||||
strtoul.c \
|
|
||||||
strtoll.c \
|
|
||||||
strtoull.c \
|
|
||||||
strtol.c)
|
|
||||||
|
|
||||||
ifeq (${ARCH},aarch64)
|
|
||||||
LIBC_SRCS += $(addprefix lib/libc/aarch64/, \
|
|
||||||
setjmp.S)
|
|
||||||
endif
|
|
||||||
|
|
||||||
INCLUDES += -Iinclude/lib/libc \
|
|
||||||
-Iinclude/lib/libc/$(ARCH) \
|
|
||||||
|
|
|
@ -1,44 +1,15 @@
|
||||||
#
|
#
|
||||||
# Copyright (c) 2020-2021, Arm Limited. All rights reserved.
|
# Copyright (c) 2020-2024, Arm Limited. All rights reserved.
|
||||||
#
|
#
|
||||||
# SPDX-License-Identifier: BSD-3-Clause
|
# SPDX-License-Identifier: BSD-3-Clause
|
||||||
#
|
#
|
||||||
|
|
||||||
LIBC_SRCS := $(addprefix lib/libc/, \
|
include lib/libc/libc_common.mk
|
||||||
abort.c \
|
|
||||||
assert.c \
|
|
||||||
exit.c \
|
|
||||||
memchr.c \
|
|
||||||
memcmp.c \
|
|
||||||
memcpy.c \
|
|
||||||
memmove.c \
|
|
||||||
memrchr.c \
|
|
||||||
printf.c \
|
|
||||||
putchar.c \
|
|
||||||
puts.c \
|
|
||||||
snprintf.c \
|
|
||||||
strchr.c \
|
|
||||||
strcmp.c \
|
|
||||||
strlcat.c \
|
|
||||||
strlcpy.c \
|
|
||||||
strlen.c \
|
|
||||||
strncmp.c \
|
|
||||||
strnlen.c \
|
|
||||||
strrchr.c \
|
|
||||||
strtok.c \
|
|
||||||
strtoul.c \
|
|
||||||
strtoll.c \
|
|
||||||
strtoull.c \
|
|
||||||
strtol.c)
|
|
||||||
|
|
||||||
ifeq (${ARCH},aarch64)
|
ifeq (${ARCH},aarch64)
|
||||||
LIBC_SRCS += $(addprefix lib/libc/aarch64/, \
|
LIBC_SRCS += $(addprefix lib/libc/aarch64/, \
|
||||||
memset.S \
|
memset.S)
|
||||||
setjmp.S)
|
|
||||||
else
|
else
|
||||||
LIBC_SRCS += $(addprefix lib/libc/aarch32/, \
|
LIBC_SRCS += $(addprefix lib/libc/aarch32/, \
|
||||||
memset.S)
|
memset.S)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
INCLUDES += -Iinclude/lib/libc \
|
|
||||||
-Iinclude/lib/libc/$(ARCH) \
|
|
||||||
|
|
43
lib/libc/libc_common.mk
Normal file
43
lib/libc/libc_common.mk
Normal file
|
@ -0,0 +1,43 @@
|
||||||
|
#
|
||||||
|
# Copyright (c) 2024, Arm Limited and Contributors. All rights reserved.
|
||||||
|
#
|
||||||
|
# SPDX-License-Identifier: BSD-3-Clause
|
||||||
|
#
|
||||||
|
|
||||||
|
LIBC_SRCS := $(addprefix lib/libc/, \
|
||||||
|
abort.c \
|
||||||
|
assert.c \
|
||||||
|
exit.c \
|
||||||
|
memchr.c \
|
||||||
|
memcmp.c \
|
||||||
|
memcpy.c \
|
||||||
|
memcpy_s.c \
|
||||||
|
memmove.c \
|
||||||
|
memrchr.c \
|
||||||
|
memset.c \
|
||||||
|
printf.c \
|
||||||
|
putchar.c \
|
||||||
|
puts.c \
|
||||||
|
snprintf.c \
|
||||||
|
strchr.c \
|
||||||
|
strcmp.c \
|
||||||
|
strlcat.c \
|
||||||
|
strlcpy.c \
|
||||||
|
strlen.c \
|
||||||
|
strncmp.c \
|
||||||
|
strnlen.c \
|
||||||
|
strrchr.c \
|
||||||
|
strtok.c \
|
||||||
|
strtoul.c \
|
||||||
|
strtoll.c \
|
||||||
|
strtoull.c \
|
||||||
|
strtol.c)
|
||||||
|
|
||||||
|
ifeq (${ARCH},aarch64)
|
||||||
|
LIBC_SRCS += $(addprefix lib/libc/aarch64/, \
|
||||||
|
setjmp.S)
|
||||||
|
endif
|
||||||
|
|
||||||
|
INCLUDES += -Iinclude/lib/libc \
|
||||||
|
-Iinclude/lib/libc/$(ARCH) \
|
||||||
|
|
Loading…
Add table
Reference in a new issue