Skip to content

Commit 03d5720

Browse files
committed
hm
1 parent 1a56c45 commit 03d5720

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

build/musl-pie-linker.sh

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,13 @@
1-
#!/bin/sh
1+
#!/bin/bash
22
# Linker wrapper for musl builds that need dynamic GTK.
33
# Replaces -static-pie with -pie to allow dynamic library loading
44
# while keeping musl libc statically linked.
5-
exec cc $(echo "$@" | sed 's/-static-pie/-pie/g')
5+
args=()
6+
for arg in "$@"; do
7+
if [ "$arg" = "-static-pie" ]; then
8+
args+=("-pie")
9+
else
10+
args+=("$arg")
11+
fi
12+
done
13+
exec cc "${args[@]}"

0 commit comments

Comments
 (0)