You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In some Linux distros like Debian, LLVM_AVAILABLE_LIBS contains both static and shared libraries in LLVM shipped with apt install llvm-dev, and acquires more packages to be installed, even though they are not actually needed. The log below shows the result of llvm-dev shipped with Debian 12, which is actually llvm-14.
Here LLVMDebuginfod acquires CURL::libcurl, which means I have to install libcurl-openssl-dev and then add find_package(CURL REQUIRED) before find_package(LLVM "14.0" REQUIRED CONFIG).
Most of libraries above are static, but something like LLVM, Polly are actually shared libraries. Linking all of them to jit causes
And ldd shows the executable requires LLVM-14.so, which is unnecessary.
I think we can filter out useless libraries from the list, and ensure that the final executables are fully statically or fully dynamically linked to LLVM.
QDP-JIT links all available LLVM libraries to target
jit
by usingLLVM_AVAILABLE_LIBS
.qdp-jit/lib/CMakeLists.txt
Line 100 in 7ffb650
In some Linux distros like Debian,
LLVM_AVAILABLE_LIBS
contains both static and shared libraries in LLVM shipped withapt install llvm-dev
, and acquires more packages to be installed, even though they are not actually needed. The log below shows the result ofllvm-dev
shipped with Debian 12, which is actuallyllvm-14
.Here
LLVMDebuginfod
acquiresCURL::libcurl
, which means I have to installlibcurl-openssl-dev
and then addfind_package(CURL REQUIRED)
beforefind_package(LLVM "14.0" REQUIRED CONFIG)
.Most of libraries above are static, but something like
LLVM
,Polly
are actually shared libraries. Linking all of them tojit
causesAnd
ldd
shows the executable requiresLLVM-14.so
, which is unnecessary.I think we can filter out useless libraries from the list, and ensure that the final executables are fully statically or fully dynamically linked to LLVM.
FYI, I use
to exclude unnecessary libraries, and the executable is statically linked against LLVM now.
The text was updated successfully, but these errors were encountered: