From 312f39020be6c0f1825837b2b209a87d1f861132 Mon Sep 17 00:00:00 2001 From: Vincenzo Eduardo Padulano Date: Mon, 13 May 2024 15:49:01 +0200 Subject: [PATCH] Comply with CMP0148 See https://cmake.org/cmake/help/latest/policy/CMP0148.html --- CMakeLists.txt | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index cc816bf4b2..d783a22003 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -107,14 +107,7 @@ if( CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR ) set( CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib${LLVM_LIBDIR_SUFFIX} ) if(LLVM_INCLUDE_TESTS) - set(Python_ADDITIONAL_VERSIONS 2.7) - include(FindPythonInterp) - if(NOT PYTHONINTERP_FOUND) - message(FATAL_ERROR -"Unable to find Python interpreter, required for builds and testing. - -Please install Python or specify the Python3_EXECUTABLE CMake variable.") - endif() + find_package(Python3 3.8 REQUIRED COMPONENTS Interpreter) # Check prebuilt llvm/utils. if(EXISTS ${LLVM_TOOLS_BINARY_DIR}/FileCheck${CMAKE_EXECUTABLE_SUFFIX}