Skip to content

Commit feef4da

Browse files
amysparkeli-schwartz
authored andcommitted
options: Make sure the gnu99 deprecation is only printed once
Cuts down the spam radically when building with MSVC. (cherry picked from commit 67a903b)
1 parent ae6fbc3 commit feef4da

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

mesonbuild/options.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -512,7 +512,7 @@ def validate_value(self, value: T.Union[str, T.List[str]]) -> str:
512512
f'However, the deprecated {std} std currently falls back to {newstd}.\n' +
513513
'This will be an error in meson 2.0.\n' +
514514
'If the project supports both GNU and MSVC compilers, a value such as\n' +
515-
'"c_std=gnu11,c11" specifies that GNU is preferred but it can safely fallback to plain c11.')
515+
'"c_std=gnu11,c11" specifies that GNU is preferred but it can safely fallback to plain c11.', once=True)
516516
return newstd
517517
raise MesonException(f'None of values {candidates} are supported by the {self.lang.upper()} compiler. ' +
518518
f'Possible values for option "{self.name}" are {self.choices}')

0 commit comments

Comments
 (0)