diff --git a/flang/CMakeLists.txt b/flang/CMakeLists.txt --- a/flang/CMakeLists.txt +++ b/flang/CMakeLists.txt @@ -127,6 +127,10 @@ endif() else() + if(NOT "mlir" IN_LIST LLVM_ENABLE_PROJECTS) + message(FATAL_ERROR "'mlir' is required in LLVM_ENABLE_PROJECTS to build flang") + endif() + option(FLANG_INCLUDE_TESTS "Generate build targets for the Flang unit tests." ${LLVM_INCLUDE_TESTS})