Help with strip
Garrett Kajmowicz
gkajmowi@tbaytel.net
Sat Dec 18 17:23:00 GMT 2004
This is going to sound somewhat odd, but I'm having a hard time getting strip
to do what I want it to do. It might be that I am usign the wrong tool. If
so, please let me know.
Please ignore the fact that this doesn't make a lot of sense - it does, but it
would take al ong time to explain the reasoning for it.
I compile a file which defines a function. It doesn't matter what the
function does.
I then
strip -N functionname function.o
The file is reduced slightly in size. So far, so good.
However, when I run objdump -D function.o, the only visible difference is that
the name of the function has been stripped.
I do not just want to remove the name of a function - I want to remove a
function altogether, including its code.
When the object file is linked into a larger file, I do not want that code to
be included. More precisely, I want that symbol to be considered undefined.
Weak symbols won't do.
Please advise.
- Garrett Kajmowicz
More information about the Binutils
mailing list