summaryrefslogtreecommitdiff
path: root/toolchain
diff options
context:
space:
mode:
authorWaldemar Brodkorb <wbx@openadk.org>2016-03-26 10:52:31 +0100
committerWaldemar Brodkorb <wbx@openadk.org>2016-03-26 10:52:31 +0100
commit2bea9aa06273cdd6476f10b52a320f8c18e788ea (patch)
treed3a142bd6f691cb982874c89f1414fa3580cc069 /toolchain
parent1279a32b8f92fe49e56bdb0e6601e223147da06d (diff)
sh2: fix elf2flt build
Diffstat (limited to 'toolchain')
-rw-r--r--toolchain/elf2flt/patches/git/0001-fix-sh2-toolchain-building.patch49
1 files changed, 49 insertions, 0 deletions
diff --git a/toolchain/elf2flt/patches/git/0001-fix-sh2-toolchain-building.patch b/toolchain/elf2flt/patches/git/0001-fix-sh2-toolchain-building.patch
new file mode 100644
index 000000000..11d3a1e5f
--- /dev/null
+++ b/toolchain/elf2flt/patches/git/0001-fix-sh2-toolchain-building.patch
@@ -0,0 +1,49 @@
+From 123fe2e98cce5c82d81d2a350529a1ea712a4058 Mon Sep 17 00:00:00 2001
+From: Waldemar Brodkorb <wbx@openadk.org>
+Date: Sat, 26 Mar 2016 10:26:56 +0100
+Subject: [PATCH] fix sh2 toolchain building
+
+
+Signed-off-by: Waldemar Brodkorb <wbx@openadk.org>
+---
+ elf2flt.c | 10 ++++++----
+ 1 file changed, 6 insertions(+), 4 deletions(-)
+
+diff --git a/elf2flt.c b/elf2flt.c
+index 7d0e639..3546341 100644
+--- a/elf2flt.c
++++ b/elf2flt.c
+@@ -101,8 +101,10 @@ const char *elf2flt_progname;
+ #define ARCH "sparc"
+ #elif defined(TARGET_v850)
+ #define ARCH "v850"
+-#elif defined(TARGET_sh)
+-#define ARCH "sh"
++#elif defined(TARGET_sh2)
++#define ARCH "sh2"
++#elif defined(TARGET_sh2eb)
++#define ARCH "sh2"
+ #elif defined(TARGET_h8300)
+ #define ARCH "h8300"
+ #elif defined(TARGET_microblaze)
+@@ -1260,7 +1262,7 @@ NIOS2_RELOC_ERR:
+ #endif /* TARGET_sparc */
+
+
+-#ifdef TARGET_sh
++#if defined(TARGET_sh2) || defined(TARGET_sh2eb)
+ case R_SH_DIR32:
+ relocation_needed = 1;
+ sym_vma = bfd_section_vma(abs_bfd, sym_section);
+@@ -1271,7 +1273,7 @@ NIOS2_RELOC_ERR:
+ sym_addr += sym_vma + q->addend;
+ sym_addr -= q->address;
+ break;
+-#endif /* TARGET_sh */
++#endif /* TARGET_sh2 / TARGET_sh2eb */
+
+ #ifdef TARGET_e1
+ #define htoe1l(x) htonl(x)
+--
+1.7.10.4
+