How to eliminate external lib/third party warnings in GCC [duplicate]
问题 This question already has answers here : How to suppress GCC warnings from library headers? (9 answers) Closed 4 years ago . In the software project I'm working on, we use certain 3rd party libraries which, sadly, produce annoying gcc warnings. We are striving to clean all code of warnings, and want to enable the treat-warnings-as-errors (-Werror) flag in GCC. Is there a way to make these 3rd party generated warnings, which we cannot fix, to disappear? 回答1: I presume you are talking about the