【问题标题】:libprotobuf check failed while executing program on mac os在 mac os 上执行程序时 libprotobuf 检查失败
【发布时间】:2020-02-17 03:10:12
【问题描述】:

我有一个使用协议缓冲区的项目,它在 linux 和 windows 上运行良好,但在 mac os 上运行程序时出现以下错误。我确认我使用了正确的库。我使用brew install protobuf 安装协议缓冲区。

使用正确的协议生成文件,编译和编译成功,没有任何问题。

库的版本是 libprotoc 3.11.3

[libprotobuf FATAL google/protobuf/generated_message_util.cc:812] CHECK 失败:(scc->visit_status.load(std::memory_order_relaxed)) == (SCCInfoBase::kRunning): libc++abi.dylib:以 google::protobuf::FatalException 类型的未捕获异常终止:检查失败:(scc->visit_status.load(std::memory_order_relaxed)) == (SCCInfoBase::kRunning):

【问题讨论】:

    标签: c++ compiler-errors protocol-buffers build-process protobuf-c


    【解决方案1】:

    也许你可以尝试在使用 g++ 编译时添加-lpthread

    【讨论】:

      猜你喜欢
      • 2021-03-05
      • 1970-01-01
      • 2013-11-28
      • 2018-03-22
      • 2019-12-28
      • 1970-01-01
      • 1970-01-01
      • 2013-02-12
      • 2011-12-07
      相关资源
      最近更新 更多