From ec1b73be2bdeb230bc2bd6b2e0a87426a446d85c Mon Sep 17 00:00:00 2001 From: Adriaan de Groot Date: Mon, 29 Nov 2021 14:56:15 +0100 Subject: [PATCH] CMake: don't cmake in the source-directory (during development) --- CMakeLists.txt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 67bb1f319..bd4d3eb3a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -46,6 +46,9 @@ project( CALAMARES ) set( CALAMARES_VERSION_RC 1 ) # Set to 0 during release cycle, 1 during development +if( CALAMARES_VERSION_RC EQUAL 1 AND CMAKE_SOURCE_DIR STREQUAL CMAKE_BINARY_DIR ) + message( FATAL_ERROR "Do not build development versions in the source-directory." ) +endif() ### OPTIONS #