[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: ld spurious warning?
From: |
Alan Modra |
Subject: |
Re: ld spurious warning? |
Date: |
Mon, 13 Feb 2017 09:08:56 +1030 |
User-agent: |
Mutt/1.5.24 (2015-08-30) |
On Sun, Feb 12, 2017 at 02:08:30AM +0000, Peter Johnson wrote:
> https://coldplace.net/basm.o
How was this file made? It has an invalid symbol table.
[ 3] .symtab SYMTAB 0000000000000000 0001f0 0000a8 18
4 6 8
sh_info above says the first global symbol is at index 6.
Symbol table '.symtab' contains 7 entries:
Num: Value Size Type Bind Vis Ndx Name
0: 0000000000000000 0 NOTYPE LOCAL DEFAULT UND
1: 0000000000000000 0 FILE LOCAL DEFAULT ABS file.asm
2: 0000000000000000 0 SECTION LOCAL DEFAULT 1
3: 0000000000000000 0 SECTION LOCAL DEFAULT 2
4: 0000000000000000 0 NOTYPE LOCAL DEFAULT 1 message
5: 0000000000000000 0 NOTYPE GLOBAL DEFAULT 2 _start
6: 000000000000000a 0 NOTYPE LOCAL DEFAULT 2 bar
This shows a local after a global, which is invalid. The sh_info
value also means ld only starts considering symbols as global at index
6. So you have no global symbols as far as ld is concerned.
--
Alan Modra
Australia Development Lab, IBM