Skip to content

Conversation

@plusk01
Copy link

@plusk01 plusk01 commented Feb 17, 2021

CMake touch ups for portability with MSVC (gross, I know).

  • BOOST_ALL_NO_LIB fixes weird dynamic vs static linking issues (see this and this)
  • By omitting SHARED in add_library, the user gains control via the BUILD_SHARED_LIBS option.
  • since <boost/asio.hpp> and <boost/function.hpp> are included in the public interface, boost includes need to be public, not private (could use PIMPL or maybe forward decl + pointers, but refactor didn't seem worth it)

I wanted the static lib option because building DLLs is a pain. tl;dr GCC exports all symbols by default, MSVC does not. Thought about adding the infrastructure to handle this, but didn't seem worth it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant