aboutsummaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/gcc/gcc-5.4/0050-powerpc-pass-secure-plt-to-the-linker.patch
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2016-06-24 08:53:09 -0700
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-07-01 16:22:44 +0100
commit1bf0944925dc0bb53b12b0f6623be0401e236e53 (patch)
tree77a614bca62066e300df6c307251d43dcd20c3ac /meta/recipes-devtools/gcc/gcc-5.4/0050-powerpc-pass-secure-plt-to-the-linker.patch
parent0412b6d90d9eaa424cd0e6b7f205ba7f6622625c (diff)
downloadopenembedded-core-contrib-1bf0944925dc0bb53b12b0f6623be0401e236e53.tar.gz
gcc5: Upgrade to gcc 5.4
Drop patches which has been applied to gcc5 branch until 5.4 release (From OE-Core rev: 42487843f846ae61f8bd1b2278d148ff37f0d667) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/gcc/gcc-5.4/0050-powerpc-pass-secure-plt-to-the-linker.patch')
-rw-r--r--meta/recipes-devtools/gcc/gcc-5.4/0050-powerpc-pass-secure-plt-to-the-linker.patch66
1 files changed, 66 insertions, 0 deletions
diff --git a/meta/recipes-devtools/gcc/gcc-5.4/0050-powerpc-pass-secure-plt-to-the-linker.patch b/meta/recipes-devtools/gcc/gcc-5.4/0050-powerpc-pass-secure-plt-to-the-linker.patch
new file mode 100644
index 0000000000..b2f2bbdf46
--- /dev/null
+++ b/meta/recipes-devtools/gcc/gcc-5.4/0050-powerpc-pass-secure-plt-to-the-linker.patch
@@ -0,0 +1,66 @@
+From 4fa0cf03678f849917dcc3d149989b7fecdbe276 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 2 Feb 2016 21:10:00 -0800
+Subject: [PATCH 50/51] powerpc pass --secure-plt to the linker
+
+Secure-plt when enabled does not pass right options to linker
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Pending
+ gcc/config/rs6000/linux64.h | 4 ++++
+ gcc/config/rs6000/sysv4.h | 2 ++
+ 2 files changed, 6 insertions(+)
+
+diff --git a/gcc/config/rs6000/linux64.h b/gcc/config/rs6000/linux64.h
+index 679da4b..3ca7cd7 100644
+--- a/gcc/config/rs6000/linux64.h
++++ b/gcc/config/rs6000/linux64.h
+@@ -174,20 +174,24 @@ extern int dot_symbols;
+ #undef ASM_DEFAULT_SPEC
+ #undef ASM_SPEC
+ #undef LINK_OS_LINUX_SPEC
++#undef LINK_SECURE_PLT_SPEC
+
+ #ifndef RS6000_BI_ARCH
+ #define ASM_DEFAULT_SPEC "-mppc64"
+ #define ASM_SPEC "%(asm_spec64) %(asm_spec_common)"
+ #define LINK_OS_LINUX_SPEC "%(link_os_linux_spec64)"
++#define LINK_SECURE_PLT_SPEC ""
+ #else
+ #if DEFAULT_ARCH64_P
+ #define ASM_DEFAULT_SPEC "-mppc%{!m32:64}"
+ #define ASM_SPEC "%{m32:%(asm_spec32)}%{!m32:%(asm_spec64)} %(asm_spec_common)"
+ #define LINK_OS_LINUX_SPEC "%{m32:%(link_os_linux_spec32)}%{!m32:%(link_os_linux_spec64)}"
++#define LINK_SECURE_PLT_SPEC "%{m32: " LINK_SECURE_PLT_DEFAULT_SPEC "}"
+ #else
+ #define ASM_DEFAULT_SPEC "-mppc%{m64:64}"
+ #define ASM_SPEC "%{!m64:%(asm_spec32)}%{m64:%(asm_spec64)} %(asm_spec_common)"
+ #define LINK_OS_LINUX_SPEC "%{!m64:%(link_os_linux_spec32)}%{m64:%(link_os_linux_spec64)}"
++#define LINK_SECURE_PLT_SPEC "%{!m64: " LINK_SECURE_PLT_DEFAULT_SPEC "}"
+ #endif
+ #endif
+
+diff --git a/gcc/config/rs6000/sysv4.h b/gcc/config/rs6000/sysv4.h
+index 8794fa5..0835551 100644
+--- a/gcc/config/rs6000/sysv4.h
++++ b/gcc/config/rs6000/sysv4.h
+@@ -571,6 +571,7 @@ ENDIAN_SELECT(" -mbig", " -mlittle", DEFAULT_ASM_ENDIAN)
+ : %(link_start_default) }"
+
+ #define LINK_START_DEFAULT_SPEC ""
++#define LINK_SECURE_PLT_SPEC LINK_SECURE_PLT_DEFAULT_SPEC
+
+ #undef LINK_SPEC
+ #define LINK_SPEC "\
+@@ -578,6 +579,7 @@ ENDIAN_SELECT(" -mbig", " -mlittle", DEFAULT_ASM_ENDIAN)
+ %{R*} \
+ %(link_shlib) \
+ %{!T*: %(link_start) } \
++%{!static: %{!mbss-plt: %(link_secure_plt_default)}} \
+ %(link_os)"
+
+ /* Shared libraries are not default. */
+--
+2.7.0
+