mirror of
https://gitee.com/Vancouver2017/luban-lite-t3e-pro.git
synced 2025-12-14 18:38:55 +00:00
18 lines
496 B
Python
18 lines
496 B
Python
import os
|
|
import sys
|
|
|
|
aic_system = sys.argv[1]
|
|
aic_root = os.path.normpath(sys.argv[2])
|
|
aic_pack_dir = os.path.normpath(sys.argv[3])
|
|
prj_out_dir = os.path.normpath(sys.argv[4])
|
|
|
|
os.chdir(prj_out_dir)
|
|
|
|
if aic_system == 'Linux':
|
|
os.system('cat ota-subimgs.cfg | cpio -ov -H crc > ota.cpio')
|
|
elif aic_system == 'Windows':
|
|
cpio_tool_dir = os.path.join(aic_root, 'tools\scripts\cpio.exe')
|
|
os.system('type ota-subimgs.cfg | ' + cpio_tool_dir + ' -ov -H crc > ota.cpio')
|
|
|
|
os.chdir(aic_root)
|