Pete Buechler wrote:

> I put together a small Linux at oddas.sourceforge.net that fits in less than
> 4M, ...

You can compress the glibc and similar libraries and most binaries by
doing the
following

objcopy -g <filename> --remove-section=.comments --remove-section=.notes

This command will remove all of the debug info from a lib and all of the
comments
and notes from the code.  There are other sections and diffrent objcopy
arguments
that may reduce the size even more.  I was surprised as to how much this
can take
off a file's size.

The debian boot disks also use a script called "mklibs.sh" which is
based on this
idea, but takes it a little farther.  The mklibs.sh comments say "This
utility
helps to reduce the necessary libraries to only include the symbols
needed to run
a given set of executables."  It works quite well.

I decided to go with the first option because my customers wanted a full
glibc,
but both work quite well.


--
To unsubscribe from this list, send a message to [EMAIL PROTECTED]
with the command "unsubscribe linux-embedded" in the message body.
For more information, see <http://waste.org/mail/linux-embedded>.

Reply via email to