aboutsummaryrefslogtreecommitdiff
path: root/bfd/ecofflink.c
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>2009-09-25 19:13:27 +0000
committerNick Clifton <nickc@redhat.com>2009-09-25 19:13:27 +0000
commit21d799b5c48956e71980143cb33035262984ed67 (patch)
treedbc66291451a9c7a4eb814c731c2bb247bba23b5 /bfd/ecofflink.c
parentfa9efd0fbc3f388e06f8f893c168e8e612216230 (diff)
downloadgdb-21d799b5c48956e71980143cb33035262984ed67.zip
gdb-21d799b5c48956e71980143cb33035262984ed67.tar.gz
gdb-21d799b5c48956e71980143cb33035262984ed67.tar.bz2
Update soruces to make alpha, arc and arm targets compile cleanly
with -Wc++-compat: * config/tc-alpha.c: Add casts. (extended_bfd_reloc_code_real_type): New type. Used to avoid enumeration conversion warnings. (struct alpha_fixup, void assemble_insn, assemble_insn) (assemble_tokens): Use new type. * ecoff.c: Add casts. (mark_stabs): Use enumeration names. * config/obj-elf.c: Add cast * config/tc-arc.c: Add casts. * config/obj-aout.h (text_section,data_section,bss_section): Make extern. * config/obj-elf.c: Add cast. * config/tc-arm.c: Add casts. (X, TxCE, TxCE, TxC3, TxC3w, TxCM_, TxCM, TUE, TUF, CE, CL, cCE) (cCL, C3E, xCM_, nUF, nCE_tag): Change input format to avoid the need for keywords as arguments. * ecoff.c: Add casts. * ecofflink.c: Add casts. * elf64-alpha.c: Add casts. (struct alpha_elf_got_entry, struct alpha_elf_reloc_entry): Move to top level. (SKIP_HOWTO): Use enum name. * elf32-arm.c: Add casts. (elf32_arm_vxworks_bed): Update code to avoid multiple declarations. (struct map_stub): Move to top level. * arc-dis.c Fix casts. * arc-ext.c: Add casts. * arm-dis.c (enum opcode_sentinel_enum): Gave name to anonymous enum. * emultempl/armelf.em: Add casts.
Diffstat (limited to 'bfd/ecofflink.c')
-rw-r--r--bfd/ecofflink.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/bfd/ecofflink.c b/bfd/ecofflink.c
index 072c97a..25b67fa 100644
--- a/bfd/ecofflink.c
+++ b/bfd/ecofflink.c
@@ -1,6 +1,6 @@
/* Routines to link ECOFF debugging information.
Copyright 1993, 1994, 1995, 1996, 1997, 1999, 2000, 2001, 2002, 2003,
- 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
+ 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
Written by Ian Lance Taylor, Cygnus Support, <ian@cygnus.com>.
This file is part of BFD, the Binary File Descriptor library.
@@ -1084,8 +1084,8 @@ ecoff_add_string (ainfo, info, debug, fdr, string)
len = strlen (string);
if (info->relocatable)
{
- if (!add_memory_shuffle (ainfo, &ainfo->ss, &ainfo->ss_end, (PTR) string,
- len + 1))
+ if (!add_memory_shuffle (ainfo, &ainfo->ss, &ainfo->ss_end,
+ (bfd_byte *) string, len + 1))
return -1;
ret = symhdr->issMax;
symhdr->issMax += len + 1;
@@ -1207,7 +1207,7 @@ bfd_ecoff_debug_accumulate_other (handle, output_bfd, output_debug,
}
(*swap_sym_out) (output_bfd, &internal_sym, external_sym);
add_memory_shuffle (ainfo, &ainfo->sym, &ainfo->sym_end,
- external_sym,
+ (bfd_byte *) external_sym,
(unsigned long) output_swap->external_sym_size);
++fdr.csym;
++output_symhdr->isymMax;
@@ -1228,7 +1228,7 @@ bfd_ecoff_debug_accumulate_other (handle, output_bfd, output_debug,
}
(*output_swap->swap_fdr_out) (output_bfd, &fdr, external_fdr);
add_memory_shuffle (ainfo, &ainfo->fdr, &ainfo->fdr_end,
- external_fdr,
+ (bfd_byte *) external_fdr,
(unsigned long) output_swap->external_fdr_size);
++output_symhdr->ifdMax;
@@ -1338,8 +1338,8 @@ bfd_ecoff_debug_one_external (abfd, debug, swap, name, esym)
- (char *) debug->external_ext)
< (symhdr->iextMax + 1) * external_ext_size)
{
- char *external_ext = debug->external_ext;
- char *external_ext_end = debug->external_ext_end;
+ char *external_ext = (char *) debug->external_ext;
+ char *external_ext_end = (char *) debug->external_ext_end;
if (! ecoff_add_bytes ((char **) &external_ext,
(char **) &external_ext_end,
(symhdr->iextMax + 1) * (size_t) external_ext_size))
@@ -1503,7 +1503,7 @@ ecoff_write_symhdr (abfd, debug, swap, where)
SET (cbExtOffset, iextMax, swap->external_ext_size);
#undef SET
- buff = (PTR) bfd_malloc (swap->external_hdr_size);
+ buff = (char *) bfd_malloc (swap->external_hdr_size);
if (buff == NULL && swap->external_hdr_size != 0)
goto error_return;