[llvm-branch-commits] [clang] 0988add - Link libclangBasic against libatomic when necessary.

Tom Stellard via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Thu Nov 10 17:05:05 PST 2022


Author: Sam James
Date: 2022-11-10T17:04:34-08:00
New Revision: 0988addf2680b3717be47fd6f2493f33fe886f90

URL: https://github.com/llvm/llvm-project/commit/0988addf2680b3717be47fd6f2493f33fe886f90
DIFF: https://github.com/llvm/llvm-project/commit/0988addf2680b3717be47fd6f2493f33fe886f90.diff

LOG: Link libclangBasic against libatomic when necessary.

This is necessary at least on PPC32.

Depends on D136280.

Bug: https://bugs.gentoo.org/874024
Thanks-to: Arfrever Frehtes Taifersar Arahesis <Arfrever at Apache.Org>
Tested-by: erhard_f at mailbox.org <erhard_f at mailbox.org>

Differential Revision: https://reviews.llvm.org/D136282

(cherry picked from commit 20132d8eaa68a6c53e152718beda1dc0f4c9ff6c)

Added: 
    

Modified: 
    clang/CMakeLists.txt
    clang/lib/Basic/CMakeLists.txt

Removed: 
    


################################################################################
diff  --git a/clang/CMakeLists.txt b/clang/CMakeLists.txt
index 13d76e7fd935a..e3bc4b468fb66 100644
--- a/clang/CMakeLists.txt
+++ b/clang/CMakeLists.txt
@@ -117,6 +117,7 @@ if(CLANG_BUILT_STANDALONE)
   include(TableGen)
   include(HandleLLVMOptions)
   include(VersionFromVCS)
+  include(CheckAtomic)
   include(GetErrcMessages)
   include(LLVMDistributionSupport)
 

diff  --git a/clang/lib/Basic/CMakeLists.txt b/clang/lib/Basic/CMakeLists.txt
index 3e052c0cf9957..c38c9fddb4240 100644
--- a/clang/lib/Basic/CMakeLists.txt
+++ b/clang/lib/Basic/CMakeLists.txt
@@ -110,3 +110,7 @@ add_clang_library(clangBasic
   omp_gen
   )
 
+target_link_libraries(clangBasic
+  PRIVATE
+  ${LLVM_ATOMIC_LIB}
+)


        


More information about the llvm-branch-commits mailing list