[CMake] how can I filter compiler warnings?

Kevin Burge kevin.burge at systemware.com
Fri May 7 13:50:29 EDT 2010


Yes, to suppress them completely from the build output (not just the 
warning line, but the "In file......." stuff too).  That's what our ruby 
scripts do.  We use regular expressions to match particular files that 
we don't care about.

On 05/07/2010 12:47 PM, Chuck Atkins wrote:
> What exactly do you mean by "filter"?  Do you want to suppress the 
> warnings?
>
>
> On Fri, May 7, 2010 at 1:29 PM, Kevin Burge 
> <kevin.burge at systemware.com <mailto:kevin.burge at systemware.com>> wrote:
>
>     I need to be able to filter warnings out of the compilation output
>     from specific files:
>
>     "/usr/include/pthread.h", line 990.27: 1506-450 (I) Obsolete
>     non-prototype-style function declaration.
>     "/usr/include/pthread.h", line 1049.42: 1506-450 (I) Obsolete
>     non-prototype-style function declaration.
>     "/usr/include/pthread.h", line 1050.42: 1506-450 (I) Obsolete
>     non-prototype-style function declaration
>
>     On our old build system, we replaced cc with a ruby script that
>     filtered the output.  I never did figure out the way to do this
>     with cmake.  I'd rather have cmake filter it if it can.
>
>     Please let me know if there's a way to do this.
>
>     Thank you,
>     Kevin Burge
>
>     _______________________________________________
>     Powered by www.kitware.com <http://www.kitware.com>
>
>     Visit other Kitware open-source projects at
>     http://www.kitware.com/opensource/opensource.html
>
>     Please keep messages on-topic and check the CMake FAQ at:
>     http://www.cmake.org/Wiki/CMake_FAQ
>
>     Follow this link to subscribe/unsubscribe:
>     http://www.cmake.org/mailman/listinfo/cmake
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20100507/3010e99e/attachment.htm>


More information about the CMake mailing list