2000-12-19 Kazu Hirata <kazu@hxi.com>

* sco5-core.c: Fix formatting.
	* section.c: Likewise.
	* sparclinux.c: Likewise.
	* sparclynx.c: Likewise.
	* sparcnetbsd.c: Likewise.
	* srec.c: Likewise.
	* stabs.c: Likewise.
	* stab-syms.c: Likewise.
	* sunos.c: Likewise.
	* syms.c: Likewise.
	* sysdep.h: Likewise.
This commit is contained in:
Kazu Hirata 2000-12-20 00:21:57 +00:00
parent e30839fee3
commit 7b82c249fa
12 changed files with 100 additions and 110 deletions

View file

@ -1,3 +1,17 @@
2000-12-19 Kazu Hirata <kazu@hxi.com>
* sco5-core.c: Fix formatting.
* section.c: Likewise.
* sparclinux.c: Likewise.
* sparclynx.c: Likewise.
* sparcnetbsd.c: Likewise.
* srec.c: Likewise.
* stabs.c: Likewise.
* stab-syms.c: Likewise.
* sunos.c: Likewise.
* syms.c: Likewise.
* sysdep.h: Likewise.
2000-12-18 Nick Clifton <nickc@redhat.com>
* coff-arm.c (EXTRA_S_FLAGS): Only define if not already

View file

@ -109,7 +109,7 @@ read_uarea(abfd, filepos)
}
/* Sanity check perhaps??? */
if (rawptr->u.u_dsize > 0x1000000) /* Remember, it's in pages... */
if (rawptr->u.u_dsize > 0x1000000) /* Remember, it's in pages... */
{
bfd_set_error (bfd_error_wrong_format);
return NULL;
@ -169,7 +169,6 @@ sco5_core_file_p (abfd)
return NULL;
}
if (coffsets.u_info == 1)
{
/* Old version, no section heads, read info from user struct */
@ -267,11 +266,10 @@ sco5_core_file_p (abfd)
pointed to by u_ar0 (by setting the vma of the start of
the section to -u_ar0). GDB uses this info to locate the
regs, using minor trickery to get around the
offset-or-absolute-addr problem. */
offset-or-absolute-addr problem. */
chead.cs_vaddr = 0 - (bfd_vma) u->u_ar0;
secname = ".reg";
flags = SEC_HAS_CONTENTS;
@ -371,9 +369,9 @@ sco5_core_file_matches_executable_p (core_bfd, exec_bfd)
/* If somebody calls any byte-swapping routines, shoot them. */
static void
swap_abort()
swap_abort ()
{
abort(); /* This way doesn't require any declaration for ANSI to fuck up */
abort (); /* This way doesn't require any declaration for ANSI to fuck up */
}
#define NO_GET ((bfd_vma (*) PARAMS (( const bfd_byte *))) swap_abort )
#define NO_PUT ((void (*) PARAMS ((bfd_vma, bfd_byte *))) swap_abort )

View file

@ -111,7 +111,6 @@ SUBSECTION
| size 0x103 |
| output_section --------|
SUBSECTION
Link orders
@ -133,7 +132,6 @@ SUBSECTION
*/
#include "bfd.h"
#include "sysdep.h"
#include "libbfd.h"
@ -642,7 +640,6 @@ bfd_get_section_by_name (abfd, name)
return NULL;
}
/*
FUNCTION
bfd_get_unique_section_name
@ -693,7 +690,6 @@ bfd_get_unique_section_name (abfd, templat, count)
return sname;
}
/*
FUNCTION
bfd_make_section_old_way
@ -719,7 +715,6 @@ DESCRIPTION
*/
asection *
bfd_make_section_old_way (abfd, name)
bfd *abfd;
@ -867,7 +862,6 @@ bfd_make_section (abfd, name)
return bfd_make_section_anyway (abfd, name);
}
/*
FUNCTION
bfd_set_section_flags
@ -911,14 +905,13 @@ bfd_set_section_flags (abfd, section, flags)
return true;
}
/*
FUNCTION
bfd_map_over_sections
SYNOPSIS
void bfd_map_over_sections(bfd *abfd,
void (*func)(bfd *abfd,
void (*func) (bfd *abfd,
asection *sect,
PTR obj),
PTR obj);
@ -937,7 +930,6 @@ DESCRIPTION
| for (p = abfd->sections; p != NULL; p = p->next)
| func(abfd, p, ...)
*/
/*VARARGS2*/
@ -957,7 +949,6 @@ bfd_map_over_sections (abfd, operation, user_storage)
abort ();
}
/*
FUNCTION
bfd_set_section_size
@ -982,7 +973,7 @@ bfd_set_section_size (abfd, ptr, val)
bfd_size_type val;
{
/* Once you've started writing to any section you cannot create or change
the size of any others. */
the size of any others. */
if (abfd->output_has_begun)
{
@ -1008,15 +999,12 @@ SYNOPSIS
file_ptr offset,
bfd_size_type count);
DESCRIPTION
Sets the contents of the section @var{section} in BFD
@var{abfd} to the data starting in memory at @var{data}. The
data is written to the output section starting at offset
@var{offset} for @var{count} octets.
Normally <<true>> is returned, else <<false>>. Possible error
returns are:
o <<bfd_error_no_contents>> -
@ -1027,7 +1015,6 @@ DESCRIPTION
This routine is front end to the back end function
<<_bfd_set_section_contents>>.
*/
#define bfd_get_section_size_now(abfd,sec) \
@ -1117,8 +1104,6 @@ DESCRIPTION
with zeroes. If no errors occur, <<true>> is returned, else
<<false>>.
*/
boolean
bfd_get_section_contents (abfd, section, location, offset, count)

View file

@ -95,7 +95,7 @@ sparclinux_write_object_contents (abfd)
#define IS_GOT_SYM(name) \
(strncmp (name, GOT_REF_PREFIX, sizeof GOT_REF_PREFIX - 1) == 0)
/* See if a symbol name is a reference to the procedure linkage table. */
/* See if a symbol name is a reference to the procedure linkage table. */
#ifndef PLT_REF_PREFIX
#define PLT_REF_PREFIX "__PLT_"
@ -478,7 +478,7 @@ linux_tally_symbols (h, data)
(h->root.root.root.string
+ sizeof PLT_REF_PREFIX - 1),
false, false, true);
/* h2 does not follow indirect symbols. */
/* h2 does not follow indirect symbols. */
h2 = linux_link_hash_lookup (linux_hash_table (info),
(h->root.root.root.string
+ sizeof PLT_REF_PREFIX - 1),
@ -535,7 +535,7 @@ linux_tally_symbols (h, data)
}
/* Quick and dirty way of stripping these symbols from the
symtab. */
symtab. */
if (bfd_is_abs_section (h->root.root.u.def.section))
h->root.written = true;
}
@ -560,7 +560,7 @@ bfd_sparclinux_size_dynamic_sections (output_bfd, info)
if (output_bfd->xvec != &MY(vec))
return true;
/* First find the fixups... */
/* First find the fixups... */
linux_link_hash_traverse (linux_hash_table (info),
linux_tally_symbols,
(PTR) info);

View file

@ -46,7 +46,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* This is needed to reject a NewsOS file, e.g. in
gdb/testsuite/gdb.t10/crossload.exp. <kingdon@cygnus.com>
I needed to add M_UNKNOWN to recognize a 68000 object, so this will
probably no longer reject a NewsOS object. <ian@cygnus.com>. */
probably no longer reject a NewsOS object. <ian@cygnus.com>. */
#define MACHTYPE_OK(mtype) ((mtype) == M_UNKNOWN \
|| (mtype) == M_68010 \
|| (mtype) == M_68020 \
@ -90,7 +90,7 @@ NAME(lynx,set_arch_mach) (abfd, machtype)
case M_UNKNOWN:
/* Some Sun3s make magic numbers without cpu types in them, so
we'll default to the 68000. */
we'll default to the 68000. */
arch = bfd_arch_m68k;
machine = bfd_mach_m68000;
break;
@ -137,7 +137,7 @@ NAME(lynx,set_arch_mach) (abfd, machtype)
}
#define SET_ARCH_MACH(ABFD, EXEC) \
NAME(lynx,set_arch_mach)(ABFD, N_MACHTYPE (EXEC)); \
NAME(lynx,set_arch_mach) (ABFD, N_MACHTYPE (EXEC)); \
choose_reloc_size(ABFD);
/* Determine the size of a relocation entry, based on the architecture */

View file

@ -21,7 +21,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define TARGET_IS_BIG_ENDIAN_P
/* SPARC chips use either 4K or 8K pages, but object files always
assume 8K page alignment so they will work on either one. */
assume 8K page alignment so they will work on either one. */
#define TARGET_PAGE_SIZE 0x2000
#define DEFAULT_ARCH bfd_arch_sparc

View file

@ -71,7 +71,6 @@ DESCRIPTION
is the sum of all the raw byte data in the record, from the length
upwards, modulo 256 and subtracted from 255.
SUBSECTION
Symbol S-Record handling

View file

@ -20,7 +20,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "bfd.h"
#define ARCH_SIZE 32 /* Value doesn't matter. */
#define ARCH_SIZE 32 /* Value doesn't matter. */
#include "libaout.h"
#include "aout/aout64.h"
@ -32,13 +32,13 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* These are not really stab symbols, but it is
convenient to have them here for the sake of nm.
For completeness, we could also add N_TEXT etc, but those
are never needed, since nm treats those specially. */
are never needed, since nm treats those specially. */
#define EXTRA_SYMBOLS \
__define_name (N_SETA, "SETA")/* Absolute set element symbol */ \
__define_name (N_SETT, "SETT")/* Text set element symbol */ \
__define_name (N_SETD, "SETD")/* Data set element symbol */ \
__define_name (N_SETB, "SETB")/* Bss set element symbol */ \
__define_name (N_SETV, "SETV")/* Pointer to set vector in data area. */ \
__define_name (N_SETV, "SETV")/* Pointer to set vector in data area. */ \
__define_name (N_INDR, "INDR") \
__define_name (N_WARNING, "WARNING")

View file

@ -108,7 +108,7 @@ struct stab_section_info
as the input offsets, because no stabs have been deleted from
this section. Otherwise the i'th entry is the number of
bytes of stabs that have been deleted prior to the i'th
stab. */
stab. */
bfd_size_type *cumulative_skips;
/* This is an array of string indices. For each stab symbol, we
@ -464,7 +464,7 @@ _bfd_link_section_stabs (abfd, psinfo, stabsec, stabstrsec, psecinfo)
sinfo->stabstr->_cooked_size = _bfd_stringtab_size (sinfo->strings);
/* Calculate the `cumulative_skips' array now that stabs have been
deleted for this section. */
deleted for this section. */
if (skip != 0)
{

View file

@ -2274,16 +2274,16 @@ sunos_write_dynamic_symbol (output_bfd, info, harg)
PUT_WORD (output_bfd, r_address, srel->r_address);
if (bfd_header_big_endian (output_bfd))
{
srel->r_index[0] = (bfd_byte)(h->dynindx >> 16);
srel->r_index[1] = (bfd_byte)(h->dynindx >> 8);
srel->r_index[2] = (bfd_byte)(h->dynindx);
srel->r_index[0] = (bfd_byte) (h->dynindx >> 16);
srel->r_index[1] = (bfd_byte) (h->dynindx >> 8);
srel->r_index[2] = (bfd_byte) (h->dynindx);
srel->r_type[0] = (RELOC_STD_BITS_EXTERN_BIG
| RELOC_STD_BITS_JMPTABLE_BIG);
}
else
{
srel->r_index[2] = (bfd_byte)(h->dynindx >> 16);
srel->r_index[1] = (bfd_byte)(h->dynindx >> 8);
srel->r_index[2] = (bfd_byte) (h->dynindx >> 16);
srel->r_index[1] = (bfd_byte) (h->dynindx >> 8);
srel->r_index[0] = (bfd_byte)h->dynindx;
srel->r_type[0] = (RELOC_STD_BITS_EXTERN_LITTLE
| RELOC_STD_BITS_JMPTABLE_LITTLE);
@ -2297,8 +2297,8 @@ sunos_write_dynamic_symbol (output_bfd, info, harg)
PUT_WORD (output_bfd, r_address, erel->r_address);
if (bfd_header_big_endian (output_bfd))
{
erel->r_index[0] = (bfd_byte)(h->dynindx >> 16);
erel->r_index[1] = (bfd_byte)(h->dynindx >> 8);
erel->r_index[0] = (bfd_byte) (h->dynindx >> 16);
erel->r_index[1] = (bfd_byte) (h->dynindx >> 8);
erel->r_index[2] = (bfd_byte)h->dynindx;
erel->r_type[0] =
(RELOC_EXT_BITS_EXTERN_BIG
@ -2306,8 +2306,8 @@ sunos_write_dynamic_symbol (output_bfd, info, harg)
}
else
{
erel->r_index[2] = (bfd_byte)(h->dynindx >> 16);
erel->r_index[1] = (bfd_byte)(h->dynindx >> 8);
erel->r_index[2] = (bfd_byte) (h->dynindx >> 16);
erel->r_index[1] = (bfd_byte) (h->dynindx >> 8);
erel->r_index[0] = (bfd_byte)h->dynindx;
erel->r_type[0] =
(RELOC_EXT_BITS_EXTERN_LITTLE
@ -2594,8 +2594,8 @@ sunos_check_dynamic_reloc (info, input_bfd, input_section, harg, reloc,
srel->r_address);
if (bfd_header_big_endian (dynobj))
{
srel->r_index[0] = (bfd_byte)(indx >> 16);
srel->r_index[1] = (bfd_byte)(indx >> 8);
srel->r_index[0] = (bfd_byte) (indx >> 16);
srel->r_index[1] = (bfd_byte) (indx >> 8);
srel->r_index[2] = (bfd_byte)indx;
if (h == NULL)
srel->r_type[0] = 2 << RELOC_STD_BITS_LENGTH_SH_BIG;
@ -2608,8 +2608,8 @@ sunos_check_dynamic_reloc (info, input_bfd, input_section, harg, reloc,
}
else
{
srel->r_index[2] = (bfd_byte)(indx >> 16);
srel->r_index[1] = (bfd_byte)(indx >> 8);
srel->r_index[2] = (bfd_byte) (indx >> 16);
srel->r_index[1] = (bfd_byte) (indx >> 8);
srel->r_index[0] = (bfd_byte)indx;
if (h == NULL)
srel->r_type[0] = 2 << RELOC_STD_BITS_LENGTH_SH_LITTLE;
@ -2633,8 +2633,8 @@ sunos_check_dynamic_reloc (info, input_bfd, input_section, harg, reloc,
erel->r_address);
if (bfd_header_big_endian (dynobj))
{
erel->r_index[0] = (bfd_byte)(indx >> 16);
erel->r_index[1] = (bfd_byte)(indx >> 8);
erel->r_index[0] = (bfd_byte) (indx >> 16);
erel->r_index[1] = (bfd_byte) (indx >> 8);
erel->r_index[2] = (bfd_byte)indx;
if (h == NULL)
erel->r_type[0] =
@ -2646,8 +2646,8 @@ sunos_check_dynamic_reloc (info, input_bfd, input_section, harg, reloc,
}
else
{
erel->r_index[2] = (bfd_byte)(indx >> 16);
erel->r_index[1] = (bfd_byte)(indx >> 8);
erel->r_index[2] = (bfd_byte) (indx >> 16);
erel->r_index[1] = (bfd_byte) (indx >> 8);
erel->r_index[0] = (bfd_byte)indx;
if (h == NULL)
erel->r_type[0] =
@ -2726,14 +2726,14 @@ sunos_check_dynamic_reloc (info, input_bfd, input_section, harg, reloc,
srel->r_address);
if (bfd_header_big_endian (dynobj))
{
srel->r_index[0] = (bfd_byte)(indx >> 16);
srel->r_index[1] = (bfd_byte)(indx >> 8);
srel->r_index[0] = (bfd_byte) (indx >> 16);
srel->r_index[1] = (bfd_byte) (indx >> 8);
srel->r_index[2] = (bfd_byte)indx;
}
else
{
srel->r_index[2] = (bfd_byte)(indx >> 16);
srel->r_index[1] = (bfd_byte)(indx >> 8);
srel->r_index[2] = (bfd_byte) (indx >> 16);
srel->r_index[1] = (bfd_byte) (indx >> 8);
srel->r_index[0] = (bfd_byte)indx;
}
/* FIXME: We may have to change the addend for a PC relative
@ -2751,14 +2751,14 @@ sunos_check_dynamic_reloc (info, input_bfd, input_section, harg, reloc,
erel->r_address);
if (bfd_header_big_endian (dynobj))
{
erel->r_index[0] = (bfd_byte)(indx >> 16);
erel->r_index[1] = (bfd_byte)(indx >> 8);
erel->r_index[0] = (bfd_byte) (indx >> 16);
erel->r_index[1] = (bfd_byte) (indx >> 8);
erel->r_index[2] = (bfd_byte)indx;
}
else
{
erel->r_index[2] = (bfd_byte)(indx >> 16);
erel->r_index[1] = (bfd_byte)(indx >> 8);
erel->r_index[2] = (bfd_byte) (indx >> 16);
erel->r_index[1] = (bfd_byte) (indx >> 8);
erel->r_index[0] = (bfd_byte)indx;
}
if (pcrel && h != NULL)

View file

@ -91,7 +91,6 @@ SUBSECTION
All storage for the symbols themselves is in an objalloc
connected to the BFD; it is freed when the BFD is closed.
INODE
Writing Symbols, Mini Symbols, Reading Symbols, Symbols
SUBSECTION
@ -163,8 +162,6 @@ SUBSECTION
*/
/*
DOCDD
INODE
@ -390,14 +387,12 @@ DESCRIPTION
Return the actual number of symbol pointers, not
including the NULL.
.#define bfd_canonicalize_symtab(abfd, location) \
. BFD_SEND (abfd, _bfd_canonicalize_symtab,\
. (abfd, location))
*/
/*
FUNCTION
bfd_set_symtab
@ -474,7 +469,6 @@ bfd_print_symbol_vandf (arg, symbol)
: ((type & BSF_OBJECT) ? 'O' : ' '))));
}
/*
FUNCTION
bfd_make_empty_symbol
@ -1005,7 +999,7 @@ _bfd_stab_section_find_nearest_line (abfd, symbols, section, offset, pfound,
if (bfd_get_32 (abfd, stab + STRDXOFF) == 0)
continue;
/* if we did not see a function def, leave space for one. */
/* if we did not see a function def, leave space for one. */
if (saw_fun == 0)
++info->indextablesize;
@ -1064,7 +1058,7 @@ _bfd_stab_section_find_nearest_line (abfd, symbols, section, offset, pfound,
a NULL function name if there were no N_FUNs in a file.
Note that a N_SO without a file name is an EOF and
there could be 2 N_SO following it with the new filename
and directory. */
and directory. */
if (saw_fun == 0)
{
info->indextable[i].val = bfd_get_32 (abfd, last_stab + VALOFF);