Uploaded image for project: 'C++ Driver'
  1. C++ Driver
  2. CXX-2613

C++ driver fails to build on M1 Mac

    • Type: Icon: Task Task
    • Resolution: Gone away
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None

      Error message from build:

       

      [ 59%] Linking CXX shared library libmongocxx-mocked.dylib
      Undefined symbols for architecture arm64:
        "bsoncxx::v_noabi::builder::core::append(core::v1::basic_string_view<char, std::__1::char_traits<char> >)", referenced from:
            mongocxx::v_noabi::collection::_find(mongocxx::v_noabi::client_session const*, bsoncxx::v_noabi::view_or_value<bsoncxx::v_noabi::document::view, bsoncxx::v_noabi::document::value>, mongocxx::v_noabi::options::find const&) in collection.cpp.o
            mongocxx::v_noabi::collection::_distinct(mongocxx::v_noabi::client_session const*, bsoncxx::v_noabi::string::view_or_value, bsoncxx::v_noabi::view_or_value<bsoncxx::v_noabi::document::view, bsoncxx::v_noabi::document::value>, mongocxx::v_noabi::options::distinct const&) in collection.cpp.o
            mongocxx::v_noabi::index_view::impl::drop_one(mongocxx::v_noabi::client_session const*, core::v1::basic_string_view<char, std::__1::char_traits<char> >, mongocxx::v_noabi::options::index_view const&) in index_view.cpp.o
            mongocxx::v_noabi::options::change_stream::as_bson() const in change_stream.cpp.o
            mongocxx::v_noabi::options::index::operator bsoncxx::v_noabi::view_or_value<bsoncxx::v_noabi::document::view, bsoncxx::v_noabi::document::value>() in index.cpp.o
            bsoncxx::v_noabi::document::value bsoncxx::v_noabi::builder::basic::make_document<std::_1::tuple<char const (&) [13], bsoncxx::v_noabi::string::view_or_value const&> >(std::_1::tuple<char const (&) [13], bsoncxx::v_noabi::string::view_or_value const&>&&) in index.cpp.o
        "bsoncxx::v_noabi::builder::core::key_view(core::v1::basic_string_view<char, std::__1::char_traits<char> >)", referenced from:
            mongocxx::v_noabi::bulk_write::append(mongocxx::v_noabi::model::write const&) in bulk_write.cpp.o
            mongocxx::v_noabi::bulk_write::bulk_write(mongocxx::v_noabi::collection const&, mongocxx::v_noabi::options::bulk_write const&, mongocxx::v_noabi::client_session const*) in bulk_write.cpp.o
            mongocxx::v_noabi::client::list_database_names(bsoncxx::v_noabi::view_or_value<bsoncxx::v_noabi::document::view, bsoncxx::v_noabi::document::value>) const in client.cpp.o
            mongocxx::v_noabi::client::_watch(mongocxx::v_noabi::client_session const*, mongocxx::v_noabi::pipeline const&, mongocxx::v_noabi::options::change_stream const&) in client.cpp.o
            mongocxx::v_noabi::collection::_rename(mongocxx::v_noabi::client_session const*, bsoncxx::v_noabi::string::view_or_value, bool, core::v1::optional<mongocxx::v_noabi::write_concern> const&) in collection.cpp.o
            mongocxx::v_noabi::collection::_find(mongocxx::v_noabi::client_session const*, bsoncxx::v_noabi::view_or_value<bsoncxx::v_noabi::document::view, bsoncxx::v_noabi::document::value>, mongocxx::v_noabi::options::find const&) in collection.cpp.o
            mongocxx::v_noabi::collection::_insert_one(mongocxx::v_noabi::client_session const*, bsoncxx::v_noabi::view_or_value<bsoncxx::v_noabi::document::view, bsoncxx::v_noabi::document::value>, mongocxx::v_noabi::options::insert const&) in collection.cpp.o
            ...
        "bsoncxx::v_noabi::document::view::operator[](core::v1::basic_string_view<char, std::__1::char_traits<char> >) const", referenced from:
            mongocxx::v_noabi::collection::_insert_one(mongocxx::v_noabi::client_session const*, bsoncxx::v_noabi::view_or_value<bsoncxx::v_noabi::document::view, bsoncxx::v_noabi::document::value>, mongocxx::v_noabi::options::insert const&) in collection.cpp.o
            mongocxx::v_noabi::collection::_find_one_and_replace(mongocxx::v_noabi::client_session const*, bsoncxx::v_noabi::view_or_value<bsoncxx::v_noabi::document::view, bsoncxx::v_noabi::document::value>, bsoncxx::v_noabi::view_or_value<bsoncxx::v_noabi::document::view, bsoncxx::v_noabi::document::value>, mongocxx::v_noabi::options::find_one_and_replace const&) in collection.cpp.o
            mongocxx::v_noabi::collection::_find_one_and_update(mongocxx::v_noabi::client_session const*, bsoncxx::v_noabi::view_or_value<bsoncxx::v_noabi::document::view, bsoncxx::v_noabi::document::value>, bsoncxx::v_noabi::view_or_value<bsoncxx::v_noabi::document::view, bsoncxx::v_noabi::document::value>, mongocxx::v_noabi::options::find_one_and_update const&) in collection.cpp.o
            mongocxx::v_noabi::collection::_find_one_and_delete(mongocxx::v_noabi::client_session const*, bsoncxx::v_noabi::view_or_value<bsoncxx::v_noabi::document::view, bsoncxx::v_noabi::document::value>, mongocxx::v_noabi::options::find_one_and_delete const&) in collection.cpp.o
            mongocxx::v_noabi::collection::_insert_many_doc_handler(mongocxx::v_noabi::bulk_write&, bsoncxx::v_noabi::builder::basic::array&, bsoncxx::v_noabi::document::view) const in collection.cpp.o
            mongocxx::v_noabi::gridfs::bucket::_open_download_stream(mongocxx::v_noabi::client_session const*, bsoncxx::v_noabi::types::bson_value::view, core::v1::optional<unsigned long>, core::v1::optional<unsigned long>) in bucket.cpp.o
            mongocxx::v_noabi::gridfs::downloader::fetch_chunk() in downloader.cpp.o
            ...
        "bsoncxx::v_noabi::document::element::operator[](core::v1::basic_string_view<char, std::__1::char_traits<char> >) const", referenced from:
            mongocxx::v_noabi::result::bulk_write::upserted_ids() const in bulk_write.cpp.o
      ld: symbol(s) not found for architecture arm64
      clang: error: linker command failed with exit code 1 (use -v to see invocation)
      make[2]: *** [src/mongocxx/libmongocxx-mocked.0.0.0.dylib] Error 1
      make[1]: *** [src/mongocxx/CMakeFiles/mongocxx_mocked.dir/all] Error 2
      make: *** [all] Error 2

            Assignee:
            kyle.kloberdanz@mongodb.com Kyle Kloberdanz (Inactive)
            Reporter:
            kyle.kloberdanz@mongodb.com Kyle Kloberdanz (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: