1 # MACRO_ENSURE_OUT_OF_SOURCE_BUILD(<errorMessage>)
3 macro( MACRO_ENSURE_OUT_OF_SOURCE_BUILD _errorMessage )
5 string( COMPARE EQUAL "${CMAKE_SOURCE_DIR}" "${CMAKE_BINARY_DIR}" _insource )
7 message( SEND_ERROR "${_errorMessage}" )
9 "In-source builds are not allowed.
10 CMake would overwrite the makefiles distributed with libcxxabi.
11 Please create a directory and run cmake from there, passing the path
12 to this source directory as the last argument.
13 This process created the file `CMakeCache.txt' and the directory `CMakeFiles'.
18 endmacro( MACRO_ENSURE_OUT_OF_SOURCE_BUILD )