#include <sys/param.h>
#include <sys/file.h>
#include <sys/stat.h>
-#include <strings.h>
-
-/* Undo brain-damage in some <strings.h> that '#define index strchr'.
- Note that tm-mips.h includes coff/sym.h, which has a structure with a
- member named 'index'. */
-#undef index
#include "coff/mips.h" /* COFF-like aspects of ecoff files */
#include "coff/ecoff-ext.h" /* External forms of ecoff sym structures */
+#include "libbfd.h" /* FIXME Secret internal BFD stuff (bfd_read) */
#include "libaout.h" /* FIXME Secret internal BFD stuff for a.out */
#include "aout/aout64.h"
#include "aout/stab_gnu.h" /* STABS information */
CORE_ADDR addr;
int mainline;
{
- bfd *abfd = objfile -> obfd;
-
init_minimal_symbol_collection ();
make_cleanup (discard_minimal_symbols, 0);
xzalloc(size)
unsigned int size;
{
- PTR p = xmalloc(size);
+ PTR p = xmalloc (size);
- memset(p, 0, size);
- return p;
+ memset (p, 0, size);
+ return p;
}
/* Exported procedure: Builds a symtab from the PST partial one.
/* This function depends on the external and internal forms
of the MIPS symbol table taking identical space. Check this
assumption at compile-time. */
+#if 0 /* FIXME: Unused */
static check_hdr1[1 + sizeof (struct hdr_ext) - sizeof (HDRR)] = {0};
static check_hdr2[1 + sizeof (HDRR) - sizeof (struct hdr_ext)] = {0};
static check_fdr1[1 + sizeof (struct fdr_ext) - sizeof (FDR)] = {0};
static check_ext2[1 + sizeof (EXTR) - sizeof (struct ext_ext)] = {0};
static check_rfd1[1 + sizeof (struct rfd_ext) - sizeof (RFDT)] = {0};
static check_rfd2[1 + sizeof (RFDT) - sizeof (struct rfd_ext)] = {0};
+#endif
/* Swap in the header record. */
ecoff_swap_hdr_in (abfd, hdr, hdr);
/* Throw away undef entries when done with file index F_IDX */
/* FIXME -- storage leak. This is never called!!! --gnu */
+#if 0
+
static void
free_pending(f_idx)
int f_idx;
pending_list[f_idx] = 0;
}
+#endif
+
static char *
prepend_tag_kind(tag_name, type_code)
char *tag_name;
is the displacement from the procedure`s start
address of the end of this block. */
BLOCK_END(top_stack->cur_block) = sh->value + top_stack->procadr;
- (void) shrink_block(top_stack->cur_block, top_stack->cur_st);
+ shrink_block(top_stack->cur_block, top_stack->cur_st);
} else complain (&stEnd_complaint, (char *)sh->sc);
pop_parse_stack(); /* restore previous lexical context */
ax += cross_ref(ax, &tp, type_code, &pn, bigend);
/* reading .o file ? */
if (UNSAFE_DATA_ADDR(tp))
- tp = init_type(type_code, 0, 0, 0, (struct objfile *) NULL);
+ tp = init_type(type_code, 0, 0, (char *) NULL,
+ (struct objfile *) NULL);
/* SOMEONE OUGHT TO FIX DBXREAD TO DROP "STRUCT" */
sprintf(name, fmt, pn);
case tqArray:
off = 0;
- t = init_type(TYPE_CODE_ARRAY, 0, 0, 0, (struct objfile *) NULL);
+ t = init_type(TYPE_CODE_ARRAY, 0, 0, (char *) NULL,
+ (struct objfile *) NULL);
TYPE_TARGET_TYPE(t) = *tpp;
/* Determine and record the domain type (type of index) */
SYMR *sh = (SYMR*)pr->isym;
struct block *b;
struct mips_extra_func_info *e;
- char name[100];
char *sh_name;
/* Static procedure at address pr->adr. Sigh. */
* This symbol table contains stabs-in-ecoff entries.
*/
- SYMR *sh;
PDR *pr;
/* Parse local symbols first */
if (p)
*tpp = p->t;
else {
- *tpp = init_type(type_code, 0, 0, 0, (struct objfile *) NULL);
+ *tpp = init_type(type_code, 0, 0, (char *) NULL,
+ (struct objfile *) NULL);
add_pending(fh, sh, *tpp);
}
}
*/
SYMBOL_NAMESPACE(s) = VAR_NAMESPACE;
SYMBOL_CLASS(s) = LOC_BLOCK;
- SYMBOL_TYPE(s) = init_type(TYPE_CODE_FUNC, 4, 0, 0, (struct objfile *) NULL);
+ SYMBOL_TYPE(s) = init_type(TYPE_CODE_FUNC, 4, 0, (char *) NULL,
+ (struct objfile *) NULL);
TYPE_TARGET_TYPE(SYMBOL_TYPE(s)) = builtin_type_void;
/* Need a block to allocate .gdbinfo. in */