#include "stabsread.h"
#include "gdb-stabs.h"
#include "demangle.h"
+#include "language.h" /* Needed inside partial-stab.h */
+#include "complaints.h"
#include "aout/aout64.h"
#include "aout/stab_gnu.h" /* We always use GNU stabs, not native, now */
add_this_object_header_file (i);
return;
}
- complain (&repeated_header_complaint, (char *)symnum);
+ complain (&repeated_header_complaint, symnum);
complain (&repeated_header_name_complaint, name);
}
symbol table. Read them in first. */
hp_symbuf_end = hp_symbuf_idx = 0;
- bfd_seek (abfd, HP_SYMTAB_OFFSET (objfile), 0);
+ bfd_seek (abfd, HP_SYMTAB_OFFSET (objfile), L_SET);
for (hp_symnum = 0; hp_symnum < HP_SYMCOUNT (objfile); hp_symnum++)
{
objfile);
}
}
- bfd_seek (abfd, DBX_SYMTAB_OFFSET (objfile), 0);
+ bfd_seek (abfd, DBX_SYMTAB_OFFSET (objfile), L_SET);
#endif
for (symnum = 0; symnum < DBX_SYMCOUNT (objfile); symnum++)
#define SET_NAMESTRING()\
if (((unsigned)bufp->n_strx + file_string_table_offset) >= \
DBX_STRINGTAB_SIZE (objfile)) { \
- complain (&string_table_offset_complaint, (char *) symnum); \
+ complain (&string_table_offset_complaint, symnum); \
namestring = "foo"; \
} else \
namestring = bufp->n_strx + file_string_table_offset + \
However, there is no reason not to accept
the GCC_COMPILED_FLAG_SYMBOL anywhere. */
- processing_gcc_compilation = 0;
if (strcmp (namestring, GCC_COMPILED_FLAG_SYMBOL) == 0)
processing_gcc_compilation = 1;
else if (strcmp (namestring, GCC2_COMPILED_FLAG_SYMBOL) == 0)
static CORE_ADDR function_start_offset;
char *colon_pos;
+#ifndef BLOCK_ADDRESS_FUNCTION_RELATIVE
+ /* N_LBRAC, N_RBRAC and N_SLINE entries are not relative to the
+ function start address, so just use the text offset. */
+ function_start_offset = ANOFFSET (section_offsets, SECT_OFF_TEXT);
+#endif
+
/* Something is wrong if we see real data before
seeing a source file name. */
absolute, or relative to the N_SO, depending on
BLOCK_ADDRESS_ABSOLUTE. */
function_start_offset = valu;
-#else
- /* Default on ordinary systems */
- function_start_offset = ANOFFSET (section_offsets, SECT_OFF_TEXT);
#endif
within_function = 1;
}
/* Stack must be empty now. */
if (context_stack_depth != 0)
- complain (&lbrac_unmatched_complaint, (char *) symnum);
+ complain (&lbrac_unmatched_complaint, symnum);
new = push_context (0, valu);
new->name = define_symbol (valu, name, desc, type, objfile);
#ifndef SUN_FIXED_LBRAC_BUG
if (valu < last_pc_address) {
/* Patch current LBRAC pc value to match last handy pc value */
- complain (&lbrac_complaint, 0);
+ complain (&lbrac_complaint);
valu = last_pc_address;
}
#endif
new = pop_context();
if (desc != new->depth)
- complain (&lbrac_mismatch_complaint, (char *) symnum);
+ complain (&lbrac_mismatch_complaint, symnum);
/* Some compilers put the variable decls inside of an
LBRAC/RBRAC block. This macro should be nonzero if this
/* FIXME Muzzle a compiler bug that makes end < start. */
if (new->start_addr > valu)
{
- complain(&lbrac_rbrac_complaint, 0);
+ complain (&lbrac_rbrac_complaint);
new->start_addr = valu;
}
/* Make a block for the local symbols within. */
struct objfile *objfile;
struct section_offsets *section_offsets;
int mainline;
- unsigned int staboffset;
+ file_ptr staboffset;
unsigned int stabsize;
- unsigned int stabstroffset;
+ file_ptr stabstroffset;
unsigned int stabstrsize;
{
int val;