1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1.2 +++ b/patches/gcc/4.4.6/360-arm-bigendian.patch Fri Nov 18 16:22:52 2011 +0800
1.3 @@ -0,0 +1,32 @@
1.4 +By Lennert Buytenhek <buytenh@wantstofly.org>
1.5 +Adds support for arm*b-linux* big-endian ARM targets
1.6 +
1.7 +See http://gcc.gnu.org/PR16350
1.8 +
1.9 +diff -durN gcc-4.4.5.orig/gcc/config/arm/linux-elf.h gcc-4.4.5/gcc/config/arm/linux-elf.h
1.10 +--- gcc-4.4.5.orig/gcc/config/arm/linux-elf.h 2009-02-20 16:20:38.000000000 +0100
1.11 ++++ gcc-4.4.5/gcc/config/arm/linux-elf.h 2010-10-09 23:13:21.000000000 +0200
1.12 +@@ -51,7 +51,7 @@
1.13 +
1.14 + #undef MULTILIB_DEFAULTS
1.15 + #define MULTILIB_DEFAULTS \
1.16 +- { "marm", "mlittle-endian", "mhard-float", "mno-thumb-interwork" }
1.17 ++ { "marm", TARGET_ENDIAN_OPTION, "mhard-float", "mno-thumb-interwork" }
1.18 +
1.19 + /* Now we define the strings used to build the spec file. */
1.20 + #undef LIB_SPEC
1.21 +diff -durN gcc-4.4.5.orig/gcc/config.gcc gcc-4.4.5/gcc/config.gcc
1.22 +--- gcc-4.4.5.orig/gcc/config.gcc 2010-10-09 23:09:53.000000000 +0200
1.23 ++++ gcc-4.4.5/gcc/config.gcc 2010-10-09 23:13:21.000000000 +0200
1.24 +@@ -739,6 +739,11 @@
1.25 + tm_file="dbxelf.h elfos.h arm/unknown-elf.h arm/elf.h arm/linux-gas.h arm/uclinux-elf.h"
1.26 + tmake_file="arm/t-arm arm/t-arm-elf"
1.27 + case ${target} in
1.28 ++ arm*b-*)
1.29 ++ tm_defines="${tm_defines} TARGET_BIG_ENDIAN_DEFAULT=1"
1.30 ++ ;;
1.31 ++ esac
1.32 ++ case ${target} in
1.33 + arm*-*-uclinux*eabi)
1.34 + tm_file="$tm_file arm/bpabi.h arm/uclinux-eabi.h"
1.35 + tmake_file="$tmake_file arm/t-bpabi"