This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

"atexit" linkage error (ARM, nostdlib, C++)


Hello folks,

I'm playing around with an evaluation-board with an ARM-CPU and wrote a
simple testing program - one main-program with main() and a class file -
which uses static C++ objects. 
I'm linking with "-nostdlib" and a matching linker-script which with
"GROUP (libgcc.a)". When linking, I get following message

  play.cxx done ...
  PIOClass.cxx done ...
 
/tools/H-i686-pc-linux-gnu/lib/gcc-lib/arm-elf/2.95.2/libgcc.a(__main.o):
In function `__do_global_ctors':
__main.o(.text+0xbc): undefined reference to `atexit'
__main.o(.text+0xbc): relocation truncated to fit: R_ARM_PC24 atexit
collect2: ld returned 1 exit status
make: *** [link] Error 1

So I'm a little bit confused, what's missing?

Thanks in advance. 
--------------------------------------------------
i.A. Andreas Bürgel     GenoLogic GmbH
     Software Engineer  Emil-Figge-Str. 80
                        D-44227 DORTMUND
                        Germany               
                        
     ab@genologic.de    phone  +49 (0) 231/9742683
                        fax    +49 (0) 231/9742682


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]