On Sat, Aug 18, 2012 at 5:48 PM, Perry Smith <pedz...@gmail.com> wrote: > > I'm on gcc 4.5.2. I started with a fresh build tree. I'm passing in > --enable-__cxa_atexit: > > configure \ > "--with-gmp=${PUBLIC_BASE}" \ > "--with-mpfr=${PUBLIC_BASE}" \ > "--with-mpc=${PUBLIC_BASE}" \ > "--disable-nls" \ > "--enable-threads=aix" \ > "--with-libiconv-prefix=/usr" \ > "--enable-__cxa_atexit" \ <<<<< > "--enable-languages=c,c++" > > config.log confirms this: > > $ /usr/work/src/gcc-4.5.2/configure --prefix=/gsa/ausgsa/projects/r/ruby > --with-gmp=/gsa/ausgsa/projects/r/ruby > --with-mpfr=/gsa/ausgsa/projects/r/ruby > --with-mpc=/gsa/ausgsa/projects/r/ruby --disable-nls --enable-threads=aix > --with-libiconv-prefix=/usr --enable-__cxa_atexit --enable-languages=c,c++ > > But when I look at > > nm -Bx powerpc-ibm-aix6.1.0.0/pthread/libstdc++-v3/src/.libs/future.o > > There is still a reference to atexit. mt_allocator.o also has a reference to > atexit. It is coming from the destructor. > > .line 60 > bl .__cxa_guard_release > nop > lwz 3,LC..20(2) > bl .atexit > nop > > If I explicitly add the -fuse-cxa-atexit, then it uses cxa_atexit. I got the > idea (perhaps mistaken) that the config time option flipped the default.
Look closely at the output from gcc/configure. Does it include the line "__cxa_atexit can't be enabled on this target"? That will be displayed if the configure script determines that your target does not provide a __cxa_atexit function, and will override --enable-__cxa_atexit. Ian