aboutsummaryrefslogtreecommitdiff
path: root/ld
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2023-01-06 19:34:15 +1030
committerAlan Modra <amodra@gmail.com>2023-01-06 21:06:15 +1030
commit10df41b188b2692b6bc8c36d4003e0f8790d1f1b (patch)
tree8e35758d1b7208320c9808601492948b381be905 /ld
parent22a95e1a37aff28238e9d40bbe4441aa554a14c6 (diff)
downloadgdb-10df41b188b2692b6bc8c36d4003e0f8790d1f1b.zip
gdb-10df41b188b2692b6bc8c36d4003e0f8790d1f1b.tar.gz
gdb-10df41b188b2692b6bc8c36d4003e0f8790d1f1b.tar.bz2
Tidy pe flag in coff_data
Make it a bool, use obj_pe accessor everywhere.
Diffstat (limited to 'ld')
-rw-r--r--ld/emultempl/beos.em2
-rw-r--r--ld/emultempl/pe.em2
-rw-r--r--ld/emultempl/pep.em2
3 files changed, 3 insertions, 3 deletions
diff --git a/ld/emultempl/beos.em b/ld/emultempl/beos.em
index 1f3b67b..521d927 100644
--- a/ld/emultempl/beos.em
+++ b/ld/emultempl/beos.em
@@ -379,7 +379,7 @@ gld${EMULATION_NAME}_after_open (void)
/* Pass the wacky PE command line options into the output bfd.
FIXME: This should be done via a function, rather than by
including an internal BFD header. */
- if (!coff_data(link_info.output_bfd)->pe)
+ if (!obj_pe (link_info.output_bfd))
{
einfo (_("%F%P: PE operations on non PE file\n"));
}
diff --git a/ld/emultempl/pe.em b/ld/emultempl/pe.em
index d201a97..bce1d1b 100644
--- a/ld/emultempl/pe.em
+++ b/ld/emultempl/pe.em
@@ -1515,7 +1515,7 @@ gld${EMULATION_NAME}_after_open (void)
if (bfd_get_flavour (link_info.output_bfd) != bfd_target_coff_flavour
|| coff_data (link_info.output_bfd) == NULL
- || coff_data (link_info.output_bfd)->pe == 0)
+ || !obj_pe (link_info.output_bfd))
einfo (_("%F%P: cannot perform PE operations on non PE output file '%pB'\n"),
link_info.output_bfd);
diff --git a/ld/emultempl/pep.em b/ld/emultempl/pep.em
index d61cab8..69b1c3e 100644
--- a/ld/emultempl/pep.em
+++ b/ld/emultempl/pep.em
@@ -1519,7 +1519,7 @@ gld${EMULATION_NAME}_after_open (void)
if (bfd_get_flavour (link_info.output_bfd) != bfd_target_coff_flavour
|| coff_data (link_info.output_bfd) == NULL
- || coff_data (link_info.output_bfd)->pe == 0)
+ || !obj_pe (link_info.output_bfd))
einfo (_("%F%P: cannot perform PE operations on non PE output file '%pB'\n"),
link_info.output_bfd);