Code issue warnings can be silenced with -Wno-xxx
options because sometimes you don't have control over the source code. But a warning telling you that a command-line option is incorrect cannot be silenced with yet another command-line option — if you can affect compiler invocation, then why not just remove the incorrect option?
This particular warning tells you that you cannot set standard to C++11 when compiling C code. To get rid of it, find where -std=c++11
is defined in the build configuration, and make sure it is only applied to C++ compilation, and not for C. For example, move it from CFLAGS
to CXXFLAGS
, or cmake's equivalent thereof.