Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Hi. Yes, I now solved the problem by building OpenCV 3.0 from source. I never had to rebuild a library because of switching to a newer version of gcc.

Hi. Yes, I now solved the problem by building OpenCV 3.0 from source. I never had to rebuild a library because of switching to a newer version of gcc.

After reading a bit I assume the reason is that with GCC 5.2.0 a new ABI is activated by default.

From the GCC release notes:

The old ABI is still supported and can be used by defining the macro _GLIBCXX_USE_CXX11_ABI to 0 before including any C++ standard library headers.

So maybe that will be of help to someone else.

I now solved the problem by building OpenCV 3.0 from source. I never had to rebuild a library because of switching to a newer version of gcc.

After reading a bit I assume the reason is that with GCC 5.2.0 a new ABI is activated by default.

From the GCC release notes:

If you get linker errors about undefined references to symbols that involve types in the std::__cxx11 namespace or the tag [abi:cxx11] then it probably indicates that you are trying to link together object files that were compiled with different values for the _GLIBCXX_USE_CXX11_ABI macro. This commonly happens when linking to a third-party library that was compiled with an older version of GCC. If the third-party library cannot be rebuilt with the new ABI then you will need to recompile your code with the old ABI.

Switching to the old ABI works like this:

The old ABI is still supported and can be used by defining the macro _GLIBCXX_USE_CXX11_ABI to 0 before including any C++ standard library headers.

So maybe that will be of help to someone else.