[gccsdk] Problems running C++ programs compiled with GCC4

John Tytgat John.Tytgat at aaug.net
Wed Jul 30 14:29:53 PDT 2008


In message <30082dc74f.Jo at hobbes.bass-software.com>
          John Tytgat <John.Tytgat at aaug.net> wrote:

> In message <4890CC8E.7060903 at sky.com>
>           Lee Noar <leenoar at sky.com> wrote:
> 
> > AFAICT, ".weakref sym1, sym2" means resolve to sym2 (if available) else 
> > zero. Using "nm -n" on the binary lists pthread_once as a weak undefined 
> > symbol, so the linker isn't pulling in the definition, pthread_once 
> > isn't available and the weakref resolves to NULL.
> 
> It could be a library order issue in the linker line.  I.e. UnixLib
> coming before libstdc++.  When pthread_once has been pulled in before,
                                                 ^ not
> libstdc++ won't pull it because of this weak ref.
                         ^ in either

John.
-- 
John Tytgat, in his comfy chair at home                                 BASS
John.Tytgat at aaug.net                             ARM powered, RISC OS driven




More information about the gcc mailing list