summaryrefslogtreecommitdiff
path: root/mesonbuild/compilers/objc.py
diff options
context:
space:
mode:
authorDylan Baker <dylan@pnwbakers.com>2025-03-04 08:24:08 -0800
committerEli Schwartz <eschwartz93@gmail.com>2025-03-10 14:14:25 -0400
commit251f74dcf3fea706ed373b717257f82592b6a1de (patch)
tree5ee2906048dc2bb552be08e040d332e9dfc7d8fb /mesonbuild/compilers/objc.py
parent4fa52925459dac650bf053715987ee7beb3b23c1 (diff)
downloadmeson-251f74dcf3fea706ed373b717257f82592b6a1de.tar.gz
coredata: remove get_option_for_subproject
This is just a wrapper around `OptionStore.get_option_for`, but without taking an `OptionKey`. This complicates the subproject passing, since `OptionKey` is designed to encapsulate the option name and subproject.
Diffstat (limited to 'mesonbuild/compilers/objc.py')
-rw-r--r--mesonbuild/compilers/objc.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/mesonbuild/compilers/objc.py b/mesonbuild/compilers/objc.py
index b133d47c4..776f5037d 100644
--- a/mesonbuild/compilers/objc.py
+++ b/mesonbuild/compilers/objc.py
@@ -78,11 +78,11 @@ class GnuObjCCompiler(GnuCStds, GnuCompiler, ObjCCompiler):
def get_option_compile_args(self, target: 'BuildTarget', env: 'Environment', subproject: T.Optional[str] = None) -> T.List[str]:
args: T.List[str] = []
- key = OptionKey('c_std', machine=self.for_machine)
+ key = OptionKey('c_std', subproject=subproject, machine=self.for_machine)
if target:
std = env.coredata.get_option_for_target(target, key)
else:
- std = env.coredata.get_option_for_subproject(key, subproject)
+ std = env.coredata.optstore.get_value_for(key)
assert isinstance(std, str)
if std != 'none':
args.append('-std=' + std)