[all-commits] [llvm/llvm-project] dd2ce3: [LLVM] Add per-target runtime directory to rpath (...
Joseph Huber via All-commits
all-commits at lists.llvm.org
Wed May 27 08:11:03 PDT 2026
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: dd2ce3d8b558daefbbc6eb2f2026e6055a291f06
https://github.com/llvm/llvm-project/commit/dd2ce3d8b558daefbbc6eb2f2026e6055a291f06
Author: Joseph Huber <huberjn at outlook.com>
Date: 2026-05-27 (Wed, 27 May 2026)
Changed paths:
M llvm/cmake/modules/AddLLVM.cmake
Log Message:
-----------
[LLVM] Add per-target runtime directory to rpath (#199755)
Summary:
This simply adds the LLVM_DEFAULT_TARGET_TRIPLE to the LLVM build's
rpath if present. This keeps things hermetic for the library (offload)
that depends on it.
The reason this is required is because `llvm-gpu-loader` calls
`DynamicLibrary` on the Offload runtime. However, in a shared library
build the actual call is in libLLVMSupport.so, which does not have this
RPath, so `dlopen` delegates to that which does not know how to find it.
The only options to fix this are to use `dlopen` directly in the loader,
or add the rpath to the LLVM binaries.
I think this makes sense for LLVM, because the target-specific directory
can contain LLVM related libraries.
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list