This is the mail archive of the mailing list for the binutils project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

ld fails to handle empty group sections

Hi Pierre,
Please ask questions like this on the mailing list.  Someone wrote
quite a good list of reasons why you should do this.  See:

On Fri, Jul 07, 2017 at 10:44:14AM +0200, Pierre Lebleu wrote:
> With the "trunk" version, I got this message :
> staging_dir/toolchain-mips_mips32_gcc-5.3.0_uClibc-
> /usr/localdisk/vant-f_5.02/openwrt/build_dir/target-mips_mips32_uClibc-
> SHT_GROUP section [index 110] has no SHF_GROUP sections
> The problem seems to be those *empty* GROUP sections :
> COMDAT group section [  110] `.group'
> [wm4.prealloc.h.7.3f44507fe709a4206e0a16687993bc55] contains 0 sections:
>    [Index]    Name

Right.  How is the ufsd.o file being generated?  Strictly speaking, I
don't think there is anything in the ELF gABI that precludes an emtpy
group, but such a construct is useless.  Rather than modifying the
linker to deal with them, I'd rather they weren't created in the first
place.  If the problem is some objcopy or ld -r linking stage that
removes sections, then it is probably better to remove empty groups at
that point rather than trying to deal with them later.

Alan Modra
Australia Development Lab, IBM

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]