aboutsummaryrefslogtreecommitdiff
path: root/GNUmakefile
diff options
context:
space:
mode:
Diffstat (limited to 'GNUmakefile')
-rw-r--r--GNUmakefile2
1 files changed, 2 insertions, 0 deletions
diff --git a/GNUmakefile b/GNUmakefile
index 015ca92..99a2f75 100644
--- a/GNUmakefile
+++ b/GNUmakefile
@@ -51,6 +51,8 @@ dependency/build/libmusl-extract: dependency/sources/$(LIBMUSL).tar.gz | depende
touch $@
dependency/build/libmusl-configure: dependency/build/libmusl-extract
+ # tweak musl gcc wrapper/spec file to support static PIE linking
+ sed -i 's#%{pie:S}crt1.o#%{pie:%{static:rcrt1.o%s;:Scrt1.o%s};:crt1.o%s}#' $(dir $<)/$(LIBMUSL)/tools/musl-gcc.specs.sh
cd $(dir $<)/$(LIBMUSL) && ./configure --prefix=$(DEPS_PREFIX) --syslibdir=$(DEPS_PREFIX)/lib
touch $@