[OE-core] boost 1.56 compile fail

Yi Qingliang niqingliang2003 at gmail.com
Fri Aug 29 11:36:22 UTC 2014


and use 'gcc_atomic' in platform.hpp just for 4.8.x 4.9.x,


#if ((defined(__GNUC__) && ((__GNUC__ * 100 + __GNUC_MINOR__) >= 407))

I don't know why low version gcc can do the lock free atomic operation, but
high version can't


On Fri, Aug 29, 2014 at 11:28 AM, Yi Qingliang <niqingliang2003 at gmail.com>
wrote:

> hardware: samsung s3c6410
>
> after updated to latest poky, the boost compile fail!
>
> error info:
> libs/atomic/src/lockpool.cpp:127:5: error: 'thread_fence' is not a member
> of 'boost::atomics::detail'
> libs/atomic/src/lockpool.cpp:138:5: error: 'signal_fence' is not a member
> of 'boost::atomics::detail'
>
>
> after dig into it, I found that:
> the marco 'BOOST_ATOMIC_FLAG_LOCK_FREE' is 0, so it don't include
> 'operations_lockfree.hpp' which has 'thread_fence' and 'signal_fence', but
> pthread.h at line 21.
>
> in file 'caps_gcc_atomic.hpp', 'BOOST_ATOMIC_FLAG_LOCK_FREE' is set to
> '0', the author think if '__GCC_ATOMIC_BOOL_LOCK_FREE' is 1, the atomic
> serial function gcc provided is not lock free.
>
> at the end of 'caps_gcc_atomic.hpp', it defined
> 'BOOST_ATOMIC_THREAD_FENCE' as 2.
>
> so the conflict is: *BOOST_ATOMIC_THREAD_FENCE* and
> *BOOST_ATOMIC_FLAG_LOCK_FREE*
>
> I don't know it is the new poky problem, or the boost problem, any idea?
>
>
> Yi Qingliang
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openembedded.org/pipermail/openembedded-core/attachments/20140829/993fe507/attachment-0002.html>


More information about the Openembedded-core mailing list