On Sat, Aug 11, 2012 at 11:17:16AM +0200, Kurt Roeckx wrote:
I'm currently seeing this:
section [37] '.symtab': symbol 306: st_value out of bounds
*** failure in ../src/elflint --quiet --gnu-ld ../src/ld
section [37] '.symtab': symbol 311: st_value out of bounds
*** failure in ../src/elflint --quiet --gnu-ld ../libelf/libelf.so
FAIL: run-elflint-self.sh
Which seems to be this symbol:
306: 000000000062a2e0 0 OBJECT LOCAL DEFAULT 26 __TMC_END__
And this binutils bug:
http://sourceware.org/bugzilla/show_bug.cgi?id=13621
Is there something we can do to ignore this?
I hoped we could, but when binutils removes the section the symbol
will be put into a random other section. I don't know how we could
really detect that has happened. Too bad the fix for this bug was
reverted. It really should be fixed properly in binutils ld, so that
it tracks which sections have symbols, and if so keeps the section
around even when it looks empty. binutild gold doesn't have this issue.
For Fedora I am using this very lame "workaround" for now:
http://pkgs.fedoraproject.org/cgit/elfutils.git/commit/?id=1d2f5631a4d211...
Thinking about it again, maybe we should make some kind of --gnu-ld
exception for zero sized symbols? But I am afraid that catched too
much.
Cheers,
Mark