[PATCH] D69444: [Support] Check for atomics64 when deciding if '-latomic' is needed
Gokturk Yuksek via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Oct 25 12:38:29 PDT 2019
gokturk created this revision.
gokturk added reviewers: beanz, compnerd.
Herald added subscribers: llvm-commits, jfb, hiraditya, mgorny.
Herald added a project: LLVM.
The CheckAtomic module performs two tests to determine if passing
'-latomic' to the linker is required: one for 64-bit atomics, and
another for non-64-bit atomics. Include the missing check for 64-bit
atomics.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D69444
Files:
llvm/lib/Support/CMakeLists.txt
Index: llvm/lib/Support/CMakeLists.txt
===================================================================
--- llvm/lib/Support/CMakeLists.txt
+++ llvm/lib/Support/CMakeLists.txt
@@ -26,7 +26,7 @@
set(system_libs ${system_libs} ${TERMINFO_LIBS})
endif()
endif()
- if( LLVM_ENABLE_THREADS AND HAVE_LIBATOMIC )
+ if( LLVM_ENABLE_THREADS AND (HAVE_LIBATOMIC OR HAVE_CXX_LIBATOMICS64) )
set(system_libs ${system_libs} atomic)
endif()
set(system_libs ${system_libs} ${LLVM_PTHREAD_LIB})
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D69444.226483.patch
Type: text/x-patch
Size: 510 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20191025/0a2bc6d1/attachment.bin>
More information about the llvm-commits
mailing list