Skip to content

Commit 00f4910

Browse files
committed
Allow pulling in of libLLVMSupport for cxx11 string ABI detection
This is necessary on platforms where `libLLVM` is split up into multiple shared libraries, so a single `libLLVM` does not exist.
1 parent 92cb40f commit 00f4910

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

src/PlatformNames.jl

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -639,11 +639,17 @@ close enough for our purposes, as you can't mix linkages between Julia and LLVM
639639
are not compiled in the same way).
640640
"""
641641
function detect_cxx11_string_abi()
642-
hdl = dlopen(@static Sys.iswindows() ? "LLVM" : "libLLVM")
643-
if hdl == C_NULL
642+
function open_libllvm()
643+
for lib_name in ("libLLVM", "LLVM", "libLLVMSupport")
644+
hdl = dlopen_e(lib_name)
645+
if hdl != C_NULL
646+
return hdl
647+
end
648+
end
644649
error("Unable to open libLLVM!")
645650
end
646651

652+
hdl = open_libllvm()
647653
# Check for llvm::sys::getProcessTriple(), first without cxx11 tag:
648654
if dlsym_e(hdl, "_ZN4llvm3sys16getProcessTripleEv") != C_NULL
649655
return :cxx03

0 commit comments

Comments
 (0)