Prefer to use the standard `BUILD_SHARED_LIBS` option to control the
library type that we are building. Build a single instance of the
library. This allows for better control of the library usage in a larger
project. See the following blog post for the recommendation:
https://alexreinking.com/blog/building-a-dual-shared-and-static-library-with-cmake.html