/* BFD back-end for oasys objects.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2001,
- 2002, 2003 Free Software Foundation, Inc.
+ 2002, 2003, 2004 Free Software Foundation, Inc.
Written by Steve Chamberlain of Cygnus Support, <sac@cygnus.com>.
This file is part of BFD, the Binary File Descriptor library.
static bfd_boolean oasys_write_object_contents
PARAMS ((bfd *));
static bfd_boolean oasys_set_section_contents
- PARAMS ((bfd *, sec_ptr, void *, file_ptr, bfd_size_type));
+ PARAMS ((bfd *, sec_ptr, const void *, file_ptr, bfd_size_type));
static asymbol *oasys_make_empty_symbol
PARAMS ((bfd *));
static bfd *oasys_openr_next_archived_file
static int oasys_sizeof_headers
PARAMS ((bfd *, bfd_boolean));
-long oasys_get_symtab
+long oasys_canonicalize_symtab
PARAMS ((bfd *, asymbol **));
long oasys_canonicalize_reloc
PARAMS ((bfd *, sec_ptr, arelent **, asymbol **));
extern const bfd_target oasys_vec;
long
-oasys_get_symtab (abfd, location)
+oasys_canonicalize_symtab (abfd, location)
bfd *abfd;
asymbol **location;
{
/*
There isn't a magic number in an Oasys archive, so the best we
- can do to verify reasnableness is to make sure that the values in
+ can do to verify reasonableness is to make sure that the values in
the header are too weird
*/
BFD_FAIL ();
}
- s->_raw_size = H_GET_32 (abfd, record.section.value);
+ s->size = H_GET_32 (abfd, record.section.value);
s->vma = H_GET_32 (abfd, record.section.vma);
s->flags = 0;
had_usefull = TRUE;
if (! per->initialized)
{
- per->data = (bfd_byte *) bfd_zalloc (abfd, section->_raw_size);
+ per->data = (bfd_byte *) bfd_zalloc (abfd, section->size);
if (!per->data)
return FALSE;
per->reloc_tail_ptr
return FALSE;
}
out.relb = RELOCATION_TYPE_REL | s->target_index;
- H_PUT_32 (abfd, s->_cooked_size, out.value);
+ H_PUT_32 (abfd, s->size, out.value);
H_PUT_32 (abfd, s->vma, out.vma);
if (! oasys_write_record (abfd,
current_byte_index = 0;
processed_data.relb = s->target_index | RELOCATION_TYPE_REL;
- while (current_byte_index < s->_cooked_size)
+ while (current_byte_index < s->size)
{
/* Scan forwards by eight bytes or however much is left and see if
there are any relocations going on */
1 modification byte + 2 data = 8 bytes total). That's where
the magic number 8 comes from.
*/
- while (current_byte_index < s->_raw_size && dst <=
+ while (current_byte_index < s->size && dst <=
&processed_data.data[sizeof (processed_data.data) - 8])
{
oasys_set_section_contents (abfd, section, location, offset, count)
bfd *abfd;
sec_ptr section;
- PTR location;
+ const PTR location;
file_ptr offset;
bfd_size_type count;
{
if (oasys_per_section (section)->data == (bfd_byte *) NULL)
{
oasys_per_section (section)->data =
- (bfd_byte *) (bfd_alloc (abfd, section->_cooked_size));
+ (bfd_byte *) (bfd_alloc (abfd, section->size));
if (!oasys_per_section (section)->data)
return FALSE;
}
#define oasys_update_armap_timestamp bfd_true
#define oasys_bfd_is_local_label_name bfd_generic_is_local_label_name
+#define oasys_bfd_is_target_special_symbol ((bfd_boolean (*) (bfd *, asymbol *)) bfd_false)
#define oasys_get_lineno _bfd_nosymbols_get_lineno
#define oasys_bfd_make_debug_symbol _bfd_nosymbols_bfd_make_debug_symbol
#define oasys_read_minisymbols _bfd_generic_read_minisymbols
#define oasys_bfd_relax_section bfd_generic_relax_section
#define oasys_bfd_gc_sections bfd_generic_gc_sections
#define oasys_bfd_merge_sections bfd_generic_merge_sections
+#define oasys_bfd_is_group_section bfd_generic_is_group_section
#define oasys_bfd_discard_group bfd_generic_discard_group
+#define oasys_section_already_linked \
+ _bfd_generic_section_already_linked
#define oasys_bfd_link_hash_table_create _bfd_generic_link_hash_table_create
#define oasys_bfd_link_hash_table_free _bfd_generic_link_hash_table_free
#define oasys_bfd_link_add_symbols _bfd_generic_link_add_symbols