From e1de1bae0997f38370bb9cae3f158af9ae3f14ac Mon Sep 17 00:00:00 2001 From: "L. E. Segovia" Date: Mon, 24 Apr 2023 20:58:59 -0300 Subject: yasm: Fix usage of incompatible optimization flags Fixes #11726 --- mesonbuild/compilers/asm.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/mesonbuild/compilers/asm.py b/mesonbuild/compilers/asm.py index f3b8604a0..a156a17ba 100644 --- a/mesonbuild/compilers/asm.py +++ b/mesonbuild/compilers/asm.py @@ -149,6 +149,10 @@ class NasmCompiler(Compiler): class YasmCompiler(NasmCompiler): id = 'yasm' + def get_optimization_args(self, optimization_level: str) -> T.List[str]: + # Yasm is incompatible with Nasm optimization flags. + return [] + def get_exelist(self, ccache: bool = True) -> T.List[str]: # Wrap yasm executable with an internal script that will write depfile. exelist = super().get_exelist(ccache) -- cgit v1.2.1