MCPcopy Create free account
hub / github.com/apache/arrow / list_dependencies

Method list_dependencies

dev/archery/archery/linking.py:37–51  ·  view source on GitHub ↗

List the full name of the library dependencies.

(self)

Source from the content-addressed store, hash-verified

35 self.path = path
36
37 def list_dependencies(self):
38 """
39 List the full name of the library dependencies.
40 """
41 system = platform.system()
42 if system == "Linux":
43 result = _ldd.run(self.path, stdout=subprocess.PIPE)
44 lines = result.stdout.splitlines()
45 return [ll.split(None, 1)[0].decode() for ll in lines]
46 elif system == "Darwin":
47 result = _otool.run("-L", self.path, stdout=subprocess.PIPE)
48 lines = result.stdout.splitlines()
49 return [dl.split(None, 1)[0].decode() for dl in lines]
50 else:
51 raise ValueError(f"{platform} is not supported")
52
53 def list_dependency_names(self):
54 """

Callers 1

list_dependency_namesMethod · 0.95

Calls 2

runMethod · 0.45
decodeMethod · 0.45

Tested by

no test coverage detected