When linking LLVMOrcJit on ARMv6, I get an error about a missing reference to __atomic_fetch_add_8.
This seems to be because on platforms without hardware support, we need to link in atomic.
The full error is below:
[ 66%] Linking CXX shared library ../../libLLVMOrcJIT.so /usr/bin/ld: CMakeFiles/LLVMOrcJIT.dir/ObjectLinkingLayer.cpp.o: in function `llvm::orc::ObjectLinkingLayer::add(llvm::IntrusiveRefCntPtr<llvm::orc::ResourceTracker>, std::unique_ptr<llvm::jitlink::LinkGraph, std::default_delete<llvm::jitlink::LinkGraph> >)': ObjectLinkingLayer.cpp:(.text._ZN4llvm3orc18ObjectLinkingLayer3addENS_18IntrusiveRefCntPtrINS0_15ResourceTrackerEEESt10unique_ptrINS_7jitlink9LinkGraphESt14default_deleteIS7_EE+0x3e0): undefined reference to `__atomic_fetch_add_8' collect2: error: ld returned 1 exit status gmake[2]: *** [lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/build.make:659: lib/libLLVMOrcJIT.so.14] Error 1 gmake[1]: *** [CMakeFiles/Makefile2:13868: lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/all] Error 2 gmake: *** [Makefile:171: all] Error 2