This is the mail archive of the crossgcc@sources.redhat.com mailing list for the crossgcc project.
See the CrossGCC FAQ for lots more information.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
Other format: | [Raw text] |
I compiled the test with the regular libc.a which is compiled with newlib. I think it uses the Angel monitor functions. It looks like the _exit calls do_global_dtors etc, and eventually cleanup_r which calles fflush, after which the printf output occurs. Since I have no debug monitors, and I use coff object, what should I put in my _exit function. Is there some specific function that must be called so that I exit gracefully. Thanks Vish > > > From: Bill Gatliff <bgat@billgatliff.com> > Date: 2004/01/25 Sun PM 11:02:30 EST > To: vishu27@cox.net > CC: crossgcc@sources.redhat.com > Subject: Re: newlib and libgloss questions > > Vish: > > > At times I have rebuilt the stock newlib, after modifying the sources to > make the syscalls "weak". Add __attribute__((weak)) to the function > definitions in the newlib sources (see the gcc manual for more info). > > By doing that, you can override newlib's function definitions with your > own without modifying anything else, simply include your definition, and > the linker will take yours over newlib's. > > I have suggested that the newlib maintainers make all of newlib's > functions weak in in the next release of newlib, but there hasn't been a > release since my suggestion. :^) > > > b.g. > > > > vishu27@cox.net wrote: > > >If I am to provide my own crt0.S and syscalls for newlib libc, should I recompile newlib by replacing the crt0.S and syscalls in newlib/sys/arm directory? Or is there a way to override the syscalls already compiled into libc. I thought that the *startupfiles in the specs file would do the job. > > > >Thanks > >Vish > > > > > > > > > >>From: "Anton Erasmus" <antera@intekom.co.za> > >>Date: 2004/01/25 Sun AM 03:55:15 EST > >>To: crossgcc@sources.redhat.com > >>Subject: Re: newlib and libgloss questions > >> > >> > >>On 2004/01/23 at 06:45 vishu27@cox.net wrote: > >> > >> > >> > >>>Hi, > >>> I am trying to run C++ programs on an OS less system. I have an already > >>>prebuild gnupro tools. I have written a crt0.S and a syscalls.c which > >>>impelment _write , _read, _sbrk and a list of other calls which are given > >>>in the gnupro documentation. > >>> > >>> > >>[Stuff Snipped] > >> > >> > >>Hi, > >> > >>You might try the > >>-nostartfiles > >>-nodefaultlibs > >>-nostdlib > >>options of gcc. > >> > >>I have found these easier to use than stuffing around with spec files etc. > >> > >> > >>Regards > >> Anton Erasmus > >> > >> > >>------ > >>Want more information? See the CrossGCC FAQ, http://www.objsw.com/CrossGCC/ > >>Want to unsubscribe? Send a note to crossgcc-unsubscribe@sources.redhat.com > >> > >> > >> > >> > > > > > >------ > >Want more information? See the CrossGCC FAQ, http://www.objsw.com/CrossGCC/ > >Want to unsubscribe? Send a note to crossgcc-unsubscribe@sources.redhat.com > > > > > > > > -- > Bill Gatliff > Embedded GNU development and training services. > bgat@billgatliff.com > > > ------ Want more information? See the CrossGCC FAQ, http://www.objsw.com/CrossGCC/ Want to unsubscribe? Send a note to crossgcc-unsubscribe@sources.redhat.com
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |