Skip to content

Commit

Permalink
compilers: port stragglers to form_compileropt_key
Browse files Browse the repository at this point in the history
Noticed by inspection.

Fixes: 03f0551
Fixes: fbb8b09
Signed-off-by: Sam James <sam@gentoo.org>
  • Loading branch information
thesamesam committed Sep 10, 2024
1 parent f83dca3 commit d52b2f4
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion mesonbuild/compilers/c.py
Original file line number Diff line number Diff line change
Expand Up @@ -310,7 +310,7 @@ def get_options(self) -> 'MutableKeyedOptionDictType':
self.update_options(
opts,
self.create_option(options.UserArrayOption,
key.evolve('c_winlibs'),
self.form_compileropt_key('winlibs'),
'Standard Win libraries to link against',
gnu_winlibs),
)
Expand Down
10 changes: 5 additions & 5 deletions mesonbuild/compilers/cpp.py
Original file line number Diff line number Diff line change
Expand Up @@ -397,7 +397,7 @@ def get_options(self) -> 'MutableKeyedOptionDictType':
self.update_options(
opts,
self.create_option(options.UserComboOption,
key.evolve('eh'),
self.form_compileropt_key('eh'),
'C++ exception handling type.',
['none', 'default', 'a', 's', 'sc'],
'default'),
Expand Down Expand Up @@ -475,7 +475,7 @@ def get_options(self) -> 'MutableKeyedOptionDictType':
self.update_options(
opts,
self.create_option(options.UserArrayOption,
key.evolve('cpp_winlibs'),
self.form_compileropt_key('cpp_winlibs'),
'Standard Win libraries to link against',
gnu_winlibs),
)
Expand Down Expand Up @@ -700,11 +700,11 @@ def get_option_compile_args(self, options: 'KeyedOptionDictType') -> T.List[str]
'gnu++03': 'gnu++98'
}
args.append('-std=' + remap_cpp03.get(std, std))
if options.get_value(key.evolve('eh')) == 'none':
if options.get_value(self.form_compileropt_key('eh')) == 'none':
args.append('-fno-exceptions')
if not options.get_value(key.evolve('rtti')):
if not options.get_value(self.form_compileropt_key('rtti')):
args.append('-fno-rtti')
if options.get_value(key.evolve('debugstl')):
if options.get_value(self.form_compileropt_key('debugstl')):
args.append('-D_GLIBCXX_DEBUG=1')
return args

Expand Down

0 comments on commit d52b2f4

Please sign in to comment.