Openembedded Core Discussions
 help / color / mirror / Atom feed
* [PATCH] gcc: Tweak arm multilib endian patch for baremetal
@ 2015-03-26 23:55 Richard Purdie
  2015-04-03  4:55 ` Khem Raj
  0 siblings, 1 reply; 2+ messages in thread
From: Richard Purdie @ 2015-03-26 23:55 UTC (permalink / raw)
  To: openembedded-core

In a baremetal build, TARGET_ENDIAN_OPTION isn't set leading to build
failures. Add in ifdefs to avoid this.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>

diff --git a/meta/recipes-devtools/gcc/gcc-4.9/0015-arm-Use-TARGET_ENDIAN_OPTION-for-determining-MULTILI.patch b/meta/recipes-devtools/gcc/gcc-4.9/0015-arm-Use-TARGET_ENDIAN_OPTION-for-determining-MULTILI.patch
index ba0a227..37c46fc 100644
--- a/meta/recipes-devtools/gcc/gcc-4.9/0015-arm-Use-TARGET_ENDIAN_OPTION-for-determining-MULTILI.patch
+++ b/meta/recipes-devtools/gcc/gcc-4.9/0015-arm-Use-TARGET_ENDIAN_OPTION-for-determining-MULTILI.patch
@@ -11,26 +11,34 @@ Upstream-Status: Pending
  gcc/config/arm/linux-elf.h |    2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
-Index: gcc-4.9-20140316/gcc/config/arm/coff.h
+Index: gcc-4.9.2/gcc/config/arm/coff.h
 ===================================================================
---- gcc-4.9-20140316.orig/gcc/config/arm/coff.h
-+++ gcc-4.9-20140316/gcc/config/arm/coff.h
-@@ -33,7 +33,7 @@
+--- gcc-4.9.2.orig/gcc/config/arm/coff.h
++++ gcc-4.9.2/gcc/config/arm/coff.h
+@@ -32,8 +32,11 @@
+ #define TARGET_DEFAULT (MASK_APCS_FRAME)
  
  #ifndef MULTILIB_DEFAULTS
++#ifndef TARGET_ENDIAN_OPTION
++#define TARGET_ENDIAN_OPTION "mlittle-endian"
++#endif
  #define MULTILIB_DEFAULTS \
 -  { "marm", "mlittle-endian", "mfloat-abi=soft", "mno-thumb-interwork" }
 +  { "marm", TARGET_ENDIAN_OPTION, "mfloat-abi=soft", "mno-thumb-interwork" }
  #endif
  \f
  /* This is COFF, but prefer stabs.  */
-Index: gcc-4.9-20140316/gcc/config/arm/elf.h
+Index: gcc-4.9.2/gcc/config/arm/elf.h
 ===================================================================
---- gcc-4.9-20140316.orig/gcc/config/arm/elf.h
-+++ gcc-4.9-20140316/gcc/config/arm/elf.h
-@@ -112,7 +112,7 @@
+--- gcc-4.9.2.orig/gcc/config/arm/elf.h
++++ gcc-4.9.2/gcc/config/arm/elf.h
+@@ -116,8 +116,11 @@
+ #endif
  
  #ifndef MULTILIB_DEFAULTS
++#ifndef TARGET_ENDIAN_OPTION
++#define TARGET_ENDIAN_OPTION "mlittle-endian"
++#endif
  #define MULTILIB_DEFAULTS \
 -  { "marm", "mlittle-endian", "mfloat-abi=soft", "mno-thumb-interwork", "fno-leading-underscore" }
 +  { "marm", TARGET_ENDIAN_OPTION, "mfloat-abi=soft", "mno-thumb-interwork", "fno-leading-underscore" }




^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2015-04-03  4:55 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-03-26 23:55 [PATCH] gcc: Tweak arm multilib endian patch for baremetal Richard Purdie
2015-04-03  4:55 ` Khem Raj

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox