[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [avr-gcc-list] c++ new/delete and __gxx_personality_sj0 missing
From: |
Kujala Matti |
Subject: |
Re: [avr-gcc-list] c++ new/delete and __gxx_personality_sj0 missing |
Date: |
Wed, 21 Aug 2002 12:55:18 +0300 (EET DST) |
> Hi all,
>
> I play arround a bit with c++. All works fine but creating
> objects with new give me the following error during link stage:
>
> /tmp/ccyIPIkZ.o: In function `main':
> /tmp/ccyIPIkZ.o(.text+0x8): undefined reference to `__gxx_personality_sj0'
> /tmp/ccyIPIkZ.o(.text+0xa): undefined reference to `__gxx_personality_sj0'
> /tmp/ccyIPIkZ.o(.text+0x44): undefined reference to `operator new(unsigned)'
> /tmp/ccyIPIkZ.o(.text+0xc8): undefined reference to `operator delete(void*)'
>
> the operators new/delete can be replaced by:
> void * operator new(unsigned int s) {
> return malloc(s);
> }
>
> void operator delete(void *m) {
> free(m);
> }
>
> Any reason to do this not this simple way?
I think that constructors and destructors are not called.
--
What sorcery, what spells, have brought thee here?
avr-gcc-list at http://avr1.org