From 18ed63b8f13c9d90d953c8803b0bb22632fe3c7a Mon Sep 17 00:00:00 2001 From: Dimitry Andric Date: Thu, 10 Sep 2020 16:47:12 +0000 Subject: [PATCH] Follow-up r364753 by only using arm's stdatomic.c implementation, as it already covers the functions in compiler-rt's atomic.c, leading to conflicts when linking. PR: 230888 MFC after: 3 days X-MFC-With: r364753 --- lib/libcompiler_rt/Makefile.inc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/libcompiler_rt/Makefile.inc b/lib/libcompiler_rt/Makefile.inc index 10797e93e63b..aa0a6a6c9e69 100644 --- a/lib/libcompiler_rt/Makefile.inc +++ b/lib/libcompiler_rt/Makefile.inc @@ -124,7 +124,8 @@ SRCF+= umodti3 # Enable compiler-rt's atomic implementation only for clang, as it uses clang # specific builtins, and gcc packages usually come with their own libatomic. -.if "${COMPILER_TYPE}" == "clang" +# Exclude arm which has its own implementations of atomic functions, below. +.if "${COMPILER_TYPE}" == "clang" && ${MACHINE_CPUARCH} != "arm" SRCF+= atomic .endif