The IRIX-specific extension of the PT_DYNAMIC segment is not needed
by the dynamic linker on OpenBSD/mips64. Disable it so that the .dynamic
section stays at the start of the PT_DYNAMIC segment even when .dynstr,
.dynsym or .hash precedes .dynamic in the ELF file. This enables
Binutils 2.17 tools, such as strip(1), rewrite executables and shared
libraries that have been produced by LLD.
OK kettenis@
m->p_flags_valid = 1;
}
}
- if (m != NULL
+ if (SGI_COMPAT (abfd)
+ && m != NULL
&& m->count == 1 && strcmp (m->sections[0]->name, ".dynamic") == 0)
{
static const char *sec_names[] =