From 61c742fae9ec74e81b3bb3caf815cf49992fb93c Mon Sep 17 00:00:00 2001 From: Jussi Pakkanen Date: Fri, 12 Jul 2024 20:57:04 +0300 Subject: Remove language (AKA compiler) type from OptionKey. --- mesonbuild/compilers/cpp.py | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) (limited to 'mesonbuild/compilers/cpp.py') diff --git a/mesonbuild/compilers/cpp.py b/mesonbuild/compilers/cpp.py index ed840e6d5..1f0952455 100644 --- a/mesonbuild/compilers/cpp.py +++ b/mesonbuild/compilers/cpp.py @@ -475,7 +475,7 @@ class GnuCPPCompiler(_StdCPPLibMixin, GnuCompiler, CPPCompiler): self.update_options( opts, self.create_option(options.UserArrayOption, - key.evolve('winlibs'), + key.evolve('cpp_winlibs'), 'Standard Win libraries to link against', gnu_winlibs), ) @@ -483,17 +483,21 @@ class GnuCPPCompiler(_StdCPPLibMixin, GnuCompiler, CPPCompiler): def get_option_compile_args(self, options: 'KeyedOptionDictType') -> T.List[str]: args: T.List[str] = [] - key = self.form_compileropt_key('std') - std = options.get_value(key) + stdkey = self.form_compileropt_key('std') + ehkey = self.form_compileropt_key('eh') + rttikey = self.form_compileropt_key('rtti') + debugstlkey = self.form_compileropt_key('debugstl') + + std = options.get_value(stdkey) if std != 'none': args.append(self._find_best_cpp_std(std)) - non_msvc_eh_options(options.get_value(key.evolve('eh')), args) + non_msvc_eh_options(options.get_value(ehkey), args) - if not options.get_value(key.evolve('rtti')): + if not options.get_value(rttikey): args.append('-fno-rtti') - if options.get_value(key.evolve('debugstl')): + if options.get_value(debugstlkey): args.append('-D_GLIBCXX_DEBUG=1') return args -- cgit v1.2.3