Skip to content
Snippets Groups Projects
Commit cfdadd3e authored by Steven Barth's avatar Steven Barth
Browse files

gcc: musl comes with its own SSP, so use it instead of libssp


Signed-off-by: default avatarSteven Barth <steven@midlink.org>

SVN-Revision: 46071
parent fc5f0241
No related branches found
No related tags found
No related merge requests found
...@@ -16,6 +16,10 @@ ifneq ($(CONFIG_GCC_VERSION_4_5)$(CONFIG_GCC_VERSION_4_6),) ...@@ -16,6 +16,10 @@ ifneq ($(CONFIG_GCC_VERSION_4_5)$(CONFIG_GCC_VERSION_4_6),)
--with-libelf=$(TOPDIR)/staging_dir/host --with-libelf=$(TOPDIR)/staging_dir/host
endif endif
ifdef CONFIG_USE_MUSL
GCC_MAKE += gcc_cv_libc_provides_ssp=yes
endif
ifneq ($(CONFIG_SJLJ_EXCEPTIONS),) ifneq ($(CONFIG_SJLJ_EXCEPTIONS),)
GCC_CONFIGURE += \ GCC_CONFIGURE += \
--enable-sjlj-exceptions --enable-sjlj-exceptions
......
--- gcc-4.7.4.org/gcc/gcc.c
+++ gcc-4.7.4/gcc/gcc.c
@@ -603,7 +603,7 @@
#ifndef LINK_SSP_SPEC
#ifdef TARGET_LIBC_PROVIDES_SSP
-#define LINK_SSP_SPEC "%{fstack-protector:}"
+#define LINK_SSP_SPEC "%{fstack-protector|fstack-protector-all:-lssp_nonshared}"
#else
#define LINK_SSP_SPEC "%{fstack-protector|fstack-protector-all:-lssp_nonshared -lssp}"
#endif
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment