[MLton-devel] strip bug on Debian causing MLton segfault

Henry Cejtin henry@sourcelight.com
Tue, 15 Jul 2003 12:54:13 -0500


That doesn't necessarily prove that it is strip at fault (although I agree
that it looks likely).  When things get run, different parts are moved to
page boundaries.  It could be that part of the symbol table is mapped in to
the executable, in which case there are slightly fewer addresses that would
cause a segfault if it is not stripped (or stripped in a different way).
It is also true that the header that describes what parts of the file should
get mapped in and where is just being mangled with the Debian strip.
You could check some of this by setting a break point in main and then running
the version.  When it gets to the break point, look at /proc/<pid>/maps
and see what things look like in the stripped and non-stripped version.
Note, in the stripped version the symbol main will not be there, but
you can do `nm' before you strip, and then use
	break *0x???
to set a break point at the address of main in both the stripped and
non-stripped version.

If the problem is the table of addresses in the stripped executable being
mangled, you can use the objdump program to see what it looks like.
The usage is a mess but I remember getting various things dumped out.



-------------------------------------------------------
This SF.Net email sponsored by: Parasoft
Error proof Web apps, automate testing & more.
Download & eval WebKing and get a free book.
www.parasoft.com/bulletproofapps1
_______________________________________________
MLton-devel mailing list
MLton-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mlton-devel