[Bug ld/25029] Invalid PE file caused by discarded .rdata section

2019-10-11 Thread nickc at redhat dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=25029

--- Comment #6 from Nick Clifton  ---
Created attachment 12038
  --> https://sourceware.org/bugzilla/attachment.cgi?id=12038=edit
Proposed patch

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug ld/25029] Invalid PE file caused by discarded .rdata section

2019-10-11 Thread nickc at redhat dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=25029

--- Comment #5 from Nick Clifton  ---
Hi Florin,

Just checking...

> The problem is in fact with the SizeOfImage and SizeOfHeaders fields.
> If I call the data section .rdata, then I get a SizeOfImage of 0x4000 and a
> SizeOfHeaders of 0x200 which is correct.
> But if I call the data section .data, then I get a SizeOfImage of 0x3000 and
> a SizeOfHeaders of 0x400.

I assume that you mean that the SizeOfImage is 0x4000 with .data, not 0x3000 ?
The actual size of the executable does not change...

> It seems that ld considers the empty 512 bytes, from the discarded .rdata
> section, as part of the header.

Agreed - and I am uploading a patch which I think will fix the problem.
Please could you give it a try and let me know if it actually works ?

Cheers
  Nick

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug ld/25062] arm: R_ARM_TLS_GOTDESC negative addend is not handled on 64bit host

2019-10-11 Thread nsz at gcc dot gnu.org
https://sourceware.org/bugzilla/show_bug.cgi?id=25062

Szabolcs Nagy  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution|--- |FIXED

--- Comment #3 from Szabolcs Nagy  ---
fixed for 2.34 and on the 2.33 branch.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug ld/25056] ld fails to bind DTPMOD at link time for pie on arm

2019-10-11 Thread nsz at gcc dot gnu.org
https://sourceware.org/bugzilla/show_bug.cgi?id=25056

Szabolcs Nagy  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution|--- |FIXED

--- Comment #8 from Szabolcs Nagy  ---
fixed for 2.34 and on the 2.33 branch.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug ld/25029] Invalid PE file caused by discarded .rdata section

2019-10-11 Thread florin.saft...@soft-to-you.com
https://sourceware.org/bugzilla/show_bug.cgi?id=25029

--- Comment #4 from Florin Saftoiu  ---
PS: I actually modified the .exe file to change SizeOfImage to 0x4000 and
SizeOfHeaders to 0x200 and I can now execute it in Windows.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug binutils/23059] OOM-Bug in cxxfilt (binuitils-2.30-15ubuntu1)

2019-10-11 Thread kamleshbhalui at gmail dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=23059

Kamlesh Kumar  changed:

   What|Removed |Added

 CC||kamleshbhalui at gmail dot com

--- Comment #3 from Kamlesh Kumar  ---
ChangeLog which fixes this.

2018-12-22  Jason Merrill  

Remove support for demangling GCC 2.x era mangling schemes.
* cplus-dem.c: Remove cplus_mangle_opname, cplus_demangle_opname,
internal_cplus_demangle, and all subroutines.
(libiberty_demanglers): Remove entries for ancient GNU (pre-3.0),
Lucid, ARM, HP, and EDG demangling styles.
(cplus_demangle): Remove 'work' variable.  Don't call
internal_cplus_demangle.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug ld/25029] Invalid PE file caused by discarded .rdata section

2019-10-11 Thread florin.saft...@soft-to-you.com
https://sourceware.org/bugzilla/show_bug.cgi?id=25029

--- Comment #3 from Florin Saftoiu  ---
Hi Nick,

Thanks for your reply.

You're right about the entry point, it is correct. But Windows still wouldn't
run my program so I took another look at the file.

The problem is in fact with the SizeOfImage and SizeOfHeaders fields.
If I call the data section .rdata, then I get a SizeOfImage of 0x4000 and a
SizeOfHeaders of 0x200 which is correct.
But if I call the data section .data, then I get a SizeOfImage of 0x3000 and a
SizeOfHeaders of 0x400.

Microsoft says
(https://docs.microsoft.com/en-us/windows/win32/debug/pe-format?redirectedfrom=MSDN#optional-header-image-only)
that SizeOfImage should be "The size (in bytes) of the image, including all
headers, as the image is loaded in memory. It must be a multiple of
SectionAlignment." and SizeOfHeaders should be "The combined size of an MS-DOS
stub, PE header, and section headers rounded up to a multiple of
FileAlignment."

It seems that ld considers the empty 512 bytes, from the discarded .rdata
section, as part of the header. I've no hypothesis about why the SizeOfImage is
messed up.

Hope this helps.

Best regards,
Florin

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug binutils/25063] 2.33: Missing dist tar ball

2019-10-11 Thread kloczko.tomasz at gmail dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=25063

--- Comment #3 from kloczek  ---
Easiest way to solve issue with downloading tar ball from release tag would be
upgrade git frontend to latest cgit ot gitlab interface which provides OOTB
possibility to download compressed or not archive from tag accessible over
exact URL.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils