mirror of
https://frontier.innolan.net/github/amigaos-binutils.git
synced 2025-11-24 01:52:47 +00:00
* libamiga.h (amiga_symbol_type): Add new member.
* amigaos.c (amiga_slurp_symbol_table): Remember reference count for HUNK_EXT entries when applicable. (amiga_print_symbol): Replace a.out style information with more relevant amiga specific data.
This commit is contained in:
@ -2368,6 +2368,7 @@ amiga_slurp_symbol_table (abfd)
|
|||||||
/* skip refs */
|
/* skip refs */
|
||||||
if (!get_long (abfd, &l) || bfd_seek (abfd, l<<2, SEEK_CUR))
|
if (!get_long (abfd, &l) || bfd_seek (abfd, l<<2, SEEK_CUR))
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
asp->refnum = l;
|
||||||
break;
|
break;
|
||||||
case EXT_ABS: /* Absolute */
|
case EXT_ABS: /* Absolute */
|
||||||
asp->symbol.section = bfd_abs_section_ptr;
|
asp->symbol.section = bfd_abs_section_ptr;
|
||||||
@ -2391,6 +2392,7 @@ amiga_slurp_symbol_table (abfd)
|
|||||||
/* skip refs */
|
/* skip refs */
|
||||||
if (!get_long (abfd, &l) || bfd_seek (abfd, l<<2, SEEK_CUR))
|
if (!get_long (abfd, &l) || bfd_seek (abfd, l<<2, SEEK_CUR))
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
asp->refnum = l;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -2468,9 +2470,8 @@ amiga_print_symbol (abfd, afile, symbol, how)
|
|||||||
fprintf (file, "%s", symbol->name);
|
fprintf (file, "%s", symbol->name);
|
||||||
break;
|
break;
|
||||||
case bfd_print_symbol_more:
|
case bfd_print_symbol_more:
|
||||||
fprintf (file, "%4x %2x %2x",
|
fprintf (file, "%4lx %2x",
|
||||||
(unsigned int)(amiga_symbol(symbol)->hunk_number&0xffff),
|
amiga_symbol(symbol)->refnum,
|
||||||
(unsigned int)0,/* ->other */
|
|
||||||
(unsigned int)amiga_symbol(symbol)->type);
|
(unsigned int)amiga_symbol(symbol)->type);
|
||||||
break;
|
break;
|
||||||
case bfd_print_symbol_all:
|
case bfd_print_symbol_all:
|
||||||
@ -2481,10 +2482,9 @@ amiga_print_symbol (abfd, afile, symbol, how)
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
bfd_print_symbol_vandf (abfd, (PTR)file, symbol);
|
bfd_print_symbol_vandf (abfd, (PTR)file, symbol);
|
||||||
fprintf (file, " %-10s %04x %02x %02x %s",
|
fprintf (file, " %-10s %04lx %02x %s",
|
||||||
symbol->section->name,
|
symbol->section->name,
|
||||||
(unsigned int)(amiga_symbol(symbol)->hunk_number&0xffff),
|
amiga_symbol(symbol)->refnum,
|
||||||
(unsigned int)0,/* ->other */
|
|
||||||
(unsigned int)amiga_symbol(symbol)->type,
|
(unsigned int)amiga_symbol(symbol)->type,
|
||||||
symbol->name);
|
symbol->name);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -113,6 +113,7 @@ typedef struct amiga_symbol {
|
|||||||
unsigned char type;
|
unsigned char type;
|
||||||
/* amiga data */
|
/* amiga data */
|
||||||
long index,hunk_number;
|
long index,hunk_number;
|
||||||
|
unsigned long refnum;
|
||||||
} amiga_symbol_type;
|
} amiga_symbol_type;
|
||||||
|
|
||||||
/* We take the address of the first element of an asymbol to ensure that the
|
/* We take the address of the first element of an asymbol to ensure that the
|
||||||
|
|||||||
Reference in New Issue
Block a user