Cilk++ with Boost Library

Cilk++ with Boost Library

I am facing an issue while compiling the Cilk++ code with Boost Library.

1. The Boost Library has been installed outside /usr/include.

I used a -I option to specify the boost directory while compiling with cilk++. I am getting the following error.

/home/user/boost_1_51_0/boost/multi_array.hpp: In member function ‘boost::multi_array<T, NumDims, Allocator>& cilk boost::multi_array<T, NumDims, Allocator>::resize(const boost::detail::multi_array::extent_gen<NumDims>&) [with T = float, long unsigned int NumDims = 2ul, Allocator = std::allocator<float>]’:
kdtree2.h:95: instantiated from here
/home/user/boost_1_51_0/boost/multi_array.hpp:415: error: no matches converting function ‘min’ to type ‘const boost::multi_array_types::size_type& (cilk*)(const boost::multi_array_types::size_type&, const boost::multi_array_types::size_type&)’
/home/user/cilk/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.2.4/../../../../include/c++/4.2.4/bits/stl_algobase.h:182: error: candidates are: template<class _Tp> const _Tp& std::min(const _Tp&, const _Tp&)
/home/user/cilk/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.2.4/../../../../include/c++/4.2.4/bits/stl_algobase.h:226: error: template<class _Tp, class _Compare> const _Tp& std::min(const _Tp&, const _Tp&, _Compare)

2 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

The issue got resolved by using the -isystem option while compiling.

Login to leave a comment.