+2017-10-23 Maciej W. Rozycki <macro@imgtec.com>
+
+ * elfn32-mips.c (mips_elf_n32_mkobject): New prototype and
+ function.
+ (bfd_elf32_mkobject): Use `mips_elf_n32_mkobject' rather than
+ `_bfd_mips_elf_mkobject'.
+
2017-10-22 Hans-Peter Nilsson <hp@axis.com>
PR gas/22304
(bfd *, Elf_Internal_Note *);
static irix_compat_t elf_n32_mips_irix_compat
(bfd *);
+static bfd_boolean mips_elf_n32_mkobject
+ (bfd *);
extern const bfd_target mips_elf32_n_be_vec;
extern const bfd_target mips_elf32_n_le_vec;
return ict_none;
}
\f
+/* Make an n32 MIPS object. We need to set the n32 ABI flag in
+ `e_flags' to tell the object apart from an o32 object. */
+
+static bfd_boolean
+mips_elf_n32_mkobject (bfd *abfd)
+{
+ bfd_boolean ret;
+
+ ret = _bfd_mips_elf_mkobject (abfd);
+ if (ret)
+ elf_elfheader (abfd)->e_flags |= EF_MIPS_ABI2;
+
+ return ret;
+}
+\f
/* ECOFF swapping routines. These are used when dealing with the
.mdebug section, which is in the ECOFF debugging format. */
static const struct ecoff_debug_swap mips_elf32_ecoff_debug_swap = {
#define bfd_elf32_bfd_set_private_flags _bfd_mips_elf_set_private_flags
#define bfd_elf32_bfd_print_private_bfd_data \
_bfd_mips_elf_print_private_bfd_data
-#define bfd_elf32_mkobject _bfd_mips_elf_mkobject
+#define bfd_elf32_mkobject mips_elf_n32_mkobject
/* Support for SGI-ish mips targets using n32 ABI. */
+2017-10-23 Maciej W. Rozycki <macro@imgtec.com>
+
+ * config/tc-mips.c (mips_elf_final_processing): Don't set
+ EF_MIPS_ABI2 in `e_flags'.
+
2017-10-22 Hans-Peter Nilsson <hp@axis.com>
PR gas/22304
else
elf_elfheader (stdoutput)->e_flags |= E_MIPS_ABI_EABI32;
}
- else if (mips_abi == N32_ABI)
- elf_elfheader (stdoutput)->e_flags |= EF_MIPS_ABI2;
- /* Nothing to do for N64_ABI. */
+ /* Nothing to do for N32_ABI or N64_ABI. */
if (mips_32bitmode)
elf_elfheader (stdoutput)->e_flags |= EF_MIPS_32BITMODE;