You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I got a conanfile wich demand boost/1.74.0, nothing unusual happens, it compiles and I can use it and link it.
However I get A LOT of linker warnings which look like
ld: warning: direct access in function 'boost::log::v2s_mt_posix::core::implementation::implementation()' from file '/Users/acof/.conan/data/boost/1.73.0/_/_/package/2bcd523eb799e86beac7172dddb46e02c19f269a/lib/libboost_log.a(core.o)' to global weak symbol 'boost::log::v2s_mt_posix::aux::light_function<bool (boost::log::v2s_mt_posix::attribute_value_set const&)>::impl<boost::log::v2s_mt_posix::filter::default_filter>::invoke_impl(void*, boost::log::v2s_mt_posix::attribute_value_set const&)' from file 'utils/libutils.a(logging_initialser.cpp.o)' means the weak symbol cannot be overridden at runtime. This was likely caused by different translation units being compiled with different visibility settings.
ld: warning: direct access in function 'boost::log::v2s_mt_posix::core::implementation::implementation()' from file '/Users/acof/.conan/data/boost/1.73.0/_/_/package/2bcd523eb799e86beac7172dddb46e02c19f269a/lib/libboost_log.a(core.o)' to global weak symbol 'boost::log::v2s_mt_posix::aux::light_function<bool (boost::log::v2s_mt_posix::attribute_value_set const&)>::impl<boost::log::v2s_mt_posix::filter::default_filter>::invoke_impl(void*, boost::log::v2s_mt_posix::attribute_value_set const&)' from file 'utils/libutils.a(logging_initialser.cpp.o)' means the weak symbol cannot be overridden at runtime. This was likely caused by different translation units being compiled with different visibility settings.
ld: warning: direct access in function 'boost::log::v2s_mt_posix::core::implementation::thread_data::thread_data()' from file '/Users/acof/.conan/data/boost/1.73.0/_/_/package/2bcd523eb799e86beac7172dddb46e02c19f269a/lib/libboost_log.a(core.o)' to global weak symbol 'boost::date_time::c_time::gmtime(long const*, tm*)' from file 'asio/libasio.a(asio_impl.cpp.o)' means the weak symbol cannot be overridden at runtime. This was likely caused by different translation units being compiled with different visibility settings.
ld: warning: direct access in function 'boost::log::v2s_mt_posix::core::implementation::thread_data::thread_data()' from file '/Users/acof/.conan/data/boost/1.73.0/_/_/package/2bcd523eb799e86beac7172dddb46e02c19f269a/lib/libboost_log.a(core.o)' to global weak symbol 'boost::date_time::c_time::gmtime(long const*, tm*)' from file 'asio/libasio.a(asio_impl.cpp.o)' means the weak symbol cannot be overridden at runtime. This was likely caused by different translation units being compiled with different visibility settings.
ld: warning: direct access in function 'boost::log::v2s_mt_posix::visitation_result boost::log::v2s_mt_posix::value_visitor_invoker<boost::mpl::vector2<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::basic_string<wchar_t, std::__1::char_traits<wchar_t>, std::__1::allocator<wchar_t> > >, boost::log::v2s_mt_posix::fallback_to_none>::operator()<boost::log::v2s_mt_posix::sinks::aux::anonymous::message_printer>(boost::log::v2s_mt_posix::attribute_name const&, boost::log::v2s_mt_posix::attribute_value_set const&, boost::log::v2s_mt_posix::sinks::aux::anonymous::message_printer) const' from file '/Users/acof/.conan/data/boost/1.73.0/_/_/package/2bcd523eb799e86beac7172dddb46e02c19f269a/lib/libboost_log.a(default_sink.o)' to global weak symbol 'boost::log::v2s_mt_posix::aux::type_sequence_dispatcher_base::get_callback(boost::log::v2s_mt_posix::type_dispatcher*, boost::typeindex::stl_type_index)' from file 'utils/libutils.a(logging_initialser.cpp.o)' means the weak symbol cannot be overridden at runtime. This was likely caused by different translation units being compiled with different visibility settings.
My question is, is that necessary? All other libraries got no such visibility set. When I change the visibility of MY project to -fvisibility=hidden -fvisibility-inlines-hidden, these warnings disappear.
Wouldn't it make more sense to set -fvisibility=hidden -fvisibility-inlines-hidden in the profile, so all dependencies got the same visibility?
Thx for your time!
The text was updated successfully, but these errors were encountered:
that's what I first thought too... however I can't find any information about -fvisibility=hidden being mandatory for iOS... it seems however recommended.
Package and Environment Details (include every applicable attribute)
Conan profiles
host profile
build profile
Steps to reproduce
I got a conanfile wich demand
boost/1.74.0
, nothing unusual happens, it compiles and I can use it and link it.However I get A LOT of linker warnings which look like
To summarize boost compiles with a different visibility:
This was likely caused by different translation units being compiled with different visibility settings.
. Sooo I checked therecipes/boost/all/conanfile.py
and yes there's actually a different hard-coded fvisibilty ONLY for iOS https://github.com/conan-io/conan-center-index/blame/cbef8be887845520b131e87faa441519d7144806/recipes/boost/all/conanfile.py#L643My question is, is that necessary? All other libraries got no such visibility set. When I change the visibility of MY project to
-fvisibility=hidden -fvisibility-inlines-hidden
, these warnings disappear.Wouldn't it make more sense to set
-fvisibility=hidden -fvisibility-inlines-hidden
in the profile, so all dependencies got the same visibility?Thx for your time!
The text was updated successfully, but these errors were encountered: