Open rahulj09 opened 5 years ago
I too would like to see a fix for this. MongoDB vendors ASIO, but also builds some user facing shared libraries that should not export the ASIO symbols. To work around this, we are required to build the shared libraries with export files, rather than relying on visibility macros.
I think what you are looking for is here: https://github.com/chriskohlhoff/asio/pull/347
As of now all the symbols are exported by asio , since in
push_options.hpp
we always set symbol visibility to default i.e.https://github.com/chriskohlhoff/asio/blob/master/asio/include/asio/detail/push_options.hpp#L27We have a requirement where we don't want to export symbols from our dylib but since asio always exports symbols we are facing issues. A simple fix for it to add a pre-processor macro which clients are configure to control symbol visibility. sample code could be like
Corresponding PR is https://github.com/chriskohlhoff/asio/pull/347