diff --git a/hipify-clang/CMakeLists.txt b/hipify-clang/CMakeLists.txt index 6e3f4e80de..4c6dc8aec8 100644 --- a/hipify-clang/CMakeLists.txt +++ b/hipify-clang/CMakeLists.txt @@ -66,14 +66,7 @@ install(TARGETS hipify-clang DESTINATION bin) if (HIPIFY_CLANG_TESTS) # 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.\n\n" - "Please install Python or specify the PYTHON_EXECUTABLE CMake variable.") - endif() - + find_package(PythonInterp 2.7 REQUIRED EXACT) find_program(LIT_COMMAND lit) set(BINARY_DIR ${CMAKE_CURRENT_BINARY_DIR})