Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

libprotobuf check failed while executing program on mac os

I have a project that uses protocol buffers and it works fine on linux and windows but on mac os I am getting following error while running the program. I confirmed I am using the correct libraries. I used brew install protobuf to install protocol buffers.

Generated the files using proper protoc and compiled and compilation succeed without any issues.

Version of library is libprotoc 3.11.3

[libprotobuf FATAL google/protobuf/generated_message_util.cc:812] CHECK failed: (scc->visit_status.load(std::memory_order_relaxed)) == (SCCInfoBase::kRunning): libc++abi.dylib: terminating with uncaught exception of type google::protobuf::FatalException: CHECK failed: (scc->visit_status.load(std::memory_order_relaxed)) == (SCCInfoBase::kRunning):

like image 251
sarbjit singh Avatar asked Mar 09 '26 16:03

sarbjit singh


1 Answers

Maybe you could try to add -lpthread when you compile with g++.

like image 178
zeno Zhang Avatar answered Mar 11 '26 07:03

zeno Zhang



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!