MCPcopy Create free account
hub / github.com/XiaoMi/mace / install

Method install

tools/python/utils/device.py:256–270  ·  view source on GitHub ↗
(self, target, install_dir, install_deps=False)

Source from the content-addressed store, hash-verified

254 ArmLinuxDevice.devices = devices
255
256 def install(self, target, install_dir, install_deps=False):
257 install_dir = os.path.abspath(install_dir)
258 ip = self._device_id
259
260 execute("ssh %s mkdir -p %s" % (ip, install_dir))
261 execute("scp -r %s %s:%s" % (target.path, ip, install_dir))
262 for lib in target.libs:
263 execute("scp -r %s:%s" % (lib, install_dir))
264
265 target.path = "%s/%s" % (install_dir, os.path.basename(target.path))
266 target.libs = ["%s/%s" % (install_dir, os.path.basename(lib))
267 for lib in target.libs]
268 target.envs.append("LD_LIBRARY_PATH=%s" % install_dir)
269
270 return target
271
272 def run(self, target):
273 execute("ssh %s %s" % (self._device_id, target))

Callers

nothing calls this directly

Calls 1

executeFunction · 0.85

Tested by

no test coverage detected