I suspect this is a C++ ABI issue. The ABI for std::string
has changed in GCC 5 (related to C++11 requirements, but it applies even if you aren’t using C++11). See:
https://gcc.gnu.org/gcc-5/changes.html#libstdcxx
If libprotobuf was built with GCC 4.x or prior, but your app is built with GCC 5, then you will see problems, because libprotobuf uses std::string
in its interface. You have two options:
- Rebuild libprotobuf with GCC 5 (but now any apps built with GCC 4 won’t work with the new version of libprotobuf).
- Build you app with
-D_GLIBCXX_USE_CXX11_ABI=0
as described at the above link. This will force GCC to use the old ABI version.