diff --git a/mesonbuild/compilers/cuda.py b/mesonbuild/compilers/cuda.py index 4dd9c36ca..603ad1321 100644 --- a/mesonbuild/compilers/cuda.py +++ b/mesonbuild/compilers/cuda.py @@ -183,7 +183,7 @@ class CudaCompiler(Compiler): #endif return 0; }}''' - found, cached = self.compiles(t.format(**fargs), env, extra_args=extra_args, dependencies=dependencies) + found, cached = self.compiles(t.format_map(fargs), env, extra_args=extra_args, dependencies=dependencies) if found: return True, cached # Check if it's a class or a template @@ -193,7 +193,7 @@ class CudaCompiler(Compiler): int main(void) {{ return 0; }}''' - return self.compiles(t.format(**fargs), env, extra_args=extra_args, dependencies=dependencies) + return self.compiles(t.format_map(fargs), env, extra_args=extra_args, dependencies=dependencies) def get_options(self) -> 'OptionDictType': opts = super().get_options()