summaryrefslogtreecommitdiff
path: root/repo/gcc/0021-Alpine-musl-package-provides-libssp_nonshared.a.-We-.patch
diff options
context:
space:
mode:
authordavidovski <david@davidovski.xyz>2022-05-31 11:05:19 +0100
committerdavidovski <david@davidovski.xyz>2022-05-31 11:05:19 +0100
commit48ca75555522716f0f686dcae3dd6cf3d8ad714d (patch)
tree00c0f58550ba4661e87376f2f02c8001c69bae44 /repo/gcc/0021-Alpine-musl-package-provides-libssp_nonshared.a.-We-.patch
parent871b2b573f01c1b3176a0f65458b3d281b41c437 (diff)
removed idea of repos
Diffstat (limited to 'repo/gcc/0021-Alpine-musl-package-provides-libssp_nonshared.a.-We-.patch')
-rw-r--r--repo/gcc/0021-Alpine-musl-package-provides-libssp_nonshared.a.-We-.patch31
1 files changed, 31 insertions, 0 deletions
diff --git a/repo/gcc/0021-Alpine-musl-package-provides-libssp_nonshared.a.-We-.patch b/repo/gcc/0021-Alpine-musl-package-provides-libssp_nonshared.a.-We-.patch
new file mode 100644
index 0000000..073d56f
--- /dev/null
+++ b/repo/gcc/0021-Alpine-musl-package-provides-libssp_nonshared.a.-We-.patch
@@ -0,0 +1,31 @@
+From c6b54651688cf062ae48ca3402d6d2e08b70ceed Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Timo=20Ter=C3=A4s?= <timo.teras@iki.fi>
+Date: Fri, 21 Aug 2020 07:03:00 +0000
+Subject: [PATCH] Alpine musl package provides libssp_nonshared.a. We link to
+ it unconditionally, as otherwise we get link failures if some objects are
+ -fstack-protector built and final link happens with -fno-stack-protector.
+ This seems to be the common case when bootstrapping gcc, the piepatches do
+ not seem to fully fix the crosstoolchain and bootstrap sequence wrt.
+ stack-protector flag usage.
+
+---
+ gcc/gcc.c | 3 +--
+ 1 file changed, 1 insertion(+), 2 deletions(-)
+
+diff --git a/gcc/gcc.c b/gcc/gcc.c
+index daeb4d0c8ea..6920bec0fa0 100644
+--- a/gcc/gcc.c
++++ b/gcc/gcc.c
+@@ -894,8 +894,7 @@ proper position among the other output files. */
+
+ #ifndef LINK_SSP_SPEC
+ #ifdef TARGET_LIBC_PROVIDES_SSP
+-#define LINK_SSP_SPEC "%{fstack-protector|fstack-protector-all" \
+- "|fstack-protector-strong|fstack-protector-explicit:}"
++#define LINK_SSP_SPEC "-lssp_nonshared"
+ #else
+ #define LINK_SSP_SPEC "%{fstack-protector|fstack-protector-all" \
+ "|fstack-protector-strong|fstack-protector-explicit" \
+--
+2.31.1
+