blob: 1122d6ae1457183c5b2f2852a664fc39f6819502 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
|
From 59a72650c3ffcda09e430888e27750ee5008a957 Mon Sep 17 00:00:00 2001
From: Khem Raj <raj.khem@gmail.com>
Date: Sun, 17 Nov 2019 16:26:07 -0800
Subject: [PATCH] clangd: Always link with libatomic
Trace.cpp uses atomic<double> which is not available as instrinsic
its only added in c++20, until then link with libatomic
Another solution would be to not use double atomics something like below
- std::atomic<double> EndTime; // Filled in by markEnded().
+ std::atomic<int64_t> EndTime; // Filled in by markEnded().
but I don't know if this would be just the change needed or more is
required
Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
clang-tools-extra/clangd/CMakeLists.txt | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/clang-tools-extra/clangd/CMakeLists.txt b/clang-tools-extra/clangd/CMakeLists.txt
index f617f7931de..2be738c6097 100644
--- a/clang-tools-extra/clangd/CMakeLists.txt
+++ b/clang-tools-extra/clangd/CMakeLists.txt
@@ -29,10 +29,7 @@ if(CLANG_BUILT_STANDALONE)
include(CheckAtomic)
endif()
-set(CLANGD_ATOMIC_LIB "")
-if(NOT HAVE_CXX_ATOMICS64_WITHOUT_LIB)
- list(APPEND CLANGD_ATOMIC_LIB "atomic")
-endif()
+list(APPEND CLANGD_ATOMIC_LIB "atomic")
add_clang_library(clangDaemon
AST.cpp
|