Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-58746

Build failure on macOS 10.12; mongodb 5.0.0 requires macOS 10.13+?

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 5.0.2, 5.1.0-rc0
    • Affects Version/s: 5.0.0
    • Component/s: None
    • None
    • Fully Compatible
    • ALL
    • v5.0
    • Dev Platform 2021-07-26

      SConstruct currently enforces a requirement of macOS 10.12 or later:

      https://github.com/mongodb/mongo/blob/master/SConstruct#L2853-L2881

      In fact, mongodb 5.0.0 appears to require macOS 10.13 or later; trying to compile on macOS 10.12 fails. There are many errors, beginning with:

      src/mongo/logv2/plain_formatter.cpp:127:21: error: 'any_cast<const std::__1::basic_string<char> &>' is unavailable: introduced in macOS 10.13
       return std::any_cast<const T&>(_storage.emplace_back(std::forward<T>(val)));
       ^
      src/mongo/logv2/plain_formatter.cpp:122:31: note: in instantiation of function template specialization 'mongo::logv2::(anonymous namespace)::TextValueExtractor::_store<std::__1::basic_string<char> >' requested here
       _add(name, StringData{_store(std::move(val))});
       ^
      /opt/local/libexec/llvm-9.0/bin/../include/c++/v1/any:596:12: note: 'any_cast<const std::__1::basic_string<char> &>' has been explicitly marked unavailable here
      _ValueType any_cast(any & __v)
       ^
      

      Here is the full build log:

      https://build.macports.org/builders/ports-10.12_x86_64-builder/builds/153834/steps/install-port/logs/stdio

      If you can continue to support macOS 10.12 that would be great. If not, you could update SConstruct to error out on macOS 10.12.

            Assignee:
            ryan.egesdahl@mongodb.com Ryan Egesdahl (Inactive)
            Reporter:
            ryandesign Ryan Schmidt
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: