From 234dd95e0bd57c165fe63aca97d8b7dccf83b389 Mon Sep 17 00:00:00 2001 From: zhanghongyu Date: Tue, 31 Oct 2023 17:40:04 +0800 Subject: [PATCH] libc_atomic: add file to cmake script resolves an error where atomic related symbols cannot be found at cmake compile time. Signed-off-by: zhanghongyu --- libs/libc/machine/CMakeLists.txt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/libs/libc/machine/CMakeLists.txt b/libs/libc/machine/CMakeLists.txt index 9089bb00d2..21230144d0 100644 --- a/libs/libc/machine/CMakeLists.txt +++ b/libs/libc/machine/CMakeLists.txt @@ -19,3 +19,7 @@ # ############################################################################## add_subdirectory(${CONFIG_ARCH}) + +if(CONFIG_LIBC_ARCH_ATOMIC) + target_sources(c PRIVATE arch_atomic.c) +endif()