aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--main/gcc/APKBUILD10
1 files changed, 10 insertions, 0 deletions
diff --git a/main/gcc/APKBUILD b/main/gcc/APKBUILD
index 3396796f5f..bf70b921f2 100644
--- a/main/gcc/APKBUILD
+++ b/main/gcc/APKBUILD
@@ -382,6 +382,16 @@ package() {
rm -rf "$pkgdir"/usr/bin/cc "$pkgdir"/usr/include "$pkgdir"/usr/share
# libcc1 does not depend on target, don't ship it
rm -rf "$pkgdir"/usr/lib/libcc1.so*
+
+ # fixup gcc library symlinks to be linker scripts so
+ # linker finds the libs from relocated sysroot
+ for so in "$pkgdir"/usr/$CTARGET/lib/*.so; do
+ if [ -h "$so" ]; then
+ local _real=$(basename $(readlink "$so"))
+ rm -f "$so"
+ echo "GROUP ($_real)" > "$so"
+ fi
+ done
fi
}