[EZ] Fix typo in gcc version detection (#120489)

It should be `FATAL_ERROR` rather than `FATAL`

I wish cmakelint would have detected it

Also, downgrade this check to 9.3, as all our binary builds are using 9.3 at the moment (will update in a followup PR)

Pull Request resolved: https://github.com/pytorch/pytorch/pull/120489
Approved by: https://github.com/DanilBaibak, https://github.com/Skylion007
This commit is contained in:
Nikita Shulga 2024-02-23 20:31:17 +00:00 committed by PyTorch MergeBot
parent 007606e520
commit e29eb39e04

View File

@ -43,9 +43,9 @@ set(CMAKE_C_STANDARD 11 CACHE STRING "The C standard whose features are reques
# ---[ Utils
include(cmake/public/utils.cmake)
# --- [ Check that minimal gcc version is 9.4+
if(CMAKE_COMPILER_IS_GNUCXX AND CMAKE_CXX_COMPILER_VERSION VERSION_LESS 9.4)
message(FATAL "GCC-9.4 or newer is required to compile PyTorch, but found ${CMAKE_CXX_COMPILER_VERSION}")
# --- [ Check that minimal gcc version is 9.3+
if(CMAKE_COMPILER_IS_GNUCXX AND CMAKE_CXX_COMPILER_VERSION VERSION_LESS 9.3)
message(FATAL_ERROR "GCC-9.3 or newer is required to compile PyTorch, but found ${CMAKE_CXX_COMPILER_VERSION}")
endif()
# This define is needed to preserve behavior given anticpated changes to cccl/thrust