[ECOS] __dso_handle, __cxa_atexit undefined

Andrew Lunn andrew@lunn.ch
Tue Feb 8 08:25:00 GMT 2005


On Mon, Feb 07, 2005 at 11:08:50PM +0100, Armin Steinhoff wrote:
> Andrew Lunn <andrew@lunn.ch> schrieb am 07.02.2005 15:50:53:
> 
> [ clip ..]
> > > I'm using Linux SUSE 9.0 / gcc 3.3.1  ... is this the root of the problem??
> > 
> > Yes, that will probably be the problem. Are you trying to use the
> > synthetic target or are you compiling for an x86 platform? 
> 
> I tried to compile the PC platform.
> 
> > Try using  anoncvs which should work for synth and gcc 3.3.1.
> 
> I downloaded that version ... but got the same problem.

That is strange. I've been using different 3.3.x versions for the last
year. I currently have 3.3.5 and that works with anoncvs with no
problems. 

Are you realy sure you have anoncvs? Take a look at 
packages/hal/synth/arch/current/src/synth_entry.c
around line 180 you should find:

#if (__GNUC__ >= 3)
// Versions of gcc/g++ after 3.0 (approx.), when configured for Linux
// native development (specifically, --with-__cxa_enable), have
// additional dependencies related to the destructors for static
// objects. When compiling C++ code with static objects the compiler
// inserts a call to __cxa_atexit() with __dso_handle as one of the
// arguments. __cxa_atexit() would normally be provided by glibc, and
// __dso_handle is part of crtstuff.c. Synthetic target applications
// are linked rather differently, so either a differently-configured
// compiler is needed or dummy versions of these symbols should be
// provided. If these symbols are not actually used then providing
// them is still harmless, linker garbage collection will remove them.

void
__cxa_atexit(void (*arg1)(void*), void* arg2, void* arg3)
{
}
void*   __dso_handle = (void*) &__dso_handle;

> I also missed the graphical configuration tool in that version.

The 2.0 version should work fine with anoncvs.

        Andrew

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss



More information about the Ecos-discuss mailing list