CMakeLists.txt: add -fmax-errors=5 for GNU

Stops compilation after 5 errors, such as in the case of
cascading errors from a missing semicolon.
This commit is contained in:
James R 2023-07-27 18:32:11 -07:00
parent 3eb356f7b9
commit b7d4513fba

View file

@ -513,6 +513,11 @@ target_compile_options(SRB2SDL2 PRIVATE
$<$<AND:$<COMPILE_LANGUAGE:C>,$<C_COMPILER_ID:MSVC>>:
/Wv:19.20.27004.0
>
# GNU
$<$<C_COMPILER_ID:GNU>:
-fmax-errors=5
>
)
if(SRB2_CONFIG_ERRORMODE)
target_compile_options(SRB2SDL2 PRIVATE