MCPcopy Create free account
hub / github.com/pytorch/executorch / main

Function main

scripts/strip_binary.py:25–37  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

23
24
25def main():
26 if len(sys.argv) != 3:
27 print("Must specify input and output file paths")
28 sys.exit(1)
29
30 input_file = Path(sys.argv[1])
31 output_file = Path(sys.argv[2])
32
33 # Assumes `strip` tool is in the path (should be specified by Skycastle workflow).
34 # GNU `strip`, or equivalent, should work for x86 and ARM ELF binaries. This might
35 # not be appropriate for more exotic, non-ELF toolchains.
36 completed = subprocess.run(["strip", "--strip-all", input_file, "-o", output_file])
37 sys.exit(completed.returncode)
38
39
40if __name__ == "__main__":

Callers 1

strip_binary.pyFile · 0.70

Calls 1

runMethod · 0.45

Tested by

no test coverage detected