[uClibc]cvs commit to uClibc/stdlib by andersen

Manuel Novoa III mnovoa3 at bellsouth.net
Sat Feb 10 16:37:32 UTC 2001


On Fri, 09 Feb 2001, Erik Andersen wrote:
> > > Revert stdio to initializing itself.  Not quite a pretty but that ensures that
> >  ...
> > I know this is the safe way, but I really dislike the added overhead.  :-(
> 
> I knew you wouldn't like it <my appologies>.  But it just had to be done all
> the same -- stuffing all this junk into the start code wasn't maintainable

Yes... maintaining all the different crt0.S files was not desireable.

> > What about having crt0 call something like __uClibc_main instead of main, where
> > ...
> Yes.  I do like this approach very much.  I wish I'd thought of it! This allows
> us to put back the sneaky initialization stuff, without having to encumber the
> crt0 asm with piles of complicated junk to avoid trashing registers and not
> blow the stack.  I dont see the need for an alternate crt0.S -- if we use weak
> symbols then in the best case this function reduces to just a few extra
> instructions of start code.  That I can live with, considering the benefits.  
> 
> Lets proceed with doing this.

Fine.  I'll take care of that today after I whip the last bit of busybox stuff
I've been playing with into shape for posting.  I've managed to shave about
2.5k off the (full build) executable size with the usage-message stuff by
combining the idea I had before I left (combining the usage messages into one
long buffer and using offsets to remove all the unneeded global symbols) and
removing the redundant applet names from the start of each usage string (since
they're already stored in the applet list).  Then I converted the usage(char *)
calls to usage_from_applet_number(int i) calls.  I think I can get it in a
maintainable form that you can live with.

Manuel





More information about the uClibc mailing list