* [PATCH] [Gold,MIPS] Detect 64-bit MIPS targets
@ 2016-08-08 23:21 Aurelien Jarno
0 siblings, 0 replies; only message in thread
From: Aurelien Jarno @ 2016-08-08 23:21 UTC (permalink / raw)
To: binutils; +Cc: Aurelien Jarno
When building gold targetting mips64el-linux-gnu or mips64-linux-gnu,
the configure script does not set HAVE_TARGET_64_LITTLE or
HAVE_TARGET_64_BIG. This causes the link of gold to fail:
mips.o: In function `(anonymous namespace)::Target_mips<64, true>::set_gp(gold::Layout*, gold::Symbol_table*) [clone .isra.1854]':
/home/aurel32/git/binutils-gdb/gold/mips.cc:8377: undefined reference to `gold::Sized_symbol<64>::init_output_data(char const*, char const*, gold::Output_data*, unsigned long, unsigned long, elfcpp::STT, elfcpp::STB, elfcpp::STV, unsigned char, bool, bool)'
mips.o: In function `gold::Merged_symbol_value<64>::value(gold::Relobj const*, unsigned int, unsigned long) const':
/home/aurel32/git/binutils-gdb/gold/object.h:1649: undefined reference to `gold::Merged_symbol_value<64>::value_from_output_section(gold::Relobj const*, unsigned int, unsigned long) const'
/home/aurel32/git/binutils-gdb/gold/object.h:1649: undefined reference to `gold::Merged_symbol_value<64>::value_from_output_section(gold::Relobj const*, unsigned int, unsigned long) const'
...
Fix that by adding mips64el and mips64 entry in gold/configure.tgt
gold/Changelog:
* configure.tgt: Add mips64el*-*-*|mips64le*-*-* and mips64*-*-*.
---
gold/ChangeLog | 4 ++++
gold/configure.tgt | 14 ++++++++++++++
2 files changed, 18 insertions(+)
diff --git a/gold/ChangeLog b/gold/ChangeLog
index 239df36..9bfbaab 100644
--- a/gold/ChangeLog
+++ b/gold/ChangeLog
@@ -1,3 +1,7 @@
+2016-08-09 Aurelien Jarno <aurelien@aurel32.net>
+
+ * configure.tgt: Add mips64el*-*-*|mips64le*-*-* and mips64*-*-*.
+
2016-06-29 Cary Coutant <ccoutant@gmail.com>
gold/
diff --git a/gold/configure.tgt b/gold/configure.tgt
index f1fd132..ac3d847 100644
--- a/gold/configure.tgt
+++ b/gold/configure.tgt
@@ -153,6 +153,13 @@ aarch64*-*)
targ_big_endian=false
targ_extra_big_endian=true
;;
+mips64el*-*-*|mips64le*-*-*)
+ targ_obj=mips
+ targ_machine=EM_MIPS_RS3_LE
+ targ_size=64
+ targ_big_endian=false
+ targ_extra_big_endian=true
+ ;;
mips*el*-*-*|mips*le*-*-*)
targ_obj=mips
targ_machine=EM_MIPS_RS3_LE
@@ -160,6 +167,13 @@ mips*el*-*-*|mips*le*-*-*)
targ_big_endian=false
targ_extra_big_endian=true
;;
+mips64*-*-*)
+ targ_obj=mips
+ targ_machine=EM_MIPS
+ targ_size=64
+ targ_big_endian=true
+ targ_extra_big_endian=false
+ ;;
mips*-*-*)
targ_obj=mips
targ_machine=EM_MIPS
--
2.8.1
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2016-08-08 23:21 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-08-08 23:21 [PATCH] [Gold,MIPS] Detect 64-bit MIPS targets Aurelien Jarno
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).