aboutsummaryrefslogtreecommitdiff
path: root/binutils/nm.c
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2007-09-13 14:32:11 +0000
committerAlan Modra <amodra@gmail.com>2007-09-13 14:32:11 +0000
commit39dbeff83eda4b7d3c2799e698db3c047e9d3a22 (patch)
tree125c79d21e6ab63f84609ae25c2eb7c0db9a983b /binutils/nm.c
parent17b6b921e4dc4f844f946b17d4e7685c3a7018c0 (diff)
downloadgdb-39dbeff83eda4b7d3c2799e698db3c047e9d3a22.zip
gdb-39dbeff83eda4b7d3c2799e698db3c047e9d3a22.tar.gz
gdb-39dbeff83eda4b7d3c2799e698db3c047e9d3a22.tar.bz2
* nm.c (value_format_64bit, set_print_radix, print_value): Handle
BFD_HOST_64BIT_LONG_LONG. * readelf.c (print_dec_vma): Don't define if BFD_HOST_64BIT_LONG_LONG. (print_vma): Handle BFD_HOST_64BIT_LONG_LONG. (dump_relocations): Likewise. Expand _bfd_int64_low in a number of places.
Diffstat (limited to 'binutils/nm.c')
-rw-r--r--binutils/nm.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/binutils/nm.c b/binutils/nm.c
index d5f18cd..1dbf47e 100644
--- a/binutils/nm.c
+++ b/binutils/nm.c
@@ -160,7 +160,11 @@ static int filename_per_symbol = 0; /* Once per symbol, at start of line. */
/* Print formats for printing a symbol value. */
static char value_format_32bit[] = "%08lx";
+#if BFD_HOST_64BIT_LONG
static char value_format_64bit[] = "%016lx";
+#elif BFD_HOST_64BIT_LONG_LONG
+static char value_format_64bit[] = "%016llx";
+#endif
static int print_width = 0;
static int print_radix = 16;
/* Print formats for printing stab info. */
@@ -269,7 +273,11 @@ set_print_radix (char *radix)
else
print_radix = 8;
value_format_32bit[4] = *radix;
+#if BFD_HOST_64BIT_LONG
value_format_64bit[5] = *radix;
+#elif BFD_HOST_64BIT_LONG_LONG
+ value_format_64bit[6] = *radix;
+#endif
other_format[3] = desc_format[3] = *radix;
break;
default:
@@ -1341,7 +1349,7 @@ print_value (bfd *abfd ATTRIBUTE_UNUSED, bfd_vma val)
break;
case 64:
-#if BFD_HOST_64BIT_LONG
+#if BFD_HOST_64BIT_LONG || BFD_HOST_64BIT_LONG_LONG
printf (value_format_64bit, val);
#else
/* We have a 64 bit value to print, but the host is only 32 bit. */