[chapter 9] strip debug symbols

Bill's LFS Login lfsbill at wlmcs.com
Wed Jan 15 11:19:47 PST 2003


On Wed, 15 Jan 2003, Matijs wrote:

> > Are you sure? There are a great many files that are not executables in
> > those directories. Strip issues a warning message for them. For the
> > others, I think strip is silent. Do 'file' on a few binaries and see if
> > they stripped OK. Or you could run stripp on a few and see if their size
> > changes.
>
> I just booted with my LFS system.
>
> file /bin/ed
>
> gives:
>
> /bin/ed: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), for
> GNU/Linux 2.0.
> 0, dynamically linked (uses shared libs), not stripped
>
> file * | grep ', stripped'
>
> is not empty... so a lot of the files ARE indeed stripped.

Keep in mind there are several type of symbols. You have only stripped
debugging symbols. Other parameters to strip include --strip-all and
--strip-unneeded. What I'm saying is that they may have stripped OK, but
there are other types of symbols that --strip-debug does not touch.

And, be cautious if you the other strip parameters on shared libraries.
Results were not always favorable in earlier 2.4-based stuff I used.
Maybe its OK now.

>
> >
> > > Does this have to do with my host system (Red Hat 8.0) or are only files
> > > mentioned of which the debug symbols cannot be stripped?
> >
> > IIRC, it only gives warnings about those it knows it can not strip.
>
> Maybe not? :?

Why not try a little experiment? recompile ed, copy it to /tmp and then
run different types of strip on it. I'm thinking that it will not show
stripped untill either a --strip-all or maybe a --strip-unneeded is
used.

> Matijs

-- 
Bill Maltby
lfsbill at wlmcs.com

-- 
Unsubscribe: send email to listar at linuxfromscratch.org
and put 'unsubscribe lfs-support' in the subject header of the message



More information about the lfs-support mailing list