From 565baddd63a916bf1bb346a196ab57ec42ee1212 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nagy=20K=C3=A1roly=20G=C3=A1briel?= Date: Sat, 7 Nov 2015 20:06:07 +0000 Subject: [PATCH] musl: enhanced to build a libssp so the one from gcc is not needed. --- base/musl/musl.conf | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/base/musl/musl.conf b/base/musl/musl.conf index fd869db68..fdfe809de 100644 --- a/base/musl/musl.conf +++ b/base/musl/musl.conf @@ -47,8 +47,13 @@ musl_postinstall() { } musl_make_utils() { + # build minimal libssp_nonshared.a so we don't need libssp from gcc + # comes from Alpine Linux + gcc $CPPFLAGS $CFLAGS -c $confdir/__stack_chk_fail_local.c -o __stack_chk_fail_local.o + $AR r libssp_nonshared.a __stack_chk_fail_local.o + cp -a libssp_nonshared.a $root/$libdir/ # getent is needed by OpenSDE framework. - $CC $CPPFLAGS $CFLAGS $confdir/getent.c -o $root/$sbindir/getent + gcc $CPPFLAGS $CFLAGS $confdir/getent.c -o $root/$sbindir/getent } # if musl is default libc @@ -60,7 +65,7 @@ if [ "$SDECFG_LIBC" == "musl" ]; then hook_add postinstall 5 'musl_postinstall' fi hook_add postflist 9 "rm -rf $root/$includedir/libintl.h" - hook_add postmake 5 'musl_make_utils' + hook_add postpatch 5 'musl_make_utils' fi # always install the headers even if already present in the sandbox