From 1c7d6584a7811b7785ae5c1e378f14b5ba0971cf Mon Sep 17 00:00:00 2001 From: takeshi_hoshina Date: Mon, 2 Nov 2020 11:07:33 +0900 Subject: basesystem-jj recipes --- ...4-pass-fix-v4bx-to-linker-to-support-EABI.patch | 43 ++++++++++++++++++++++ 1 file changed, 43 insertions(+) create mode 100644 bsp/meta-arm/meta-arm-toolchain/recipes-devtools/gcc/gcc-arm-8.3/0016-gcc-armv4-pass-fix-v4bx-to-linker-to-support-EABI.patch (limited to 'bsp/meta-arm/meta-arm-toolchain/recipes-devtools/gcc/gcc-arm-8.3/0016-gcc-armv4-pass-fix-v4bx-to-linker-to-support-EABI.patch') diff --git a/bsp/meta-arm/meta-arm-toolchain/recipes-devtools/gcc/gcc-arm-8.3/0016-gcc-armv4-pass-fix-v4bx-to-linker-to-support-EABI.patch b/bsp/meta-arm/meta-arm-toolchain/recipes-devtools/gcc/gcc-arm-8.3/0016-gcc-armv4-pass-fix-v4bx-to-linker-to-support-EABI.patch new file mode 100644 index 00000000..9b1b4d4d --- /dev/null +++ b/bsp/meta-arm/meta-arm-toolchain/recipes-devtools/gcc/gcc-arm-8.3/0016-gcc-armv4-pass-fix-v4bx-to-linker-to-support-EABI.patch @@ -0,0 +1,43 @@ +From a66ec1e382bf869749588f072a4a7c09039f2b3a Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Fri, 29 Mar 2013 09:30:32 +0400 +Subject: [PATCH 16/40] gcc: armv4: pass fix-v4bx to linker to support EABI. + +The LINK_SPEC for linux gets overwritten by linux-eabi.h which +means the value of TARGET_FIX_V4BX_SPEC gets lost and as a result +the option is not passed to linker when chosing march=armv4 +This patch redefines this in linux-eabi.h and reinserts it +for eabi defaulting toolchains. + +We might want to send it upstream. + +Signed-off-by: Khem Raj + +Upstream-Status: Pending +--- + gcc/config/arm/linux-eabi.h | 6 +++++- + 1 file changed, 5 insertions(+), 1 deletion(-) + +diff --git a/gcc/config/arm/linux-eabi.h b/gcc/config/arm/linux-eabi.h +index b3af68cac57..330b6e13c5f 100644 +--- a/gcc/config/arm/linux-eabi.h ++++ b/gcc/config/arm/linux-eabi.h +@@ -88,10 +88,14 @@ + #define MUSL_DYNAMIC_LINKER \ + "/lib/ld-musl-arm" MUSL_DYNAMIC_LINKER_E "%{mfloat-abi=hard:hf}.so.1" + ++/* For armv4 we pass --fix-v4bx to linker to support EABI */ ++#undef TARGET_FIX_V4BX_SPEC ++#define TARGET_FIX_V4BX_SPEC "%{mcpu=arm8|mcpu=arm810|mcpu=strongarm*|march=armv4: --fix-v4bx}" ++ + /* At this point, bpabi.h will have clobbered LINK_SPEC. We want to + use the GNU/Linux version, not the generic BPABI version. */ + #undef LINK_SPEC +-#define LINK_SPEC EABI_LINK_SPEC \ ++#define LINK_SPEC TARGET_FIX_V4BX_SPEC EABI_LINK_SPEC \ + LINUX_OR_ANDROID_LD (LINUX_TARGET_LINK_SPEC, \ + LINUX_TARGET_LINK_SPEC " " ANDROID_LINK_SPEC) + +-- +2.21.0 + -- cgit 1.2.3-korg