aboutsummaryrefslogtreecommitdiff
path: root/bfd/coffcode.h
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2017-07-03 21:59:30 +0930
committerAlan Modra <amodra@gmail.com>2017-07-03 22:03:48 +0930
commitce9116fdbfba8926a7bc25613d39bc3b2ed942fc (patch)
tree78a13ca90ae15c14c35ee77807cde3ba98363f8d /bfd/coffcode.h
parentcd9af601e60240bb38dc58ce7e69abd5f2972ec7 (diff)
downloadgdb-ce9116fdbfba8926a7bc25613d39bc3b2ed942fc.zip
gdb-ce9116fdbfba8926a7bc25613d39bc3b2ed942fc.tar.gz
gdb-ce9116fdbfba8926a7bc25613d39bc3b2ed942fc.tar.bz2
BFD long long cleanup
long long isn't supposed to be used without a configure test, to support ancient compilers. Probably not terribly important nowadays. * bfd.c (bfd_scan_vma): Don't use long long unless HAVE_LONG_LONG. * coff-rs6000.c (FMT20): Handle hosts with 64-bit long and Microsoft C library variant of long long format specifier. (PRINT20): Cast value to bfd_uint64_t not long long. * coffcode.h (coff_print_aux): Use BFD_VMA_FMT. * coff-x86_64.c (coff_amd64_reloc): Use bfd_uint64_t rather than long long. Don't cast to bfd_vma. * elf32-score.c (score3_bfd_getl48): Likewise. * vms-alpha.c (_bfd_vms_slurp_eisd): Likewise.
Diffstat (limited to 'bfd/coffcode.h')
-rw-r--r--bfd/coffcode.h16
1 files changed, 4 insertions, 12 deletions
diff --git a/bfd/coffcode.h b/bfd/coffcode.h
index 3331f4c..d6388d7 100644
--- a/bfd/coffcode.h
+++ b/bfd/coffcode.h
@@ -2599,23 +2599,15 @@ coff_print_aux (bfd *abfd ATTRIBUTE_UNUSED,
if (SMTYP_SMTYP (aux->u.auxent.x_csect.x_smtyp) != XTY_LD)
{
BFD_ASSERT (! aux->fix_scnlen);
-#ifdef XCOFF64
- fprintf (file, "val %5lld",
- (long long) aux->u.auxent.x_csect.x_scnlen.l);
-#else
- fprintf (file, "val %5ld", (long) aux->u.auxent.x_csect.x_scnlen.l);
-#endif
+ fprintf (file, "val %5" BFD_VMA_FMT "d",
+ aux->u.auxent.x_csect.x_scnlen.l);
}
else
{
fprintf (file, "indx ");
if (! aux->fix_scnlen)
-#ifdef XCOFF64
- fprintf (file, "%4lld",
- (long long) aux->u.auxent.x_csect.x_scnlen.l);
-#else
- fprintf (file, "%4ld", (long) aux->u.auxent.x_csect.x_scnlen.l);
-#endif
+ fprintf (file, "%4" BFD_VMA_FMT "d",
+ aux->u.auxent.x_csect.x_scnlen.l);
else
fprintf (file, "%4ld",
(long) (aux->u.auxent.x_csect.x_scnlen.p - table_base));