message: Updating mongo-c-driver version. mongo-cxx-driver stable release 3.2 has an explicit dependency upon mongo-c-driver 1.9.2. Updated db_plugin cmake to handle mongo-cxx-driver 3.2 as well as older releases.
diff: @@ -21,14 +21,30 @@ if(BUILD_MONGO_DB_PLUGIN)
  find_package(libbsoncxx REQUIRED)
  message(STATUS "Found bsoncxx headers: ${LIBBSONCXX_INCLUDE_DIRS}")
  +
  + # mongo-cxx-driver 3.2 release altered LIBBSONCXX_LIBRARIES semantics. Instead of library names,
  + # it now hold library paths.
  + if((LIBBSONCXX_VERSION_MAJOR LESS 3) OR ((LIBBSONCXX_VERSION_MAJOR EQUAL 3) AND (LIBBSONCXX_VERSION_MINOR LESS 2)))
  find_library(EOS_LIBBSONCXX ${LIBBSONCXX_LIBRARIES}
  PATHS ${LIBBSONCXX_LIBRARY_DIRS} NO_DEFAULT_PATH)
  + else()
  + set(EOS_LIBBSONCXX ${LIBBSONCXX_LIBRARIES})
  + endif()
  +
  message(STATUS "Found bsoncxx library: ${EOS_LIBBSONCXX}")
  find_package(libmongocxx REQUIRED)
  message(STATUS "Found mongocxx headers: ${LIBMONGOCXX_INCLUDE_DIRS}")
  +
  + # mongo-cxx-driver 3.2 release altered LIBBSONCXX_LIBRARIES semantics. Instead of library names,
  + # it now hold library paths.
  + if((LIBBSONCXX_VERSION_MAJOR LESS 3) OR ((LIBBSONCXX_VERSION_MAJOR EQUAL 3) AND (LIBBSONCXX_VERSION_MINOR LESS 2)))
  find_library(EOS_LIBMONGOCXX ${LIBMONGOCXX_LIBRARIES}
  PATHS ${LIBMONGOCXX_LIBRARY_DIRS} NO_DEFAULT_PATH)
  + else()
  + set(EOS_LIBMONGOCXX ${LIBMONGOCXX_LIBRARIES})
  + endif()
  +
  message(STATUS "Found mongocxx library: ${EOS_LIBMONGOCXX}")
  else()
  message("Could NOT find MongoDB. mongo_db_plugin with MongoDB support will not be included.")
  