bug-binutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: secti


From: nickc at redhat dot com
Subject: [Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows
Date: Fri, 03 Feb 2023 20:40:07 +0000

https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #18 from Nick Clifton <nickc at redhat dot com> ---
Created attachment 14652
  --> https://sourceware.org/bugzilla/attachment.cgi?id=14652&action=edit
Proposed patch

Interesting.  The issue is the section itself: .rdata_r.  This is not a normal
PE section name, and it is missing from the default script used by the linker. 
So instead the orphan section handling code is activated, and this places the
section into the .rdata section.  But in doing so, it also sets the vaddr for
the .rdata section to 0.

The .rdata_r section is being created by the LTO plugin when it recompiles
helloworld.cc.  I am not sure why this is happening.  But there is an easy fix
- add the .rdata_r section to the default linker map.  So that is what this
patch does.

Please try out the patch and let me know if it works for you.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]