Modify dev warning options to affect deprecated warnings.

Change the '-Wdev' and '-Wno-dev' options to also enable and
suppress the deprecated warnings output, via the
'CMAKE_WARN_DEPRECATED' CMake variable, by default. This
action does not happen if the user specifies a deprecated
warning message option.

Add tests and update the documentation for the new
functionality.
This commit is contained in:
Michael Scott
2015-11-08 23:34:59 +00:00
committed by Brad King
parent b146747ed7
commit e8974b62d7
4 changed files with 45 additions and 2 deletions

View File

@@ -77,13 +77,14 @@
Suppress developer warnings.
Suppress warnings that are meant for the author of the
CMakeLists.txt files.
CMakeLists.txt files. By default this will also turn off
deprecation warnings.
``-Wdev``
Enable developer warnings.
Enable warnings that are meant for the author of the CMakeLists.txt
files.
files. By default this will also turn on deprecation warnings.
``-Wdeprecated``
Enable deprecated functionality warnings.

View File

@@ -3,3 +3,6 @@ cmake-W-options
* The :variable:`CMAKE_WARN_DEPRECATED` variable can now be set using the
``-Wdeprecated`` and ``-Wno-deprecated`` :manual:`cmake(1)` options.
* The ``-Wdev`` and ``-Wno-dev`` :manual:`cmake(1)` options now also enable
and suppress the deprecated warnings output by default.