From: Nick Clifton <nickc@sourceware.org>
To: bfd-cvs@sourceware.org
Subject: [binutils-gdb] So the linker from producing an export data table when run with --exclude-all-symbols.
Date: Mon, 20 Feb 2023 11:33:39 +0000 (GMT) [thread overview]
Message-ID: <20230220113339.2FE753858D1E@sourceware.org> (raw)
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=c9802aca6d152c4a47252f69ad81556dbc24e312
commit c9802aca6d152c4a47252f69ad81556dbc24e312
Author: Nick Clifton <nickc@redhat.com>
Date: Mon Feb 20 11:32:52 2023 +0000
So the linker from producing an export data table when run with --exclude-all-symbols.
PR 30004 * pe-dll.c (pe_dll_build_sections): Do not build an edata section if all symbols are being excluded.
Diff:
---
ld/ChangeLog | 6 ++++++
ld/pe-dll.c | 3 ++-
2 files changed, 8 insertions(+), 1 deletion(-)
diff --git a/ld/ChangeLog b/ld/ChangeLog
index 0fa00a95525..de9ed2753bc 100644
--- a/ld/ChangeLog
+++ b/ld/ChangeLog
@@ -1,3 +1,9 @@
+2023-02-20 Nick Clifton <nickc@redhat.com>
+
+ PR 30004
+ * pe-dll.c (pe_dll_build_sections): Do not build an edata section
+ if all symbols are being excluded.
+
2023-02-16 Ulf Samuelsson <binutils@emagii.com>
Nick Clifton <nickc@redhat.com>
diff --git a/ld/pe-dll.c b/ld/pe-dll.c
index 2956eef1ca9..7e0d886cfb9 100644
--- a/ld/pe-dll.c
+++ b/ld/pe-dll.c
@@ -3659,7 +3659,8 @@ pe_dll_build_sections (bfd *abfd, struct bfd_link_info *info)
pe_output_file_set_long_section_names (abfd);
process_def_file_and_drectve (abfd, info);
- if (pe_def_file->num_exports == 0 && !bfd_link_pic (info))
+ if (pe_def_file->num_exports == 0
+ && (!bfd_link_pic (info) || pe_dll_exclude_all_symbols))
{
if (pe_dll_enable_reloc_section)
{
reply other threads:[~2023-02-20 11:33 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230220113339.2FE753858D1E@sourceware.org \
--to=nickc@sourceware.org \
--cc=bfd-cvs@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).