Skip to content

Commit 51e2229

Browse files
topolarityKristofferC
authored and
KristofferC
committed
make: Fix sed command for LLVM libraries with no symbol versioning (#54672)
If the LLVM library was built without symbol versioning, previously this would return the `nm` output in its entirety, instead of correctly reporting "" as the LLVM symbol version. (cherry picked from commit debaa73)
1 parent 936673b commit 51e2229

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ ifneq ($(USE_SYSTEM_LLVM),0)
120120
# USE_SYSTEM_LLVM != 0
121121
CG_LLVMLINK += $(LLVM_LDFLAGS) $(shell $(LLVM_CONFIG_HOST) --libs --system-libs)
122122
LLVM_SHLIB_SYMBOL_VERSION := $(shell nm -D --with-symbol-versions $(shell $(LLVM_CONFIG_HOST) --libfiles --link-shared | awk '{print $1; exit}') | \
123-
grep _ZN4llvm3Any6TypeId | head -n 1 | sed -e 's/.*@//')
123+
grep _ZN4llvm3Any6TypeId | head -n 1 | sed -ne 's/.*@//p')
124124

125125
# HACK: llvm-config doesn't correctly point to shared libs on all platforms
126126
# https://github.com/JuliaLang/julia/issues/29981

0 commit comments

Comments
 (0)