Skip to content

Commit d71a920

Browse files
fix: restrict dynamic library bundling to Haskell-specific libs
1 parent c49871d commit d71a920

1 file changed

Lines changed: 6 additions & 2 deletions

File tree

  • packages/haskell-language-server

packages/haskell-language-server/build.sh

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,10 @@ cp "$HLS_BIN" "$OUTPUT_DIR"/usr/bin/
2626
# Copy all shared Haskell libraries the binary depends on
2727
for lib in $(ldd "$HLS_BIN" | grep '\.so' | awk '{print $3}'); do
2828
if [ -n "$lib" ] && [ -f "$lib" ]; then
29-
cp "$lib" "$OUTPUT_DIR"/usr/lib/
29+
libname="${lib##*/}"
30+
# Only copy Haskell-specific libraries (libHS*) to avoid bundling standard system glibc/loader libraries
31+
if [[ "$libname" == libHS* ]]; then
32+
cp "$lib" "$OUTPUT_DIR"/usr/lib/
33+
fi
3034
fi
31-
done
35+
done

0 commit comments

Comments
 (0)