summaryrefslogtreecommitdiffstats
path: root/Help/command/message.rst
blob: 2b4b1aa0dedcc7276ac580dd187e8381001f470e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
message
-------

Display a message to the user.

.. code-block:: cmake

  message([<mode>] "message to display" ...)

The optional ``<mode>`` keyword determines the type of message:

::

  (none)         = Important information
  STATUS         = Incidental information
  WARNING        = CMake Warning, continue processing
  AUTHOR_WARNING = CMake Warning (dev), continue processing
  SEND_ERROR     = CMake Error, continue processing,
                                but skip generation
  FATAL_ERROR    = CMake Error, stop processing and generation
  DEPRECATION    = CMake Deprecation Error or Warning if variable
                   CMAKE_ERROR_DEPRECATED or CMAKE_WARN_DEPRECATED
                   is enabled, respectively, else no message.

The CMake command-line tool displays STATUS messages on stdout and all
other message types on stderr.  The CMake GUI displays all messages in
its log area.  The interactive dialogs (ccmake and CMakeSetup) show
STATUS messages one at a time on a status line and other messages in
interactive pop-up boxes.

CMake Warning and Error message text displays using a simple markup
language.  Non-indented text is formatted in line-wrapped paragraphs
delimited by newlines.  Indented text is considered pre-formatted.