Skip to content

Commit 63ea057

Browse files
When testing for architecture flag, make sure those flags are not ignored
Fix #999
1 parent 7080469 commit 63ea057

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

test/architectures/CMakeLists.txt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,11 @@ set(INTEL_PROCESSORS
22
knl knm skylake-avx512 cannonlake icelake-client
33
icelake-server cascadelake cooperlake tigerlake sapphirerapids alderlake
44
rocketlake graniterapids graniterapids-d znver4)
5-
set(CMAKE_CXX_FLAGS "")
5+
set(CMAKE_CXX_FLAGS "-Werror=unused-command-line-argument")
66

77
foreach(INTEL_PROCESSOR ${INTEL_PROCESSORS})
8+
# Adding the werror here to choke if the -march is incompatible with the
9+
# native one.
810
check_cxx_compiler_flag(-march=${INTEL_PROCESSOR} FLAG_SUPPORTED_${INTEL_PROCESSOR})
911
if(FLAG_SUPPORTED_${INTEL_PROCESSOR})
1012
message(STATUS ${INTEL_PROCESSOR})

0 commit comments

Comments
 (0)