[clang-tools-extra] r329053 - [clangd][cmake] Provide libatomic when there is no native support for 64bit atomics

Simon Dardis via cfe-commits cfe-commits at lists.llvm.org
Tue Apr 3 02:40:07 PDT 2018


Author: sdardis
Date: Tue Apr  3 02:40:07 2018
New Revision: 329053

URL: http://llvm.org/viewvc/llvm-project?rev=329053&view=rev
Log:
[clangd][cmake] Provide libatomic when there is no native support for 64bit atomics

This addresses a persistent failure on clang-cmake-mips buildbot.

Reviewers: ioeric

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

Modified:
    clang-tools-extra/trunk/clangd/CMakeLists.txt

Modified: clang-tools-extra/trunk/clangd/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/clangd/CMakeLists.txt?rev=329053&r1=329052&r2=329053&view=diff
==============================================================================
--- clang-tools-extra/trunk/clangd/CMakeLists.txt (original)
+++ clang-tools-extra/trunk/clangd/CMakeLists.txt Tue Apr  3 02:40:07 2018
@@ -2,6 +2,11 @@ set(LLVM_LINK_COMPONENTS
   Support
   )
 
+set(CLANGD_ATOMIC_LIB "")
+if(NOT HAVE_CXX_ATOMICS64_WITHOUT_LIB)
+  list(APPEND CLANGD_ATOMIC_LIB "atomic")
+endif()
+
 add_clang_library(clangDaemon
   AST.cpp
   ClangdLSPServer.cpp
@@ -50,6 +55,7 @@ add_clang_library(clangDaemon
   clangToolingCore
   clangToolingRefactor
   ${LLVM_PTHREAD_LIB}
+  ${CLANGD_ATOMIC_LIB}
   )
 
 if( LLVM_LIB_FUZZING_ENGINE OR LLVM_USE_SANITIZE_COVERAGE )




More information about the cfe-commits mailing list