diff options
-rw-r--r-- | cmake/Modules/MacroOutOfSourceBuild.cmake | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/cmake/Modules/MacroOutOfSourceBuild.cmake b/cmake/Modules/MacroOutOfSourceBuild.cmake index dedeef352..71a8ca4cc 100644 --- a/cmake/Modules/MacroOutOfSourceBuild.cmake +++ b/cmake/Modules/MacroOutOfSourceBuild.cmake @@ -24,10 +24,7 @@ # # Ensures that we do an out of source build MACRO(MACRO_ENSURE_OUT_OF_SOURCE_BUILD MSG) STRING(COMPARE EQUAL "${CMAKE_SOURCE_DIR}" "${CMAKE_BINARY_DIR}" insource) - GET_FILENAME_COMPONENT(PARENTDIR ${CMAKE_SOURCE_DIR} PATH) - STRING(COMPARE EQUAL "${CMAKE_SOURCE_DIR}" "${PARENTDIR}" insourcesubdir) - MESSAGE( "${CMAKE_SOURCE_DIR} , ${CMAKE_BINARY_DIR}, ${PARENTDIR}") - IF(insource OR insourcesubdir) + IF(insource) MESSAGE(FATAL_ERROR "${MSG}") - ENDIF(insource OR insourcesubdir) + ENDIF() ENDMACRO(MACRO_ENSURE_OUT_OF_SOURCE_BUILD)
\ No newline at end of file |