diff --git a/openmp/libomptarget/CMakeLists.txt b/openmp/libomptarget/CMakeLists.txt --- a/openmp/libomptarget/CMakeLists.txt +++ b/openmp/libomptarget/CMakeLists.txt @@ -29,6 +29,11 @@ # Get dependencies for the different components of the project. include(LibomptargetGetDependencies) +# LLVM source tree is required at build time for libomptarget +if (NOT LLVM_MAIN_INCLUDE_DIR) + message(FATAL_ERROR "Missing definition for LLVM_MAIN_INCLUDE_DIR") +endif() + # This is a list of all the targets that are supported/tested right now. set (LIBOMPTARGET_ALL_TARGETS "${LIBOMPTARGET_ALL_TARGETS} aarch64-unknown-linux-gnu") set (LIBOMPTARGET_ALL_TARGETS "${LIBOMPTARGET_ALL_TARGETS} powerpc64le-ibm-linux-gnu")