forked from OSchip/llvm-project
[LLDB][MIPS] Check if libatomic needs to be specified explicitly
Patch by Nitesh Jain. Summary : The problem appears while linking liblldb.so. The class Address contain atomic variable m_offset. The loading and storing of variable is access via atomic_load_8 and atomic_store_8 functions. Some target fail to implicitly link libatomic, which cause undefine reference to atomic_store_8/atomic_load_8. This patch uses http://reviews.llvm.org/D20896 to check if libatomic need to be explicitly link. Reviewed by labath. Differential: D20464 llvm-svn: 274121
This commit is contained in:
parent
56fac57b57
commit
067b6edc1f
|
@ -157,6 +157,11 @@ if (NOT CMAKE_SYSTEM_NAME MATCHES "Windows" AND NOT __ANDROID_NDK__)
|
|||
endif()
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if (NOT HAVE_CXX_ATOMICS64_WITHOUT_LIB )
|
||||
list(APPEND LLDB_SYSTEM_LIBS atomic)
|
||||
endif()
|
||||
|
||||
# On FreeBSD/NetBSD backtrace() is provided by libexecinfo, not libc.
|
||||
if (CMAKE_SYSTEM_NAME MATCHES "FreeBSD" OR CMAKE_SYSTEM_NAME MATCHES "NetBSD")
|
||||
list(APPEND LLDB_SYSTEM_LIBS execinfo)
|
||||
|
|
Loading…
Reference in New Issue