mirror of
https://gitlab.kitware.com/cmake/cmake.git
synced 2026-09-25 04:09:36 +03:00
Source: Fix configuration with GCC 14.3+ on machines with AVX10.1
When detecting C++ features, filter out a warning that is generated by GCC >= 14.3 on, for example, Intel graniterapids machines. Fixes: #27745
This commit is contained in:
@@ -63,6 +63,8 @@ function(cm_check_cxx_feature name)
|
||||
string(REGEX REPLACE "[^\n]*ld: warning: [^\n]*" "" check_output "${check_output}")
|
||||
# Filter out distcc.
|
||||
string(REGEX REPLACE "[^\n]*distcc\\[[0-9]+\\][^\n]*[Ww]arning:[^\n]*" "" check_output "${check_output}")
|
||||
# Filter warning on Intel graniterapids CPUs
|
||||
string(REGEX REPLACE "[^\n]*cc1[plus]*: warning: [^\n]*-mavx[^\n]* is aliased[^\n]*" "" check_output "${check_output}")
|
||||
# If using the feature causes warnings, treat it as broken/unavailable.
|
||||
if(check_output MATCHES "(^|[ :])[Ww][Aa][Rr][Nn][Ii][Nn][Gg]")
|
||||
set(CMake_HAVE_CXX_${FEATURE} OFF CACHE INTERNAL "TRY_COMPILE" FORCE)
|
||||
|
||||
Reference in New Issue
Block a user