bebbo / binutils-gdb

Unofficial mirror of sourceware binutils-gdb repository. Updated daily.
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git
GNU General Public License v2.0
3 stars 3 forks source link

strip damages .o and .a files instead of stripping #9

Closed githubaf closed 4 years ago

githubaf commented 5 years ago

I compiled libnix.a with -g and tried to strip it afterwards, Stripping does not chage the size. (remains huge) "stripped" libnix.a cannot be linked afterwards.

The same is true for .o files. I created a simple hello_world.c and compiled it with -c -g Then I stripped the hello.o file. It remains big. Linking the "stripped" hello.o failed with "missing main".

Stripping executables works.

bebbo commented 5 years ago

no idea if this should succeed...

githubaf commented 5 years ago

Seems I did not really understand what strip is stripping depending on the commandline options... Issue can probably be closed again.