mailarchive of the ptxdist mailing list
 help / color / mirror / Atom feed
From: "Andreas Bießmann" <andreas@biessmann.de>
To: PTXdist ML <ptxdist@pengutronix.de>
Cc: "Andreas Bießmann" <andreas@biessmann.de>
Subject: [ptxdist] [OSELAS.Toolchain PATCH 1/2] patches/gcc-4.7.2: add eabi fix for armv4
Date: Sat,  6 Jul 2013 19:00:27 +0200	[thread overview]
Message-ID: <1373130028-17640-2-git-send-email-andreas@biessmann.de> (raw)
In-Reply-To: <1373130028-17640-1-git-send-email-andreas@biessmann.de>

Signed-off-by: Andreas Bießmann <andreas@biessmann.de>

---
 .../0501-arm-eabi-pass-fix-v4bx-to-ld.patch        |   49 ++++++++++++++++++++
 patches/gcc-4.7.2/series                           |    3 +-
 2 files changed, 51 insertions(+), 1 deletion(-)
 create mode 100644 patches/gcc-4.7.2/0501-arm-eabi-pass-fix-v4bx-to-ld.patch

diff --git a/patches/gcc-4.7.2/0501-arm-eabi-pass-fix-v4bx-to-ld.patch b/patches/gcc-4.7.2/0501-arm-eabi-pass-fix-v4bx-to-ld.patch
new file mode 100644
index 0000000..d855fa5
--- /dev/null
+++ b/patches/gcc-4.7.2/0501-arm-eabi-pass-fix-v4bx-to-ld.patch
@@ -0,0 +1,49 @@
+From: =?UTF-8?q?Andreas=20Bie=C3=9Fmann?= <andreas@biessmann.de>
+Date: Sat, 8 Jun 2013 16:35:23 +0200
+Subject: [PATCH] arm:eabi: pass --fix-v4bx to ld
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+From https://raw.github.com/openembedded/oe-core/master/meta/recipes-devtools/gcc/gcc-4.7/gcc-armv4-pass-fix-v4bx-to-ld.patch
+
+---8<---
+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
+
+Upstream-Status: Pending
+
+-Khem
+--->8---
+
+Signed-off-by: Andreas Bießmann <andreas@biessmann.de>
+---
+ gcc/config/arm/linux-eabi.h |    7 ++++++-
+ 1 file changed, 6 insertions(+), 1 deletion(-)
+
+diff --git a/gcc/config/arm/linux-eabi.h b/gcc/config/arm/linux-eabi.h
+index 80bd825..c04e60f 100644
+--- a/gcc/config/arm/linux-eabi.h
++++ b/gcc/config/arm/linux-eabi.h
+@@ -64,10 +64,15 @@
+ #undef  GLIBC_DYNAMIC_LINKER
+ #define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.3"
+ 
++/* 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|mcpu=fa526|mcpu=fa626:--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 BE8_LINK_SPEC						\
++#define LINK_SPEC BE8_LINK_SPEC TARGET_FIX_V4BX_SPEC			\
+   LINUX_OR_ANDROID_LD (LINUX_TARGET_LINK_SPEC,				\
+ 		       LINUX_TARGET_LINK_SPEC " " ANDROID_LINK_SPEC)
+ 
diff --git a/patches/gcc-4.7.2/series b/patches/gcc-4.7.2/series
index 7951514..5b3b453 100644
--- a/patches/gcc-4.7.2/series
+++ b/patches/gcc-4.7.2/series
@@ -19,6 +19,7 @@
 0400-add-support-for-arm-linux-eabi-triplets-useful-for-a.patch
 #tag:OpenEmbedded --start-number 500
 0500-Fix-Argument-list-too-long-error.patch
+0501-arm-eabi-pass-fix-v4bx-to-ld.patch
 #tag:Linaro --start-number 600
 0600-Backport-the-change-to-the-hard-float-loader-path.-C.patch
-# ea3731c90748fd21a473c04e08e5f9f3  - git-ptx-patches magic
+# 1dc326873cd1b3aab51b38c30b65c221  - git-ptx-patches magic
-- 
1.7.10.4


-- 
ptxdist mailing list
ptxdist@pengutronix.de

  reply	other threads:[~2013-07-06 17:00 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-06 17:00 [ptxdist] [OSELAS.Toolchain PATCH 0/2] Add armv4 toolchain without thumb Andreas Bießmann
2013-07-06 17:00 ` Andreas Bießmann [this message]
2013-07-06 17:00 ` [ptxdist] [OSELAS.Toolchain PATCH 2/2] add new arm-v4-linux-gnueabi toolchain Andreas Bießmann

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1373130028-17640-2-git-send-email-andreas@biessmann.de \
    --to=andreas@biessmann.de \
    --cc=ptxdist@pengutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox