0

The documentation for the cmake_minimum_required command says:

The FATAL_ERROR option is accepted but ignored by CMake 2.6 and higher. 
It should be specified so CMake versions 2.4 and lower fail with an error 
instead of just a warning.   

But, it doesn't say what the valid options are for FATAL_ERROR - am I missing something blindingly obvious?

ChrisW
  • 4,970
  • 7
  • 55
  • 92
  • http://stackoverflow.com/questions/5403636/cause-cmake-to-generate-an-error – Kyle Kanos Jun 07 '13 at 16:59
  • @KyleKanos Can you explain what the `FATAL_ERROR` option in `cmake_minimum_required` should be? A string? How do the arguments of `message` relate to those of `cmake_minimum_required`? – ChrisW Jun 07 '13 at 17:23
  • FATAL_ERROR is not _an_ option, it **is** the option. – Kyle Kanos Jun 07 '13 at 17:39

1 Answers1

0

There are no additional arguments required for FATAL_ERROR in the context of cmake_minimum_required.

You use it like this:

cmake_minimum_required(VERSION 2.8 FATAL_ERROR)

or

cmake_minimum_required(VERSION 2.8.11.1 FATAL_ERROR)

In the context of message, you do pass an additional argument:

message(FATAL_ERROR "My message...")
Fraser
  • 74,704
  • 20
  • 238
  • 215