+2008-07-30 Alan Modra <amodra@bigpond.net.au>
+
+ * coff-ppc.c, coffgen.c, ecoff.c, ecofflink.c, elf.c, elf32-frv.c,
+ elf32-iq2000.c, elf32-m32c.c, elf32-mep.c, elf32-mt.c,
+ elf32-sh-symbian.c, elf64-hppa.c, mach-o.c, peXXigen.c, pef.c,
+ ppcboot.c, vms-misc.c, xsym.c: Silence gcc warnings.
+
2008-07-28 Daniel Jacobowitz <dan@codesourcery.com>
* elfxx-mips.c (mips_elf_calculate_relocation): Avoid generating
/* BFD back-end for PowerPC Microsoft Portable Executable files.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
+ 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
Free Software Foundation, Inc.
Original version pieced together by Kim Knuttila (krk@cygnus.com)
{
fprintf (file,
_("**** global_toc_size %ld(%lx), thunk_size %ld(%lx)\n"),
- global_toc_size, global_toc_size,
- thunk_size, thunk_size);
+ global_toc_size, (unsigned long) global_toc_size,
+ thunk_size, (unsigned long) thunk_size);
cat = _("Out of bounds!");
}
}
/* Support for the generic parts of COFF, for BFD.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002, 2003, 2004, 2005, 2007
+ 2000, 2001, 2002, 2003, 2004, 2005, 2007, 2008
Free Software Foundation, Inc.
Written by Cygnus Support.
/* Probably a section symbol ? */
{
fprintf (file, "AUX scnlen 0x%lx nreloc %d nlnno %d",
- (long) auxp->u.auxent.x_scn.x_scnlen,
+ (unsigned long) auxp->u.auxent.x_scn.x_scnlen,
auxp->u.auxent.x_scn.x_nreloc,
auxp->u.auxent.x_scn.x_nlinno);
if (auxp->u.auxent.x_scn.x_checksum != 0
llnos = auxp->u.auxent.x_sym.x_fcnary.x_fcn.x_lnnoptr;
fprintf (file,
"AUX tagndx %ld ttlsiz 0x%lx lnnos %ld next %ld",
- tagndx, auxp->u.auxent.x_sym.x_misc.x_fsize,
+ tagndx,
+ (unsigned long) auxp->u.auxent.x_sym.x_misc.x_fsize,
llnos, next);
break;
}
sprintf (string,
"%s %s { ifd = %u, index = %lu }",
which, name, ifd,
- ((long) indx
+ ((unsigned long) indx
+ debug_info->symbolic_header.iextMax));
}
/* Routines to link ECOFF debugging information.
Copyright 1993, 1994, 1995, 1996, 1997, 1999, 2000, 2001, 2002, 2003,
- 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+ 2004, 2005, 2006, 2007, 2008 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.
lookup = (char *) bfd_malloc ((bfd_size_type) strlen (name) + 20);
if (lookup == NULL)
return FALSE;
- sprintf (lookup, "%s %lx %lx", name, fdr.csym, fdr.caux);
+ sprintf (lookup, "%s %lx %lx", name, (unsigned long) fdr.csym,
+ (unsigned long) fdr.caux);
fh = string_hash_lookup (&ainfo->fdr_hash, lookup, TRUE, TRUE);
free (lookup);
case bfd_print_symbol_more:
fprintf (file, "elf ");
bfd_fprintf_vma (abfd, file, symbol->value);
- fprintf (file, " %lx", (long) symbol->flags);
+ fprintf (file, " %lx", (unsigned long) symbol->flags);
break;
case bfd_print_symbol_all:
{
/* Make a ".module/xxxxxxxx" section. */
/* module_info.base_address */
base_addr = bfd_get_32 (abfd, note->descdata + 4);
- sprintf (buf, ".module/%08lx", (long) base_addr);
+ sprintf (buf, ".module/%08lx", (unsigned long) base_addr);
len = strlen (buf) + 1;
name = bfd_alloc (abfd, len);
/* FRV-specific support for 32-bit ELF.
- Copyright 2002, 2003, 2004, 2005, 2006, 2007
+ Copyright 2002, 2003, 2004, 2005, 2006, 2007, 2008
Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
_bfd_elf_print_private_bfd_data (abfd, ptr);
flags = elf_elfheader (abfd)->e_flags;
- fprintf (file, _("private flags = 0x%lx:"), (long)flags);
+ fprintf (file, _("private flags = 0x%lx:"), (unsigned long) flags);
switch (flags & EF_FRV_CPU_MASK)
{
/* IQ2000-specific support for 32-bit ELF.
- Copyright (C) 2003, 2004, 2005, 2006, 2007
+ Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008
Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
_bfd_elf_print_private_bfd_data (abfd, ptr);
flags = elf_elfheader (abfd)->e_flags;
- fprintf (file, _("private flags = 0x%lx:"), (long)flags);
+ fprintf (file, _("private flags = 0x%lx:"), (unsigned long) flags);
switch (flags & EF_IQ2000_CPU_MASK)
{
/* M16C/M32C specific support for 32-bit ELF.
- Copyright (C) 2005, 2006, 2007
+ Copyright (C) 2005, 2006, 2007, 2008
Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
_bfd_elf_print_private_bfd_data (abfd, ptr);
flags = elf_elfheader (abfd)->e_flags;
- fprintf (file, _("private flags = 0x%lx:"), (long)flags);
+ fprintf (file, _("private flags = 0x%lx:"), (unsigned long) flags);
switch (flags & EF_M32C_CPU_MASK)
{
/* MeP-specific support for 32-bit ELF.
- Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007
+ Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
_bfd_elf_print_private_bfd_data (abfd, ptr);
flags = elf_elfheader (abfd)->e_flags;
- fprintf (file, _("private flags = 0x%lx"), (long)flags);
+ fprintf (file, _("private flags = 0x%lx"), (unsigned long) flags);
partial_flags = (flags & EF_MEP_CPU_MASK) >> 24;
if (partial_flags < ARRAY_SIZE (core_names))
/* Morpho Technologies MT specific support for 32-bit ELF
- Copyright 2001, 2002, 2003, 2004, 2005, 2006, 2007
+ Copyright 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
_bfd_elf_print_private_bfd_data (abfd, ptr);
flags = elf_elfheader (abfd)->e_flags;
- fprintf (file, _("private flags = 0x%lx:"), (long)flags);
+ fprintf (file, _("private flags = 0x%lx:"), (unsigned long) flags);
switch (flags & EF_MT_CPU_MASK)
{
/* Renesas / SuperH specific support for Symbian 32-bit ELF files
- Copyright 2004, 2005, 2006, 2007
+ Copyright 2004, 2005, 2006, 2007, 2008
Free Software Foundation, Inc.
Contributed by Red Hat
BFD_ASSERT (ptr->new_symndx);
if (SYMBIAN_DEBUG)
fprintf (stderr, "convert reloc %lx from using index %ld to using index %ld\n",
- (long) rel->r_info, (long) ELF32_R_SYM (rel->r_info), ptr->new_symndx);
+ (unsigned long) rel->r_info,
+ (long) ELF32_R_SYM (rel->r_info), ptr->new_symndx);
rel->r_info = ELF32_R_INFO (ptr->new_symndx, r_type);
break;
}
{
nlen = sprintf (buf, "%x:%lx",
sec->id & 0xffffffff,
- (long) ELF64_R_SYM (rel->r_info));
+ (unsigned long) ELF64_R_SYM (rel->r_info));
if (rel->r_addend)
{
buf[nlen++] = '+';
/* BFD COFF object file private structure.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
+ 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
Free Software Foundation, Inc.
Written by Cygnus Support.
default:
fprintf (stderr,
"unable to write unknown load command 0x%lx\n",
- (long) cur->type);
+ (unsigned long) cur->type);
return FALSE;
}
}
|| header.byteorder == BFD_ENDIAN_LITTLE))
{
fprintf (stderr, "unknown header byte-order value 0x%lx\n",
- (long) header.byteorder);
+ (unsigned long) header.byteorder);
goto wrong;
}
|| header.byteorder == BFD_ENDIAN_LITTLE))
{
fprintf (stderr, "unknown header byte-order value 0x%lx\n",
- (long) header.byteorder);
+ (unsigned long) header.byteorder);
abort ();
}
&& first_thunk != 0
&& first_thunk != hint_addr)
fprintf (file, "\t%04lx",
- (long) bfd_get_32 (abfd, ft_data + ft_idx + j));
+ (unsigned long) bfd_get_32 (abfd, ft_data + ft_idx + j));
fprintf (file, "\n");
}
#else
&& first_thunk != 0
&& first_thunk != hint_addr)
fprintf (file, "\t%04lx",
- (long) bfd_get_32 (abfd, ft_data + ft_idx + j));
+ (unsigned long) bfd_get_32 (abfd, ft_data + ft_idx + j));
fprintf (file, "\n");
}
fprintf (file,
_("\nVirtual Address: %08lx Chunk size %ld (0x%lx) Number of fixups %ld\n"),
- (unsigned long) virtual_address, size, size, number);
+ (unsigned long) virtual_address, size, (unsigned long) size, number);
for (j = 0; j < number; ++j)
{
fprintf (file,
_("\treloc %4d offset %4x [%4lx] %s"),
- j, off, (long) (off + virtual_address), tbl[t]);
+ j, off, (unsigned long) (off + virtual_address), tbl[t]);
/* HIGHADJ takes an argument, - the next record *is* the
low 16 bits of addend. */
fprintf (file, "\t(%s)",name);
fprintf (file, "\nMajorLinkerVersion\t%d\n", i->MajorLinkerVersion);
fprintf (file, "MinorLinkerVersion\t%d\n", i->MinorLinkerVersion);
- fprintf (file, "SizeOfCode\t\t%08lx\n", i->SizeOfCode);
+ fprintf (file, "SizeOfCode\t\t%08lx\n", (unsigned long) i->SizeOfCode);
fprintf (file, "SizeOfInitializedData\t%08lx\n",
- i->SizeOfInitializedData);
+ (unsigned long) i->SizeOfInitializedData);
fprintf (file, "SizeOfUninitializedData\t%08lx\n",
- i->SizeOfUninitializedData);
+ (unsigned long) i->SizeOfUninitializedData);
fprintf (file, "AddressOfEntryPoint\t");
fprintf_vma (file, i->AddressOfEntryPoint);
fprintf (file, "\nBaseOfCode\t\t");
fprintf (file, "MinorImageVersion\t%d\n", i->MinorImageVersion);
fprintf (file, "MajorSubsystemVersion\t%d\n", i->MajorSubsystemVersion);
fprintf (file, "MinorSubsystemVersion\t%d\n", i->MinorSubsystemVersion);
- fprintf (file, "Win32Version\t\t%08lx\n", i->Reserved1);
- fprintf (file, "SizeOfImage\t\t%08lx\n", i->SizeOfImage);
- fprintf (file, "SizeOfHeaders\t\t%08lx\n", i->SizeOfHeaders);
- fprintf (file, "CheckSum\t\t%08lx\n", i->CheckSum);
+ fprintf (file, "Win32Version\t\t%08lx\n", (unsigned long) i->Reserved1);
+ fprintf (file, "SizeOfImage\t\t%08lx\n", (unsigned long) i->SizeOfImage);
+ fprintf (file, "SizeOfHeaders\t\t%08lx\n", (unsigned long) i->SizeOfHeaders);
+ fprintf (file, "CheckSum\t\t%08lx\n", (unsigned long) i->CheckSum);
switch (i->Subsystem)
{
fprintf_vma (file, i->SizeOfHeapReserve);
fprintf (file, "\nSizeOfHeapCommit\t");
fprintf_vma (file, i->SizeOfHeapCommit);
- fprintf (file, "\nLoaderFlags\t\t%08lx\n", i->LoaderFlags);
- fprintf (file, "NumberOfRvaAndSizes\t%08lx\n", i->NumberOfRvaAndSizes);
+ fprintf (file, "\nLoaderFlags\t\t%08lx\n", (unsigned long) i->LoaderFlags);
+ fprintf (file, "NumberOfRvaAndSizes\t%08lx\n",
+ (unsigned long) i->NumberOfRvaAndSizes);
fprintf (file, "\nThe Data Directory\n");
for (j = 0; j < IMAGE_NUMBEROF_DIRECTORY_ENTRIES; j++)
{
fprintf (file, "Entry %1x ", j);
fprintf_vma (file, i->DataDirectory[j].VirtualAddress);
- fprintf (file, " %08lx ", i->DataDirectory[j].Size);
+ fprintf (file, " %08lx ", (unsigned long) i->DataDirectory[j].Size);
fprintf (file, "%s\n", dir_names[j]);
}
/* PEF support for BFD.
- Copyright 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
+ Copyright 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
offset += 4;
if (file != NULL)
- fprintf (file, " [length = 0x%lx]", (long) offset);
+ fprintf (file, " [length = 0x%lx]", (unsigned long) offset);
return offset;
}
/* BFD back-end for PPCbug boot records.
Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2006,
- 2007 Free Software Foundation, Inc.
+ 2007, 2008 Free Software Foundation, Inc.
Written by Michael Meissner, Cygnus Support, <meissner@cygnus.com>
This file is part of BFD, the Binary File Descriptor library.
int i;
fprintf (f, _("\nppcboot header:\n"));
- fprintf (f, _("Entry offset = 0x%.8lx (%ld)\n"), entry_offset, entry_offset);
- fprintf (f, _("Length = 0x%.8lx (%ld)\n"), length, length);
+ fprintf (f, _("Entry offset = 0x%.8lx (%ld)\n"),
+ (unsigned long) entry_offset, entry_offset);
+ fprintf (f, _("Length = 0x%.8lx (%ld)\n"),
+ (unsigned long) length, length);
if (tdata->header.flags)
fprintf (f, _("Flag field = 0x%.2x\n"), tdata->header.flags);
tdata->header.partition[i].partition_end.sector,
tdata->header.partition[i].partition_end.cylinder);
- fprintf (f, _("Partition[%d] sector = 0x%.8lx (%ld)\n"), i, sector_begin, sector_begin);
- fprintf (f, _("Partition[%d] length = 0x%.8lx (%ld)\n"), i, sector_length, sector_length);
+ fprintf (f, _("Partition[%d] sector = 0x%.8lx (%ld)\n"),
+ i, (unsigned long) sector_begin, sector_begin);
+ fprintf (f, _("Partition[%d] length = 0x%.8lx (%ld)\n"),
+ i, (unsigned long) sector_length, sector_length);
}
fprintf (f, "\n");
char *
_bfd_vms_length_hash_symbol (bfd * abfd, const char *in, int maxlen)
{
- long int result;
+ unsigned long result;
int in_len;
char *new_name;
const char *old_name;
/* xSYM symbol-file support for BFD.
- Copyright 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
+ Copyright 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
bfd_sym_symbol_name (abfd, tinfo.nte_index)[0],
&bfd_sym_symbol_name (abfd, tinfo.nte_index)[1]);
}
- fprintf (f, " (TTE %lu)", value);
+ fprintf (f, " (TTE %lu)", (unsigned long) value);
break;
}
fprintf (f, "union (0x%x) of ", type);
bfd_sym_fetch_long (buf, len, offset, &offset, &nrec);
- fprintf (f, "%lu elements: ", nrec);
+ fprintf (f, "%lu elements: ", (unsigned long) nrec);
for (i = 0; i < nrec; i++)
{
bfd_sym_fetch_long (buf, len, offset, &offset, &eloff);
fprintf (f, "\n ");
- fprintf (f, "offset %lu: ", eloff);
+ fprintf (f, "offset %lu: ", (unsigned long) eloff);
bfd_sym_print_type_information (abfd, f, buf, len, offset, &offset);
}
break;
bfd_sym_symbol_name (abfd, value)[0],
&bfd_sym_symbol_name (abfd, value)[1]);
- fprintf (f, " (NTE %lu) with type ", value);
+ fprintf (f, " (NTE %lu) with type ", (unsigned long) value);
bfd_sym_print_type_information (abfd, f, buf, len, offset, &offset);
break;
}
+2008-07-30 Alan Modra <amodra@bigpond.net.au>
+
+ * dlltool.c, dwarf.c, objdump.c, readelf.c, resrc.c, resres.c,
+ windmc.c: Silence gcc warnings.
+
2008-07-28 Alan Modra <amodra@bigpond.net.au>
* readelf.c (print_vma): Typo fix.
for (i = 0; i < on_page; i++)
{
- long needed = need[i];
+ unsigned long needed = need[i];
if (needed)
needed = ((needed - page_addr) | 0x3000) & 0xffff;
{
fprintf (f, "\t.section .edata\n\n");
fprintf (f, "\t%s 0 %s Allways 0\n", ASM_LONG, ASM_C);
- fprintf (f, "\t%s 0x%lx %s Time and date\n", ASM_LONG, (long) time(0),
- ASM_C);
+ fprintf (f, "\t%s 0x%lx %s Time and date\n", ASM_LONG,
+ (unsigned long) time(0), ASM_C);
fprintf (f, "\t%s 0 %s Major and Minor version\n", ASM_LONG, ASM_C);
fprintf (f, "\t%sname%s %s Ptr to name of dll\n", ASM_RVA_BEFORE, ASM_RVA_AFTER, ASM_C);
fprintf (f, "\t%s %d %s Starting ordinal of exports\n", ASM_LONG, d_low_ord, ASM_C);
if (uvalue >= section->size)
warn (_("Offset %lx used as value for DW_AT_import attribute of DIE at offset %lx is too big.\n"),
- uvalue, (long int)(orig_data - section->start));
+ uvalue, (unsigned long) (orig_data - section->start));
else
{
unsigned long abbrev_number;
{
if (start < next)
warn (_("There is a hole [0x%lx - 0x%lx] in .debug_loc section.\n"),
- (long)(start - section_begin), (long)(next - section_begin));
+ (unsigned long) (start - section_begin),
+ (unsigned long) (next - section_begin));
else if (start > next)
warn (_("There is an overlap [0x%lx - 0x%lx] in .debug_loc section.\n"),
- (long)(start - section_begin), (long)(next - section_begin));
+ (unsigned long) (start - section_begin),
+ (unsigned long) (next - section_begin));
}
start = next;
{
if (start < next)
warn (_("There is a hole [0x%lx - 0x%lx] in %s section.\n"),
- (long)(start - section_begin),
- (long)(next - section_begin), section->name);
+ (unsigned long) (start - section_begin),
+ (unsigned long) (next - section_begin), section->name);
else if (start > next)
warn (_("There is an overlap [0x%lx - 0x%lx] in %s section.\n"),
- (long)(start - section_begin),
- (long)(next - section_begin), section->name);
+ (unsigned long) (start - section_begin),
+ (unsigned long) (next - section_begin), section->name);
}
start = next;
if (display_file_offsets && ((addr_offset + (octets / opb)) < stop_offset))
printf ("\t... (skipping %d zeroes, resuming at file offset: 0x%lx)\n",
octets / opb,
- (long int)(section->filepos + (addr_offset + (octets / opb))));
+ (unsigned long) (section->filepos
+ + (addr_offset + (octets / opb))));
else
printf ("\t...\n");
}
printf (_("Contents of section %s:"), section->name);
if (display_file_offsets)
- printf (_(" (Starting at file offset: 0x%lx)"), (long int)(section->filepos + start_offset));
+ printf (_(" (Starting at file offset: 0x%lx)"),
+ (unsigned long) (section->filepos + start_offset));
printf ("\n");
data = xmalloc (datasize);
if (fseek (file, archive_file_offset + offset, SEEK_SET))
{
error (_("Unable to seek to 0x%lx for %s\n"),
- archive_file_offset + offset, reason);
+ (unsigned long) archive_file_offset + offset, reason);
return NULL;
}
}
warn (_("Virtual address 0x%lx not located in any PT_LOAD segment.\n"),
- (long) vma);
+ (unsigned long) vma);
return (long) vma;
}
break;
default:
- printf ("%#lx\n", (long) entry->d_un.d_ptr);
+ printf ("%#lx\n", (unsigned long) entry->d_un.d_ptr);
}
}
printf (_("\nLibrary list section '%s' contains %lu entries:\n"),
SECTION_NAME (section),
- (long) (section->sh_size / sizeof (Elf32_External_Lib)));
+ (unsigned long) (section->sh_size / sizeof (Elf32_External_Lib)));
puts (" Library Time Stamp Checksum Version Flags");
if (((char *) next) > (((char *) pnotes) + length))
{
warn (_("corrupt note found at offset %lx into core notes\n"),
- (long)((char *)external - (char *)pnotes));
+ (unsigned long) ((char *) external - (char *) pnotes));
warn (_(" type: %lx, namesize: %08lx, descsize: %08lx\n"),
inote.type, inote.namesz, inote.descsz);
break;
/* resrc.c -- read and write Windows rc files.
- Copyright 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2005, 2007
+ Copyright 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2005, 2007, 2008
Free Software Foundation, Inc.
Written by Ian Lance Taylor, Cygnus Support.
Rewritten by Kai Tietz, Onevision.
if (got == c)
return;
- fatal (_("%s: read of %lu returned %lu"), msg, (long) c, (long) got);
+ fatal (_("%s: read of %lu returned %lu"),
+ msg, (unsigned long) c, (unsigned long) got);
}
\f
/* Define an accelerator resource. */
{
if (k == 0)
plen = fprintf (e, "0x%lxL",
- (long) windres_get_32 (&wrtarget, data + i, length - i));
+ (unsigned long) windres_get_32 (&wrtarget, data + i, length - i));
else
plen = fprintf (e, " 0x%lxL",
- (long) windres_get_32 (&wrtarget, data + i, length - i)) - 1;
+ (unsigned long) windres_get_32 (&wrtarget, data + i, length - i)) - 1;
if (has_next || (i + 4) < length)
{
if (plen>0 && plen < 11)
{
if (stringtable->strings[i].length != 0)
{
- fprintf (e, " %lu, ", (long) offset + i);
+ fprintf (e, " %lu, ", (unsigned long) offset + i);
unicode_print_quoted (e, stringtable->strings[i].string,
stringtable->strings[i].length);
fprintf (e, "\n");
(const rc_res_id *) NULL,
&language, 1);
if (sec_length != sec_length_wrote)
- fatal ("res write failed with different sizes (%lu/%lu).", (long) sec_length,
- (long) sec_length_wrote);
+ fatal ("res write failed with different sizes (%lu/%lu).",
+ (unsigned long) sec_length, (unsigned long) sec_length_wrote);
bfd_close (abfd);
return;
return NULL;
codepage_from_unicode (&l, usz, &s, mcset_codepage_out);
if (! s)
- fatal ("unicode string not mappable to ASCII codepage 0x%lx.\n", (long) mcset_codepage_out);
+ fatal ("unicode string not mappable to ASCII codepage 0x%lx.\n",
+ (unsigned long) mcset_codepage_out);
return s;
}
int i, l;
fprintf (fp,
- "/* Do not edit this file manually.\n"
- " This file is autogenerated by windmc. */\n\n");
+ "/* Do not edit this file manually.\n"
+ " This file is autogenerated by windmc. */\n\n");
if (! mc_nodes_lang_count)
return;
n = NULL;
++i;
n = mc_nodes_lang[l];
fprintf (fp, "\n// Country: %s\n// Language: %s\n#pragma code_page(%u)\n",
- n->lang->lang_info.country, n->lang->lang_info.name,
- (unsigned) n->lang->lang_info.wincp);
- fprintf (fp, "LANGUAGE 0x%lx, 0x%lx\n", (long) (n->lang->nval & 0x3ff),
- (long) ((n->lang->nval & 0xffff) >> 10));
+ n->lang->lang_info.country, n->lang->lang_info.name,
+ (unsigned) n->lang->lang_info.wincp);
+ fprintf (fp, "LANGUAGE 0x%lx, 0x%lx\n",
+ (unsigned long) (n->lang->nval & 0x3ff),
+ (unsigned long) ((n->lang->nval & 0xffff) >> 10));
fprintf (fp, "1 MESSAGETABLE \"");
if (mcset_prefix_bin)
fprintf (fp, "%s_", mcset_mc_basename);
+2008-07-30 Alan Modra <amodra@bigpond.net.au>
+
+ * messages.c, symbols.c, write.c: Silence gcc warnings.
+
2008-07-28 Ineiev <ineiev@yahoo.co.uk>
* config/tc-i386.c (operand_type_check): Warning fix.
/* messages.c - error reporter -
Copyright 1987, 1991, 1992, 1993, 1994, 1995, 1996, 1998, 2000, 2001,
- 2003, 2004, 2005, 2006, 2007
+ 2003, 2004, 2005, 2006, 2007, 2008
Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
if (sizeof (val) > sizeof (bfd_vma))
abort ();
- sprintf_vma (val_buf, val);
- sprintf_vma (min_buf, min);
- sprintf_vma (max_buf, max);
+ sprintf_vma (val_buf, (bfd_vma) val);
+ sprintf_vma (min_buf, (bfd_vma) min);
+ sprintf_vma (max_buf, (bfd_vma) max);
/* xgettext:c-format. */
err = _("%s out of range (0x%s is not between 0x%s and 0x%s)");
/* symbols.c -symbol table-
Copyright 1987, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
- 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
+ 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
if (s != undefined_section
&& s != expr_section)
- fprintf (file, " %lx", (long) S_GET_VALUE (sym));
+ fprintf (file, " %lx", (unsigned long) S_GET_VALUE (sym));
}
else if (indent_level < max_indent_level
&& S_GET_SEGMENT (sym) != undefined_section)
fprintf (file, "\n%*s<", indent_level * 4, "");
if (LOCAL_SYMBOL_CHECK (sym))
fprintf (file, "constant %lx",
- (long) ((struct local_symbol *) sym)->lsy_value);
+ (unsigned long) ((struct local_symbol *) sym)->lsy_value);
else
print_expr_1 (file, &sym->sy_value);
fprintf (file, ">");
fprintf (file, "absent");
break;
case O_constant:
- fprintf (file, "constant %lx", (long) exp->X_add_number);
+ fprintf (file, "constant %lx", (unsigned long) exp->X_add_number);
break;
case O_symbol:
indent_level++;
maybe_print_addnum:
if (exp->X_add_number)
fprintf (file, "\n%*s%lx", indent_level * 4, "",
- (long) exp->X_add_number);
+ (unsigned long) exp->X_add_number);
indent_level--;
break;
case O_register:
/* write.c - emit .o file
Copyright 1986, 1987, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997,
- 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
+ 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
fprintf_vma (stderr, (bfd_vma) ((bfd_hostptr_t) fixp->fx_frag));
fprintf (stderr, " where=%ld offset=%lx addnumber=%lx",
(long) fixp->fx_where,
- (long) fixp->fx_offset, (long) fixp->fx_addnumber);
+ (unsigned long) fixp->fx_offset,
+ (unsigned long) fixp->fx_addnumber);
fprintf (stderr, "\n %s (%d)", bfd_get_reloc_code_name (fixp->fx_r_type),
fixp->fx_r_type);
if (fixp->fx_addsy)
+2008-07-30 Alan Modra <amodra@bigpond.net.au>
+
+ * corefile.c, symtab.c: Silence gcc warnings.
+
2008-06-19 Andreas Schwab <schwab@suse.de>
* basic_blocks.c: Always include "gprof.h" first.
/* corefile.c
- Copyright 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2007
+ Copyright 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2007, 2008
Free Software Foundation, Inc.
This file is part of GNU Binutils.
else
{
DBG (AOUTDEBUG, printf ("[get_src_info] no info for 0x%lx (%s:%d,%s)\n",
- (long) addr, fname ? fname : "<unknown>", l,
+ (unsigned long) addr,
+ fname ? fname : "<unknown>", l,
func_name ? func_name : "<unknown>"));
return FALSE;
}
/* symtab.c
- Copyright 1999, 2000, 2001, 2002, 2004, 2007 Free Software Foundation, Inc.
+ Copyright 1999, 2000, 2001, 2002, 2004, 2007, 2008
+ Free Software Foundation, Inc.
This file is part of GNU Binutils.
for (j = 0; j < tab->len; ++j)
{
printf ("[symtab_finalize] 0x%lx-0x%lx\t%s\n",
- (long) tab->base[j].addr, (long) tab->base[j].end_addr,
- tab->base[j].name);
+ (unsigned long) tab->base[j].addr,
+ (unsigned long) tab->base[j].end_addr,
+ tab->base[j].name);
}
);
}
Sym *
dbg_sym_lookup (Sym_Table *sym_tab, bfd_vma address)
{
- long low, mid, high;
+ unsigned long low, mid, high;
Sym *sym;
fprintf (stderr, "[dbg_sym_lookup] address 0x%lx\n",
+2008-07-30 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/pe.em, emultempl/pep.em: Silence gcc warnings.
+
2008-07-18 Joseph Myers <joseph@codesourcery.com>
* ld.texinfo (--no-wchar-size-warning): Document new ARM option.
if (pe_dll_extra_pe_debug)
printf ("arelent: %s@%#lx: add=%li\n", sym->name,
- (long) rel->address, (long) rel->addend);
+ (unsigned long) rel->address, (long) rel->addend);
if (! bfd_get_section_contents (s->owner, s, addend, rel->address, sizeof (addend)))
einfo (_("%C: Cannot get section contents - auto-import exception\n"),
if (pep_dll_extra_pe_debug)
printf ("arelent: %s@%#lx: add=%li\n", sym->name,
- (long) rel->address, (long) rel->addend);
+ (unsigned long) rel->address, (long) rel->addend);
if (! bfd_get_section_contents (s->owner, s, addend, rel->address, sizeof (addend)))
einfo (_("%C: Cannot get section contents - auto-import exception\n"),
+2008-07-30 Alan Modra <amodra@bigpond.net.au>
+
+ * bfin-dis.c, cris-dis.c, i386-dis.c, or32-opc.c: Silence gcc warnings.
+
2008-07-10 Richard Sandiford <rdsandiford@googlemail.com>
* mips-dis.c (_print_insn_mips): Use ELF_ST_IS_MIPS16.
/* Disassemble ADI Blackfin Instructions.
- Copyright 2005, 2007 Free Software Foundation, Inc.
+ Copyright 2005, 2007, 2008 Free Software Foundation, Inc.
This file is part of libopcodes.
}
else
{
- sprintf (buf, "%lx", x);
+ sprintf (buf, "%lx", (unsigned long) x);
return buf;
}
}
if (constant_formats[cf].issigned && x < 0)
sprintf (buf, "-0x%x", abs (x));
else
- sprintf (buf, "0x%lx", x);
+ sprintf (buf, "0x%lx", (unsigned long) x);
}
return buf;
/* Disassembler code for CRIS.
- Copyright 2000, 2001, 2002, 2004, 2005, 2006, 2007
+ Copyright 2000, 2001, 2002, 2004, 2005, 2006, 2007, 2008
Free Software Foundation, Inc.
Contributed by Axis Communications AB, Lund, Sweden.
Written by Hans-Peter Nilsson.
format_dec (long number, char *outbuffer, int signedp)
{
last_immediate = number;
- sprintf (outbuffer, signedp ? "%ld" : "%lu", number);
+ if (signedp)
+ sprintf (outbuffer, "%ld", number);
+ else
+ sprintf (outbuffer, "%lu", (unsigned long) number);
return outbuffer + strlen (outbuffer);
}
/* Print i386 instructions for GDB, the GNU debugger.
Copyright 1988, 1989, 1991, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2001, 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+ 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
+ Free Software Foundation, Inc.
This file is part of the GNU opcodes library.
buf[j++] = '0';
buf[j++] = 'x';
- sprintf_vma (tmp, val);
+ sprintf_vma (tmp, (bfd_vma) val);
for (i = 0; tmp[i] == '0'; i++)
continue;
if (tmp[i] == '\0')
/* Table of opcodes for the OpenRISC 1000 ISA.
- Copyright 2002, 2004, 2005, 2007 Free Software Foundation, Inc.
+ Copyright 2002, 2004, 2005, 2007, 2008 Free Software Foundation, Inc.
Contributed by Damjan Lampret (lampret@opencores.org).
This file is part of the GNU opcodes library.
c = cover_insn (cur, curpass, mask & (~(cur_mask << best_first)));
if (c)
{
- debug (8, "%li> #%X -> %lu\n", (long)(next - automata), i, (long)(cur - automata));
+ debug (8, "%li> #%X -> %lu\n", (long)(next - automata), i,
+ (unsigned long)(cur - automata));
*next = cur - automata;
cur = c;
}