avr-gcc-list
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avr-gcc-list] [Fwd: building gcc/g++]


From: reinhard . jessich
Subject: Re: [avr-gcc-list] [Fwd: building gcc/g++]
Date: Tue, 8 Jan 2002 00:32:20 +0100

On Mon, 07 Jan 2002, Peter Jansen wrote:
> Hi,
> 
> 
> > Is this really necessary?
> > I have patched the makefiles, so that libiberty and libstdc++ isn't build.
> > Then I have patched gcc, so that it not requires libc++.
> > Was this the wrong approach?
> 
> 
> That approach is ok I preferred to keep the mods to a minimum and I 
> needed g++ so had to get it to compile.
I did a little mistake with my patches. Now I can build avr-g++ without having
to deal with newlib and libstdc++. They are simply not build.
The patches are for gcc-3.0.2. Attached you will find them. I think they can
be sent to the gcc team, but I haven't done it until now, because of the
following problem.

After writing a small c++ test program, simulating it in simulavr and analysing
the generated asm file, I discovered that nobody is calling the
con/destructors of global variables.

I have found the __CTOR_LIST__ in the asm output.

Is anybody working on a solution of this problem?
I am not so familar with gcc, that I can quickly implement this.
I have started to analyse how the m68hc11 port does this. I think it can be
used as a pattern. Currently I am not sure if we need to change gcrt1.S from
libc. I think it is possible to configure gcc, that it will emit the needed
calls to the functions to walk through the list of con/destructors.
The next problem is, that I am not familar with the avr assembler. I need to
learn it.

> >>I have posted patches for the ATmega128 for the above sources if you 
> >>want ATmega128 support. Some of this support is already built into the 
> >>CVS trees for gcc, binutils already for those who like like on the edge.
Maybe you can send me the patches. Then I will integrae them into my build
script.

Regards,
   Reinhard

-- 
 Ing. Reinhard Jessich              mailto: address@hidden
 A-1190 Vienna, Goergengasse 2/2/1  phone: +43/1/3692600
 http://members.telering.at/jessich mobile: +43/664/1735439

Attachment: gcc-patch
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]