Skip to content

Commit a1b35e8

Browse files
authored
Bump CMake requirement to 3.29 (#12556)
### Summary Update the CMake version requirement to 3.29. This is in response to XNNPACK implicitly requiring it. Note that it should be sufficient to update the dependency only at the top-level CMake (as opposed to all of the separate locations where the version in specified). Fixes #12524. See the issue for more context. ### Test plan I've built locally to verify that it builds correctly. CI will also help validate. I also attempted to build with an older CMake version (3.28), and observed the following error: ``` CMake Error at CMakeLists.txt:50 (cmake_minimum_required): CMake 3.29 or higher is required. You are running version 3.28.0 ``` Previously, it would error out with: ``` CMake Error at CMakeLists.txt:18 (CMAKE_POLICY): Policy "CMP0156" is not known to this version of CMake. ```
1 parent 4500419 commit a1b35e8

File tree

3 files changed

+5
-3
lines changed

3 files changed

+5
-3
lines changed

CMakeLists.txt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,9 @@
4545
# ~~~
4646
#
4747

48-
cmake_minimum_required(VERSION 3.24)
48+
# TODO Lower to 3.24 when XNNPACK dependency is updated to include
49+
# https://github.com/google/XNNPACK/commit/c690daa67f883e1b627aadf7684c06797e9a0684
50+
cmake_minimum_required(VERSION 3.29)
4951
project(executorch)
5052

5153
include(${PROJECT_SOURCE_DIR}/tools/cmake/common/preset.cmake)

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[build-system]
22
requires = [
3-
"cmake<4.0.0", # For building binary targets in the wheel. 4.0.0 breaks third-party CMake build so temporarily pin the version.
3+
"cmake>=3.29,<4.0.0", # For building binary targets in the wheel. 4.0.0 breaks third-party CMake build so temporarily pin the version.
44
"pip>=23", # For building the pip package.
55
"pyyaml", # Imported by the kernel codegen tools.
66
"setuptools>=63", # For building the pip package contents.

requirements-dev.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Pip packages needed to build from source. Mainly for development of ExecuTorch.
22

3-
cmake>=3.19, <4.0.0 # For building binary targets in the wheel.
3+
cmake>=3.29, <4.0.0 # For building binary targets in the wheel.
44
pip>=23 # For building the pip package.
55
pyyaml # Imported by the kernel codegen tools.
66
setuptools>=63 # For building the pip package contents.

0 commit comments

Comments
 (0)