Subject: Re: strip command
To: None <port-arm32@NetBSD.ORG>
From: Mark Brinicombe <amb@physig4.ph.kcl.ac.uk>
List: port-arm32
Date: 07/08/1996 21:50:02
> I know. that it removes the symbols from a executable binary file.
Yep thats its job.
> But is
> it always usefull to do that?
Only to save disc space. The symbol table is not loaded when a binary is run,
it is only used with a debugger.
> Or can a "strip" cause any errors, such as
> a segmention fault or bus error
Not with normal binaries. The one binary that you should not strip is /netbsd.
This is because binaries such as ps, netstat, top etc. read the symbol table
from /netbsd to find out where various kernel variable are. Then they can read
these variables via /dev/kmem.
This also explains why you get errors for a few binaries if you boot from a
kernel other than the one in /netbsd as if the boot kernel differs then the
variables can be read from the wrong addresses.
every other binary can be stripped. In fact just about all the standard
binaries in the sets will already be stripped.
You may wonder if it is worth stripping them... It depends over 100's of
binaries it can save a lot of space, especially for X binaries etc.
Mosaic has a symbol table > 1MB for example so this is stripped first to save
disc space but also to make the set smaller reducing the download time for
folks.
Cheers,
Mark
--
Mark Brinicombe amb@physig.ph.kcl.ac.uk
Research Associate http://www.ph.kcl.ac.uk/~amb/
Department of Physics tel: 0171 873 2894
King's College London fax: 0171 873 2716