public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* PATCH: ld/1485: --enable-targets=all doesn't work for 64bit target
@ 2006-05-25  3:19 H. J. Lu
  2006-05-25  3:48 ` Alan Modra
  0 siblings, 1 reply; 8+ messages in thread
From: H. J. Lu @ 2006-05-25  3:19 UTC (permalink / raw)
  To: binutils

This patch checks 64bit bfd properly so that --enable-targets=all will
work for 64bit target and host.


H.J.
----
2006-05-24  H.J. Lu  <hongjiu.lu@intel.com>

	PR ld/1485
	* configure.in: Use ${srcdir}/../bfd/config.bfd to check 64bit
	bfd.  Support 64bit host for --enable-targets=all.
	* configure: Regenerated.

--- ld/configure.in.64	2006-04-14 14:44:46.000000000 -0700
+++ ld/configure.in	2006-05-24 10:16:18.000000000 -0700
@@ -169,6 +169,11 @@ do
       EMUL=$targ_emul
     fi
 
+    . ${srcdir}/../bfd/config.bfd
+    case "${targ_defvec}-${targ_selvecs}" in
+    *elf64*) want64=true;;
+    esac
+
     for i in $targ_emul $targ_extra_emuls $targ_extra_libpath; do
 	case " $all_emuls " in
 	*" e${i}.o "*) ;;
@@ -210,10 +215,13 @@ AC_SUBST(EMUL)
 TDIRS=tdirs
 AC_SUBST_FILE(TDIRS)
 
-dnl FIXME: We will build a 64 bit BFD for a 64 bit host or a 64 bit
-dnl target, and in those cases we should also build the 64 bit
-dnl emulations.
 if test x${all_targets} = xtrue; then
+  if test x${want64} = xfalse; then
+    AC_CHECK_SIZEOF(long)
+    if test "x${ac_cv_sizeof_long}" = "x8"; then
+      want64=true
+    fi
+  fi
   if test x${want64} = xtrue; then
     EMULATION_OFILES='$(ALL_EMULATIONS) $(ALL_64_EMULATIONS)'
   else

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

end of thread, other threads:[~2006-05-25  8:03 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-05-25  3:19 PATCH: ld/1485: --enable-targets=all doesn't work for 64bit target H. J. Lu
2006-05-25  3:48 ` Alan Modra
2006-05-25  4:20   ` H. J. Lu
2006-05-25  5:01     ` Alan Modra
2006-05-25  5:51       ` Should sh-*-* enable 64bit targets? H. J. Lu
2006-05-25  5:55         ` Alan Modra
2006-05-25 14:45           ` H. J. Lu
2006-05-25 14:56             ` Alan Modra

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).