Just some notes for my friends -- Andre Stechert

June 27, 2005

ldd: ld-linux.so.2 exited with unknown exit code (139)

Bumped into this error message while building custom glibcs. Google results were mostly folks expressing confusion, so I thought I'd post as a decode.

What's going on here is that ldd, which is a bash script, is invoking the glibc dynamic loader for you with its --verify option. The ld-linux.so.2 thing? That's the dynamic loader. Yes, you can invoke it directly. Try it. And read the ldd bash script while you're at it. Anyway 139 = 128 + 11. When a command within a shell script gets signaled, its return value is 128 + the signal number. Signal number 11? SIGSEGV.

Probably what you want to do at this point is ulimit -c, invoke ld-linux.so.2 manually, and then use gdb to see what's causing it to fail. Good luck!