|
Boost Users : |
Subject: Re: [Boost-users] undefined reference to `__sync_fetch_and_add_4'
From: Peter Dimov (pdimov_at_[hidden])
Date: 2009-04-24 12:49:18
Birju Prajapati:
> g++ -m32 [...]
> /usr/local/lib32/libboost_serialization-gcc43-mt.so: undefined reference
> to `__sync_fetch_and_add_4'
This is weird. __sync_fetch_and_add is used by shared_ptr and atomic_count,
but in both places, the earlier
#elif defined( __GNUC__ ) && ( defined( __i386__ ) || defined(
__x86_64__ ) )
takes precedence, and I have verified that g++ -m32 does indeed define
__i386__.
This could be caused by an issue we've identified recently of libstdc++
standard headers using __sync_fetch_and_add as part of their reference
counted implementation of std::string and std::locale.
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net