ELF: Group PT_NOTE segments by section alignments
Alignments of SHT_NOTE sections can be 8 bytes for 64-bit ELF files. We
should put all adjacent SHT_NOTE sections with the same section alignment
into a single PT_NOTE segment even when the section alignment != 4 bytes.
Also check SHT_NOTE section type instead of section name.
PR ld/23658
* elf.c (get_program_header_size): Put all adjacent SHT_NOTE
sections with the same section alignment into a single PT_NOTE
segment. Check SHT_NOTE section type instead of section name.
(_bfd_elf_map_sections_to_segments): Likewise.