[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug ld/28903] LD producing SegFault executables with FreePascal 2.6.4,
From: |
amodra at gmail dot com |
Subject: |
[Bug ld/28903] LD producing SegFault executables with FreePascal 2.6.4, in Binutils-2.36.1 and later |
Date: |
Tue, 01 Mar 2022 00:02:24 +0000 |
https://sourceware.org/bugzilla/show_bug.cgi?id=28903
Alan Modra <amodra at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|REOPENED |RESOLVED
Resolution|--- |INVALID
--- Comment #23 from Alan Modra <amodra at gmail dot com> ---
The segfaults are due to your linker script setting the value of "dot" to near
zero with ". = 0 + SIZEOF_HEADERS;" then containing a .data output section
with additional contents over the standard .data section. That extra .data
section then has a vma in the unmapped page at zero (unmapped to catch NULL
pointer dereferences). Unsurprisingly you get segfaults in the loader. If the
linker uses your script with -T, which seems to be the intent, the the whole
binary is mapped low. Segfaults again.
The linker script is plainly and obviously broken. Newer linkers are simply
doing as asked. Closing, please don't reopen.
--
You are receiving this mail because:
You are on the CC list for the bug.
- [Bug ld/28903] LD producing SegFault executables with FreePascal 2.6.4, in Binutils-2.36.1 and later, (continued)
- [Bug ld/28903] LD producing SegFault executables with FreePascal 2.6.4, in Binutils-2.36.1 and later, hjl.tools at gmail dot com, 2022/02/17
- [Bug ld/28903] LD producing SegFault executables with FreePascal 2.6.4, in Binutils-2.36.1 and later, hjl.tools at gmail dot com, 2022/02/18
- [Bug ld/28903] LD producing SegFault executables with FreePascal 2.6.4, in Binutils-2.36.1 and later, hjl.tools at gmail dot com, 2022/02/18
- [Bug ld/28903] LD producing SegFault executables with FreePascal 2.6.4, in Binutils-2.36.1 and later, hjl.tools at gmail dot com, 2022/02/18
- [Bug ld/28903] LD producing SegFault executables with FreePascal 2.6.4, in Binutils-2.36.1 and later, hjl.tools at gmail dot com, 2022/02/18
- [Bug ld/28903] LD producing SegFault executables with FreePascal 2.6.4, in Binutils-2.36.1 and later, jbthiel at gmail dot com, 2022/02/27
- [Bug ld/28903] LD producing SegFault executables with FreePascal 2.6.4, in Binutils-2.36.1 and later, hjl.tools at gmail dot com, 2022/02/27
- [Bug ld/28903] LD producing SegFault executables with FreePascal 2.6.4, in Binutils-2.36.1 and later, jbthiel at gmail dot com, 2022/02/28
- [Bug ld/28903] LD producing SegFault executables with FreePascal 2.6.4, in Binutils-2.36.1 and later, jbthiel at gmail dot com, 2022/02/28
- [Bug ld/28903] LD producing SegFault executables with FreePascal 2.6.4, in Binutils-2.36.1 and later, nickc at redhat dot com, 2022/02/28
- [Bug ld/28903] LD producing SegFault executables with FreePascal 2.6.4, in Binutils-2.36.1 and later,
amodra at gmail dot com <=