Open hakonhagland opened 3 years ago
Added a quick fix that seems to work for me. See PR #3201.
I am not able to tell which file is including
<boost/bind.hpp>
, according to the compiler output above it should be/usr/include/boost/smart_ptr/detail/sp_thread_sleep.hpp
but that file does not have any line#include <boost/bind.hpp>
as far as I can see. Any ideas which file triggered the warning?
It may be boost/property_tree/json_parser.hpp
in opm/simulators/linalg/ISTLSolverEbosFlexible.hpp
. In Boost 1.74, json_parser.hpp
goes on to include boost/property_tree/json_parser/detail/parser.hpp
which in turn directly includes <boost/bind.hpp>
. In Boost 1.76 that appears to be fixed. As for why the warning appears to be triggered in sp_thread_sleep.hpp
, I'd venture a guess that that's the first location that happens to define the BOOST_PRAGMA_MESSAGE
macro (through including <boost/config/pragma_message.hpp>
) in the pertinent translation unit and that the compiler is unable to distinguish between the macro definition and the actual call and therefore attributes the failure to the definition instead.
I am trying to get rid of some warnings when building
opm-simulators
on Ubuntu 21.04 with gcc 10.3.0, boost version 1.74.0 :I am not able to tell which file is including
<boost/bind.hpp>
, according to the compiler output above it should be/usr/include/boost/smart_ptr/detail/sp_thread_sleep.hpp
but that file does not have any line#include <boost/bind.hpp>
as far as I can see. Any ideas which file triggered the warning?According to the warning message, we can define
BOOST_BIND_GLOBAL_PLACEHOLDERS
to silence the warnings.