[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug ld/27567] Linking PE files adds alignment section flags to executab
From: |
cvs-commit at gcc dot gnu.org |
Subject: |
[Bug ld/27567] Linking PE files adds alignment section flags to executables |
Date: |
Fri, 16 Apr 2021 13:52:00 +0000 |
https://sourceware.org/bugzilla/show_bug.cgi?id=27567
--- Comment #1 from cvs-commit at gcc dot gnu.org <cvs-commit at gcc dot
gnu.org> ---
The master branch has been updated by Alan Modra <amodra@sourceware.org>:
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=6f8f6017a0c4e22c6417c597c31b0a937d148a39
commit 6f8f6017a0c4e22c6417c597c31b0a937d148a39
Author: Alan Modra <amodra@gmail.com>
Date: Fri Apr 16 22:29:05 2021 +0930
PR27567, Linking PE files adds alignment section flags to executables
So don't set those flags for an executable. In the patch I also test
DYNAMIC even though the PE bfd code doesn't appear to set it for dlls.
I figure it doesn't hurt to include that flag too.
PR 27567
bfd/
* coffcode.h (styp_to_sec_flags): Use an unsigned long styp_flags.
(coff_write_object_contents): Pass bfd to COFF_ENCODE_ALIGNMENT,
ignore alignment checks when return is false. Formatting.
include/
* coff/internal.h (struct internal_scnhdr): Make s_flags unsigned
long.
* coff/pe.h (COFF_ENCODE_ALIGNMENT): Don't set align flags for an
executable and return false. Do so for a relocatable object and
evaluate to true.
* coff/ti.h (COFF_ENCODE_ALIGNMENT): Add bfd arg and evaluate to
true.
(COFF_DECODE_ALIGNMENT): Formatting.
* coff/z80.h (COFF_ENCODE_ALIGNMENT): Similarly.
(COFF_DECODE_ALIGNMENT): Similarly.
--
You are receiving this mail because:
You are on the CC list for the bug.
- [Bug ld/27567] Linking PE files adds alignment section flags to executables,
cvs-commit at gcc dot gnu.org <=