MCPcopy Index your code
hub / github.com/nodejs/node / GetPerTargetSetting

Method GetPerTargetSetting

tools/gyp/pylib/gyp/xcode_emulation.py:1039–1055  ·  view source on GitHub ↗

Tries to get xcode_settings.setting from spec. Assumes that the setting has the same value in all configurations and throws otherwise.

(self, setting, default=None)

Source from the content-addressed store, hash-verified

1037 return self.GetPerTargetSetting(setting, default)
1038
1039 def GetPerTargetSetting(self, setting, default=None):
1040 """Tries to get xcode_settings.setting from spec. Assumes that the setting
1041 has the same value in all configurations and throws otherwise."""
1042 is_first_pass = True
1043 result = None
1044 for configname in sorted(self.xcode_settings.keys()):
1045 if is_first_pass:
1046 result = self.xcode_settings[configname].get(setting, None)
1047 is_first_pass = False
1048 else:
1049 assert result == self.xcode_settings[configname].get(setting, None), (
1050 "Expected per-target setting for '%s', got per-config setting "
1051 "(target %s)" % (setting, self.spec["target_name"])
1052 )
1053 if result is None:
1054 return default
1055 return result
1056
1057 def _GetStripPostbuilds(self, configname, output_binary, quiet):
1058 """Returns a list of shell commands that contain the shell commands

Callers 9

GetFrameworkVersionMethod · 0.95
GetWrapperExtensionMethod · 0.95
GetInstallNameBaseMethod · 0.95
GetInstallNameMethod · 0.95
GetPerConfigSettingMethod · 0.95
__init__Method · 0.80
GetMacInfoPlistFunction · 0.80

Calls 3

sortedFunction · 0.85
keysMethod · 0.65
getMethod · 0.65

Tested by

no test coverage detected