CMake: suppress ALL warnings

Viewed 4322

I am trying to do something extremely simple:

I have to work on a C++ project that raises a lot of compilation warnings. Temporarily, I want to only see errors when I run make. What do I need to add to my CMakeLists.txt to make that happen? The simpler, the better.

1 Answers

It turns out the answer was to simply add the line

add_definitions(-w)

To CMakeLists.txt

It took me a lot longer than it should have to find this simple answer.

Related