aboutsummaryrefslogtreecommitdiff
path: root/bfd
diff options
context:
space:
mode:
authorAnthony Green <green@redhat.com>2012-09-13 22:24:51 +0000
committerAnthony Green <green@redhat.com>2012-09-13 22:24:51 +0000
commite202fa84e706abb043aed457473a764c76672297 (patch)
tree972e3d625d10ce5271e031e2f293cba7b2d9d11c /bfd
parentb9516fa158d68eedaa9e2191e38e7a1acfcfee77 (diff)
downloadgdb-e202fa84e706abb043aed457473a764c76672297.zip
gdb-e202fa84e706abb043aed457473a764c76672297.tar.gz
gdb-e202fa84e706abb043aed457473a764c76672297.tar.bz2
Bi-endian patches for moxie
Diffstat (limited to 'bfd')
-rw-r--r--bfd/ChangeLog10
-rw-r--r--bfd/config.bfd3
-rwxr-xr-xbfd/configure3
-rw-r--r--bfd/configure.in3
-rw-r--r--bfd/elf32-moxie.c6
-rw-r--r--bfd/targets.c6
6 files changed, 24 insertions, 7 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index e33ab1a..9a0d510 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,3 +1,13 @@
+2012-09-13 Anthony Green <green@moxielogic.com>
+
+ * targets.c (bfd_elf32_bigmoxie_vec, bfd_elf32_littlemoxie_vec):
+ Define.
+ (bfd_elf32_moxie_vec): Remove.
+ * config.bfd, configure.in: Add bi-endian support for moxie.
+ * configure: Rebuilt.
+ * elf32-moxie.c (TARGET_LITTLE_NAME, TARGET_LITTLE_SYM): Define.
+ (TARGET_BIG_NAME, TARGET_BIG_SYM): Update for bi-endian support.
+
2012-09-12 Doug Kwan <dougkwan@google.com>
* elf64-ppc.c (ppc64_elf_relocate_section): Use pre-adjusted
diff --git a/bfd/config.bfd b/bfd/config.bfd
index 6025f26..218f1dd 100644
--- a/bfd/config.bfd
+++ b/bfd/config.bfd
@@ -419,7 +419,8 @@ case "${targ}" in
;;
moxie-*-elf | moxie-*-rtems | moxie-*-uclinux)
- targ_defvec=bfd_elf32_moxie_vec
+ targ_defvec=bfd_elf32_bigmoxie_vec
+ targ_selvecs=bfd_elf32_littlemoxie_vec
;;
h8300*-*-rtemscoff*)
diff --git a/bfd/configure b/bfd/configure
index a6f61c5..ea06949 100755
--- a/bfd/configure
+++ b/bfd/configure
@@ -15221,6 +15221,7 @@ do
bfd_elf32_bigmips_vec) tb="$tb elf32-mips.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf ecofflink.lo" ;;
bfd_elf32_bigmips_vxworks_vec)
tb="$tb elf32-mips.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf ecofflink.lo" ;;
+ bfd_elf32_bigmoxie_vec) tb="$tb elf32-moxie.lo elf32.lo $elf" ;;
bfd_elf32_cr16_vec) tb="$tb elf32-cr16.lo elf32.lo $elf" ;;
bfd_elf32_cr16c_vec) tb="$tb elf32-cr16c.lo elf32.lo $elf" ;;
bfd_elf32_cris_vec) tb="$tb elf32-cris.lo elf32.lo $elf" ;;
@@ -15232,7 +15233,6 @@ do
bfd_elf32_fr30_vec) tb="$tb elf32-fr30.lo elf32.lo $elf" ;;
bfd_elf32_frv_vec) tb="$tb elf32-frv.lo elf32.lo $elf" ;;
bfd_elf32_frvfdpic_vec) tb="$tb elf32-frv.lo elf32.lo $elf" ;;
- bfd_elf32_moxie_vec) tb="$tb elf32-moxie.lo elf32.lo $elf" ;;
bfd_elf32_h8300_vec) tb="$tb elf32-h8300.lo elf32.lo $elf" ;;
bfd_elf32_hppa_linux_vec) tb="$tb elf32-hppa.lo elf32.lo $elf" ;;
bfd_elf32_hppa_nbsd_vec) tb="$tb elf32-hppa.lo elf32.lo $elf" ;;
@@ -15263,6 +15263,7 @@ do
bfd_elf32_littlemips_vec) tb="$tb elf32-mips.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf ecofflink.lo" ;;
bfd_elf32_littlemips_vxworks_vec)
tb="$tb elf32-mips.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf ecofflink.lo" ;;
+ bfd_elf32_littlemoxie_vec) tb="$tb elf32-moxie.lo elf32.lo $elf" ;;
bfd_elf32_m32c_vec) tb="$tb elf32-m32c.lo elf32.lo $elf" ;;
bfd_elf32_m32r_vec) tb="$tb elf32-m32r.lo elf32.lo $elf" ;;
bfd_elf32_m32rle_vec) tb="$tb elf32-m32r.lo elf32.lo $elf" ;;
diff --git a/bfd/configure.in b/bfd/configure.in
index 3626173..612d032 100644
--- a/bfd/configure.in
+++ b/bfd/configure.in
@@ -704,6 +704,7 @@ do
bfd_elf32_bigmips_vec) tb="$tb elf32-mips.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf ecofflink.lo" ;;
bfd_elf32_bigmips_vxworks_vec)
tb="$tb elf32-mips.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf ecofflink.lo" ;;
+ bfd_elf32_bigmoxie_vec) tb="$tb elf32-moxie.lo elf32.lo $elf" ;;
bfd_elf32_cr16_vec) tb="$tb elf32-cr16.lo elf32.lo $elf" ;;
bfd_elf32_cr16c_vec) tb="$tb elf32-cr16c.lo elf32.lo $elf" ;;
bfd_elf32_cris_vec) tb="$tb elf32-cris.lo elf32.lo $elf" ;;
@@ -715,7 +716,6 @@ do
bfd_elf32_fr30_vec) tb="$tb elf32-fr30.lo elf32.lo $elf" ;;
bfd_elf32_frv_vec) tb="$tb elf32-frv.lo elf32.lo $elf" ;;
bfd_elf32_frvfdpic_vec) tb="$tb elf32-frv.lo elf32.lo $elf" ;;
- bfd_elf32_moxie_vec) tb="$tb elf32-moxie.lo elf32.lo $elf" ;;
bfd_elf32_h8300_vec) tb="$tb elf32-h8300.lo elf32.lo $elf" ;;
bfd_elf32_hppa_linux_vec) tb="$tb elf32-hppa.lo elf32.lo $elf" ;;
bfd_elf32_hppa_nbsd_vec) tb="$tb elf32-hppa.lo elf32.lo $elf" ;;
@@ -746,6 +746,7 @@ do
bfd_elf32_littlemips_vec) tb="$tb elf32-mips.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf ecofflink.lo" ;;
bfd_elf32_littlemips_vxworks_vec)
tb="$tb elf32-mips.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf ecofflink.lo" ;;
+ bfd_elf32_littlemoxie_vec) tb="$tb elf32-moxie.lo elf32.lo $elf" ;;
bfd_elf32_m32c_vec) tb="$tb elf32-m32c.lo elf32.lo $elf" ;;
bfd_elf32_m32r_vec) tb="$tb elf32-m32r.lo elf32.lo $elf" ;;
bfd_elf32_m32rle_vec) tb="$tb elf32-m32r.lo elf32.lo $elf" ;;
diff --git a/bfd/elf32-moxie.c b/bfd/elf32-moxie.c
index c1a793e..9a031b4 100644
--- a/bfd/elf32-moxie.c
+++ b/bfd/elf32-moxie.c
@@ -366,8 +366,10 @@ moxie_elf_check_relocs (bfd *abfd,
#define ELF_MACHINE_CODE EM_MOXIE
#define ELF_MAXPAGESIZE 0x1
-#define TARGET_BIG_SYM bfd_elf32_moxie_vec
-#define TARGET_BIG_NAME "elf32-moxie"
+#define TARGET_BIG_SYM bfd_elf32_bigmoxie_vec
+#define TARGET_BIG_NAME "elf32-bigmoxie"
+#define TARGET_LITTLE_SYM bfd_elf32_littlemoxie_vec
+#define TARGET_LITTLE_NAME "elf32-littlemoxie"
#define elf_info_to_howto_rel NULL
#define elf_info_to_howto moxie_info_to_howto_rela
diff --git a/bfd/targets.c b/bfd/targets.c
index fa206d2..621bf8d 100644
--- a/bfd/targets.c
+++ b/bfd/targets.c
@@ -606,6 +606,7 @@ extern const bfd_target bfd_elf32_bigarm_symbian_vec;
extern const bfd_target bfd_elf32_bigarm_vxworks_vec;
extern const bfd_target bfd_elf32_bigmips_vec;
extern const bfd_target bfd_elf32_bigmips_vxworks_vec;
+extern const bfd_target bfd_elf32_bigmoxie_vec;
extern const bfd_target bfd_elf32_cr16_vec;
extern const bfd_target bfd_elf32_cr16c_vec;
extern const bfd_target bfd_elf32_cris_vec;
@@ -617,7 +618,6 @@ extern const bfd_target bfd_elf32_epiphany_vec;
extern const bfd_target bfd_elf32_fr30_vec;
extern const bfd_target bfd_elf32_frv_vec;
extern const bfd_target bfd_elf32_frvfdpic_vec;
-extern const bfd_target bfd_elf32_moxie_vec;
extern const bfd_target bfd_elf32_h8300_vec;
extern const bfd_target bfd_elf32_hppa_linux_vec;
extern const bfd_target bfd_elf32_hppa_nbsd_vec;
@@ -645,6 +645,7 @@ extern const bfd_target bfd_elf32_littlearm_symbian_vec;
extern const bfd_target bfd_elf32_littlearm_vxworks_vec;
extern const bfd_target bfd_elf32_littlemips_vec;
extern const bfd_target bfd_elf32_littlemips_vxworks_vec;
+extern const bfd_target bfd_elf32_littlemoxie_vec;
extern const bfd_target bfd_elf32_m32c_vec;
extern const bfd_target bfd_elf32_m32r_vec;
extern const bfd_target bfd_elf32_m32rle_vec;
@@ -979,6 +980,7 @@ static const bfd_target * const _bfd_target_vector[] =
&bfd_elf32_bigarm_vxworks_vec,
&bfd_elf32_bigmips_vec,
&bfd_elf32_bigmips_vxworks_vec,
+ &bfd_elf32_bigmoxie_vec,
&bfd_elf32_cr16_vec,
&bfd_elf32_cr16c_vec,
&bfd_elf32_cris_vec,
@@ -990,7 +992,6 @@ static const bfd_target * const _bfd_target_vector[] =
&bfd_elf32_fr30_vec,
&bfd_elf32_frv_vec,
&bfd_elf32_frvfdpic_vec,
- &bfd_elf32_moxie_vec,
&bfd_elf32_h8300_vec,
&bfd_elf32_hppa_linux_vec,
&bfd_elf32_hppa_nbsd_vec,
@@ -1020,6 +1021,7 @@ static const bfd_target * const _bfd_target_vector[] =
&bfd_elf32_littlearm_vxworks_vec,
&bfd_elf32_littlemips_vec,
&bfd_elf32_littlemips_vxworks_vec,
+ &bfd_elf32_littlemoxie_vec,
&bfd_elf32_m32c_vec,
&bfd_elf32_m32r_vec,
&bfd_elf32_m32rle_vec,