bfd: support section groups with preceding SHF_GROUP sections
GAS always places section groups (SHT_GROUP) before the rest of the
sections in the output file. However, other assemblers may place
section groups after the group members.
This patch fixes handlign such situations, and removes some duplicated
logic.
bfd/ChangeLog:
2017-06-06 Jose E. Marchesi <jose.marchesi@oracle.com>
* elf.c (setup_group): Make sure BFD sections are created for all
group sections in the input file when processing SHF_GROUP
sections.
(bfd_section_from_shdr): Avoid duplicating logic already
implemented in `setup_group'.