Exiting CMake

Brad King brad.king at kitware.com
Tue Aug 15 17:21:34 CEST 2006


Allen Winter wrote:
> Is there a little more graceful way of exiting other than message(FATAL_ERROR "message") ??
> 
> For example, in the MACRO_DISPLAY_FEATURE_LOG() macro I want to exit if there
> are missing required features.  I want to display the messages that some requirements
> are missing and then exit.
> 
> But I don't want to panic the user with messages like:
> 
>   CMake Error: Error in cmake code at
>   /data/kde/trunk/KDE/kdepimlibs/CMakeLists.txt:1:
>   MESSAGE some message
>   Current CMake stack: /data/kde/trunk/KDE/kdepimlibs/CMakeLists.txt
> 
> I don't see a simple Quit() or Exit() type of cmake commands.

There is currently no such command but you can submit a feature request:

http://www.cmake.org/Bug

-Brad


More information about the Kde-buildsystem mailing list