diff --git a/CMakeLists.txt b/CMakeLists.txt
index ef226f3ebef418953eb543a3f133c6e4fd8d08f6..63a8c910fe8568e151b99b4a067c9fd895ab7da9 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -76,8 +76,13 @@ if(BA_APPLE_BUNDLE AND NOT APPLE)
     message(FATAL_ERROR "BA_APPLE_BUNDLE=ON although hardware is not APPLE")
 endif()
 
-if(BA_TIDY AND BORNAGAIN_PYTHON)
-    message(FATAL_ERROR "BA_TIDY is incompatible with BORNAGAIN_PYTHON")
+if(BA_TIDY)
+    if (BORNAGAIN_PYTHON)
+        message(FATAL_ERROR "BA_TIDY is incompatible with BORNAGAIN_PYTHON")
+    endif()
+    if(NOT CMAKE_CXX_COMPILER_ID MATCHES "Clang")
+        message(FATAL_ERROR "BA_TIDY requires compiler Clang")
+    endif()
 endif()
 
 if(BA_GUI AND NOT BORNAGAIN_PYTHON AND NOT BA_TIDY)