This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Committed] S/390: Fix default arch_info flags


Hi,

currently the wrong default arch_info is chosen for s390x. Actually it
is a miracle that this didn't cause trouble earlier. I just noticed it
because gas rejected a symbol generated from gfortran as being too big
for s390x.

I've committed the attached patch after testing on s390 and s390x.

Bye,

-Andreas-

2012-07-27  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>

	* cpu-s390.c (bfd_s390_64_arch, bfd_s390_arch): Pick the default
	arch depending on the target size.

---
 bfd/cpu-s390.c |    8 ++++++++
 1 file changed, 8 insertions(+)

Index: binutils/bfd/cpu-s390.c
===================================================================
--- binutils.orig/bfd/cpu-s390.c
+++ binutils/bfd/cpu-s390.c
@@ -33,7 +33,11 @@ const bfd_arch_info_type bfd_s390_64_arc
     "s390",
     "s390:64-bit",
     3, /* section alignment power */
+#if BFD_DEFAULT_TARGET_SIZE == 64
     TRUE, /* the default */
+#else
+    FALSE, /* the default */
+#endif
     bfd_default_compatible,
     bfd_default_scan,
     bfd_arch_default_fill,
@@ -50,7 +54,11 @@ const bfd_arch_info_type bfd_s390_arch =
     "s390",
     "s390:31-bit",
     3, /* section alignment power */
+#if BFD_DEFAULT_TARGET_SIZE == 64
+    FALSE, /* the default */
+#else
     TRUE, /* the default */
+#endif
     bfd_default_compatible,
     bfd_default_scan,
     bfd_arch_default_fill,


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]