Hi I'm facing the same issue. Adding "-I${Protobuf_INCLUDE_DIRS}" to the CMAKE_CXX_CPPCHECK bypass this error, but then it fails like this: /usr/local/include/google/protobuf/stubs/port.h:123:0: error: #error "Protobuf requires at least C++11." [preprocessorErrorDirective] #error "Protobuf requires at least C++11." The error happens even though I'm using C++14, very likely because the cplusplus macro is not received by cppcheck.