PowerPC64 DT_RELR local PLT

Similarly to the local GOT case.

	* elf64-ppc.c (ppc64_elf_size_dynamic_sections): Don't allocate
	space for PLT relocs against local syms when enable_dt_relr.
This commit is contained in:
Alan Modra
2022-01-19 13:28:04 +10:30
parent 8f22c9532b
commit edca615ac1

View File

@ -10356,7 +10356,8 @@ ppc64_elf_size_dynamic_sections (bfd *output_bfd,
s = htab->pltlocal;
ent->plt.offset = s->size;
s->size += LOCAL_PLT_ENTRY_SIZE (htab);
if (bfd_link_pic (info))
if (bfd_link_pic (info)
&& !(info->enable_dt_relr && !htab->opd_abi))
htab->relpltlocal->size += sizeof (Elf64_External_Rela);
}
}