This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
PATCH: Enable 64bit emulation if available
- From: "H. J. Lu" <hjl at lucon dot org>
- To: binutils at sources dot redhat dot com
- Date: Fri, 9 Feb 2007 09:29:39 -0800
- Subject: PATCH: Enable 64bit emulation if available
want64 check in ld/configure.tgt may be done before it is set. As the
result, 64bit emulation may be left out by ld. This patch moves
want64 check to ld/configure.in.
H.J.
----
2007-02-09 H.J. Lu <hongjiu.lu@intel.com>
* configure.in (targ_extra_emuls): Add $targ64_extra_emuls if
want64 is true.
(targ_extra_libpath): Add $targ64_extra_libpath if want64 is
true
* configure: Regenerated.
* configure.tgt (i[3-7]86-*-linux-*): Set targ64_extra_emuls
and targ64_extra_libpath.
(powerpc*-*-linux*): Likewise.
(s390-*-linux*): Likewise.
--- ld/configure.in.wrap 2006-12-13 06:07:44.000000000 -0800
+++ ld/configure.in 2007-02-04 16:46:07.000000000 -0800
@@ -175,6 +175,11 @@ do
. ${srcdir}/../bfd/config.bfd
fi
+ if test x${want64} = xtrue; then
+ targ_extra_emuls="$targ_extra_emuls $targ64_extra_emuls"
+ targ_extra_libpath="$targ_extra_libpath $targ64_extra_libpath"
+ fi
+
for i in $targ_emul $targ_extra_emuls $targ_extra_libpath; do
case " $all_emuls " in
*" e${i}.o "*) ;;
--- ld/configure.tgt.wrap 2007-01-08 09:28:56.000000000 -0800
+++ ld/configure.tgt 2007-02-04 16:46:07.000000000 -0800
@@ -167,10 +167,8 @@ i[3-7]86-*-linux*aout*) targ_emul=i386li
i[3-7]86-*-linux*oldld) targ_emul=i386linux; targ_extra_emuls=elf_i386 ;;
i[3-7]86-*-linux-*) targ_emul=elf_i386
targ_extra_emuls=i386linux
- if test x${want64} = xtrue; then
- targ_extra_emuls="$targ_extra_emuls elf_x86_64"
- targ_extra_libpath=elf_x86_64
- fi
+ targ64_extra_emuls="$targ_extra_emuls elf_x86_64"
+ targ64_extra_libpath=elf_x86_64
tdir_i386linux=${targ_alias}aout ;;
x86_64-*-linux-*) targ_emul=elf_x86_64
targ_extra_emuls="elf_i386 i386linux"
@@ -411,10 +409,9 @@ powerpc*-*-linux*) case "${targ}" in
*) targ_emul=elf32ppclinux
targ_extra_emuls="elf32ppc elf32ppcsim"
targ_extra_libpath=elf32ppc
- if test "${want64}" = "true"; then
- targ_extra_emuls="$targ_extra_emuls elf64ppc"
- targ_extra_libpath="$targ_extra_libpath elf64ppc"
- fi ;;
+ targ64_extra_emuls="$targ_extra_emuls elf64ppc"
+ targ64_extra_libpath="$targ_extra_libpath elf64ppc"
+ ;;
esac ;;
powerpc*le-*-elf* | powerpc*le-*-eabi* | powerpc*le-*-solaris* \
| powerpc*le-*-sysv* | powerpc*le-*-vxworks*)
@@ -465,11 +462,9 @@ s390x-*-linux*) targ_emul=elf64_
s390x-*-tpf*) targ_emul=elf64_s390
tdir_elf_s390=`echo ${targ_alias} | sed -e 's/s390x/s390/'` ;;
s390-*-linux*) targ_emul=elf_s390
- if test "${want64}" = "true"; then
- targ_extra_emuls=elf64_s390
- targ_extra_libpath=$targ_extra_emuls
- tdir_elf64_s390=`echo ${targ_alias} | sed -e 's/s390/s390x/'`
- fi
+ targ64_extra_emuls=elf64_s390
+ targ64_extra_libpath=$targ_extra_emuls
+ tdir_elf64_s390=`echo ${targ_alias} | sed -e 's/s390/s390x/'`
;;
score-*-elf) targ_emul=scoreelf ;;
sh-*-linux*) targ_emul=shlelf_linux
--- ld/configure.wrap 2006-12-13 06:07:44.000000000 -0800
+++ ld/configure 2007-02-04 16:46:48.000000000 -0800
@@ -7453,6 +7453,11 @@ do
. ${srcdir}/../bfd/config.bfd
fi
+ if test x${want64} = xtrue; then
+ targ_extra_emuls="$targ_extra_emuls $targ64_extra_emuls"
+ targ_extra_libpath="$targ_extra_libpath $targ64_extra_libpath"
+ fi
+
for i in $targ_emul $targ_extra_emuls $targ_extra_libpath; do
case " $all_emuls " in
*" e${i}.o "*) ;;