MCPcopy Create free account
hub / github.com/nodejs/node / _GetStandaloneBinaryPath

Method _GetStandaloneBinaryPath

tools/gyp/pylib/gyp/xcode_emulation.py:470–488  ·  view source on GitHub ↗

Returns the name of the non-bundle binary represented by this target. E.g. hello_world. Only valid for non-bundles.

(self)

Source from the content-addressed store, hash-verified

468 )
469
470 def _GetStandaloneBinaryPath(self):
471 """Returns the name of the non-bundle binary represented by this target.
472 E.g. hello_world. Only valid for non-bundles."""
473 assert not self._IsBundle()
474 assert self.spec["type"] in {
475 "executable",
476 "shared_library",
477 "static_library",
478 "loadable_module",
479 }, "Unexpected type %s" % self.spec["type"]
480 target = self.spec["target_name"]
481 if self.spec["type"] in {"loadable_module", "shared_library", "static_library"}:
482 if target[:3] == "lib":
483 target = target[3:]
484
485 target_prefix = self._GetStandaloneExecutablePrefix()
486 target = self.spec.get("product_name", target)
487 target_ext = self._GetStandaloneExecutableSuffix()
488 return target_prefix + target + target_ext
489
490 def GetExecutableName(self):
491 """Returns the executable name of the bundle represented by this target.

Callers 3

GetFullProductNameMethod · 0.95
GetExecutableNameMethod · 0.95
GetExecutablePathMethod · 0.95

Calls 4

_IsBundleMethod · 0.95
getMethod · 0.65

Tested by

no test coverage detected