Skip to content

Commit 25986a2

Browse files
committed
[llvm-jitlink] Don't hardcode LLVM version number into the runtime path.
This should unbreak builders that were failing due to different patch numbers.
1 parent ae70b21 commit 25986a2

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

llvm/tools/llvm-jitlink/llvm-jitlink.cpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1191,7 +1191,11 @@ static Error sanitizeArguments(const Triple &TT, const char *ArgV0) {
11911191
if (DefaultOrcRuntimePath.endswith("bin"))
11921192
sys::path::remove_filename(DefaultOrcRuntimePath); // remove 'bin'
11931193
sys::path::append(DefaultOrcRuntimePath,
1194-
"lib/clang/13.0.0/lib/darwin/libclang_rt.orc_osx.a");
1194+
("lib/clang/" + Twine(LLVM_VERSION_MAJOR) + "." +
1195+
Twine(LLVM_VERSION_MINOR) + "." +
1196+
Twine(LLVM_VERSION_PATCH) +
1197+
"/lib/darwin/libclang_rt.orc_osx.a")
1198+
.str());
11951199
OrcRuntimePath = DefaultOrcRuntimePath.str().str();
11961200
}
11971201
}

0 commit comments

Comments
 (0)