[Mlir-commits] [mlir] 3539813 - [MLIR] Removes CMake work-arounds.

Mark de Wever llvmlistbot at llvm.org
Wed Jun 7 08:47:16 PDT 2023


Author: Mark de Wever
Date: 2023-06-07T17:47:10+02:00
New Revision: 3539813f987032577807b251b7ad419789a30d0a

URL: https://github.com/llvm/llvm-project/commit/3539813f987032577807b251b7ad419789a30d0a
DIFF: https://github.com/llvm/llvm-project/commit/3539813f987032577807b251b7ad419789a30d0a.diff

LOG: [MLIR] Removes CMake work-arounds.

CMake older than 3.20.0 is no longer supported.
This removes work-arounds for no longer supported versions.

Reviewed By: mehdi_amini

Differential Revision: https://reviews.llvm.org/D152101

Added: 
    

Modified: 
    mlir/cmake/modules/MLIRDetectPythonEnv.cmake
    mlir/tools/mlir-vulkan-runner/CMakeLists.txt

Removed: 
    


################################################################################
diff  --git a/mlir/cmake/modules/MLIRDetectPythonEnv.cmake b/mlir/cmake/modules/MLIRDetectPythonEnv.cmake
index 71b2ab9fb41e1..0a486c1bbb549 100644
--- a/mlir/cmake/modules/MLIRDetectPythonEnv.cmake
+++ b/mlir/cmake/modules/MLIRDetectPythonEnv.cmake
@@ -2,13 +2,6 @@
 
 # Finds and configures python packages needed to build MLIR Python bindings.
 macro(mlir_configure_python_dev_packages)
-  if(CMAKE_VERSION VERSION_LESS "3.19.0")
-  message(SEND_ERROR
-      "Building MLIR Python bindings is known to rely on CMake features "
-      "that require at least version 3.19. Recommend upgrading to 3.19+ "
-      "for full support. Detected current version: ${CMAKE_VERSION}")
-  endif()
-
   if(MLIR_DETECT_PYTHON_ENV_PRIME_SEARCH)
     # Prime the search for python to see if there is a full development
     # package. This seems to work around cmake bugs searching only for

diff  --git a/mlir/tools/mlir-vulkan-runner/CMakeLists.txt b/mlir/tools/mlir-vulkan-runner/CMakeLists.txt
index c495a359da714..e4bd9e4121e08 100644
--- a/mlir/tools/mlir-vulkan-runner/CMakeLists.txt
+++ b/mlir/tools/mlir-vulkan-runner/CMakeLists.txt
@@ -8,16 +8,12 @@ set(LLVM_OPTIONAL_SOURCES
 if (MLIR_ENABLE_VULKAN_RUNNER)
   message(STATUS "Building the Vulkan runner")
 
-  # At first try "FindVulkan" from:
-  # https://cmake.org/cmake/help/v3.7/module/FindVulkan.html
-  if (NOT CMAKE_VERSION VERSION_LESS 3.7.0)
-    find_package(Vulkan)
-  endif()
+  find_package(Vulkan)
 
   # If Vulkan is not found try a path specified by VULKAN_SDK.
   if (NOT Vulkan_FOUND)
     if ("$ENV{VULKAN_SDK}" STREQUAL "")
-      message(FATAL_ERROR "Please use at least CMAKE 3.7.0 or provide "
+      message(FATAL_ERROR "Vulkan not found through CMake; please provide "
                           "VULKAN_SDK path as an environment variable")
     endif()
 


        


More information about the Mlir-commits mailing list