ld:i386 crashes with -static -fPIE -pie
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
GLibC |
Incomplete
|
Medium
|
|||
binutils (Ubuntu) |
Confirmed
|
High
|
Unassigned | ||
Trusty |
Invalid
|
High
|
Diego | ||
eglibc (Debian) |
Fix Released
|
Unknown
|
|||
eglibc (Ubuntu) |
Fix Released
|
Medium
|
Unassigned | ||
Trusty |
Fix Released
|
Medium
|
Unassigned | ||
evolution-data-server (Ubuntu) |
Fix Released
|
Critical
|
Unassigned | ||
Trusty |
Invalid
|
Critical
|
Unassigned | ||
xorg-server (Ubuntu) |
Fix Released
|
Critical
|
Unassigned | ||
Trusty |
Fix Released
|
Critical
|
Unassigned |
Bug Description
Making a simple file conftest.c with the following contents:
int main() { return 0; }
And then compiling it on i386 with gcc -fPIE -pie -static conftest.c
returns:
*** Error in `/usr/bin/ld': corrupted double-linked list: 0x08dddb38 ***
This breaks compilation xorg-server on i386. I believe that -static -fPIE -pie is probably invalid, and it fails on amd64 too.
$ gcc -fPIE -pie -static conftest.c
/usr/bin/ld: /usr/lib/
/usr/lib/
collect2: error: ld returned 1 exit status
But autoconf hangs on the corrupted double-linked list, which times out the xorg-server build.
Changed in binutils (Ubuntu): | |
importance: | Undecided → High |
tags: | added: ftbfs |
Changed in eglibc: | |
importance: | Unknown → Medium |
status: | Unknown → Incomplete |
affects: | eglibc → glibc |
Changed in evolution-data-server (Ubuntu Trusty): | |
milestone: | ubuntu-14.04.1 → trusty-updates |
Changed in xorg-server (Ubuntu): | |
milestone: | ubuntu-14.01 → none |
Changed in evolution-data-server (Ubuntu): | |
milestone: | ubuntu-14.04.1 → none |
Changed in eglibc (Ubuntu): | |
importance: | Undecided → Medium |
Changed in eglibc (Ubuntu Trusty): | |
importance: | Undecided → Medium |
Changed in eglibc (Debian): | |
status: | Unknown → Fix Released |
Changed in evolution-data-server (Ubuntu Trusty): | |
status: | Confirmed → Triaged |
Changed in binutils (Ubuntu Trusty): | |
assignee: | nobody → Diego (dmggears3) |
malloc_printerr() on error detection "free(): invalid next size (fast)" ends up calling into:
backtrace.c:init() c:do_dlopen( ) c:malloc_ printerr( )
dl-libc.
malloc.c:calloc()
malloc.
The malloc error reporting should only report the first error, not attempt to recusively report all error (we knew it was corrupted at the outer most point, so any further work inside malloc is also likely to find corruption).
Full stack trace to follow.
The main problem is the process does not abort() and die, it hangs around in:
pthread_ once.S: pthread_ one() c:__backtrace( )
backtrace.
I think due to recursive lock, this lock should trylock() on the 2nd time and abort() the process immediately. It does appear to deadlock itself.