'fs_image_path':'leiniao',
'ssb_version': 'brandy-native-js-ln-ssb',
# 'fs_image_path':'evb',
+ # 'mkyaffs2image_old': True,
'fs_image': True
},
'brandy-native-js-ln-r': {
'fs_image_path':'leiniao',
'ssb_version': 'brandy-native-js-ln-ssb',
# 'fs_image_path':'evb',
+ # 'mkyaffs2image_old': True,
'fs_image': True
},
'brandy-native-js-lnppp-r': {
cur_dir = os.path.dirname(os.path.abspath(__file__))\r
image_tool_path = os.path.realpath(os.path.join(root_path, 'tools', 'bin', 'platform_tool', 'mkyaffs2image'))\r
\r
-# 配置生成文件镜像工具路径\r
mkyaffstool = os.path.join(image_tool_path, 'mkyaffs2image')\r
image_name = "file"\r
\r
if sys.argv[3] == 'False':\r
single_user_partition = False\r
fs_image_path=sys.argv[4]\r
+ elif len(sys.argv) == 6 :\r
+ out_path = os.path.join(sys.argv[1], "%s.bin" %image_name)\r
+ if sys.argv[2] == '128' :\r
+ cfg_obb_size = 128\r
+ if sys.argv[3] == 'False':\r
+ single_user_partition = False\r
+ fs_image_path=sys.argv[4]\r
+ if sys.argv[5] == 'True':\r
+ mkyaffstool = os.path.join(image_tool_path, 'mkyaffs2image.old')\r
+ else:\r
+ mkyaffstool = os.path.join(image_tool_path, 'mkyaffs2image')\r
else:\r
print("need give parms output path and oobsize!")\r
sys.exit(1)\r
os.remove(tmp_file)\r
if os.path.exists(image_file):\r
os.remove(image_file)\r
+ # 配置生成文件镜像工具路径\r
if single_user_partition :\r
for partition in partition_list_single:\r
if (partition[1] != "null"):\r
defines = env.get("defines")
if "CFG_DRIVERS_NANDFLASH" in defines:
print("fs img nandflash mode")
+ mkyaffs2image_old = 'False'
if env.get('fs_image_path'):
fs_image_path = os.path.join(root_path, 'files', env.get('fs_image_path'))
else:
fs_image_path = os.path.join(root_path, 'files', 'fd230')
+ if env.get('mkyaffs2image_old'):
+ mkyaffs2image_old = 'True'
# 创建文件校验表,方便检验文件完整性。
create_fs_checksum_script_path=os.path.join(root_path, 'build', 'config', 'target_config', env.get('chip'),'mk_fs_image', 'create_fs_checksumfile.py')
errcode = exec_shell([self.python_path, create_fs_checksum_script_path, fs_image_path], None, True)
else :
oobsize = '64'
- errcode = exec_shell([self.python_path, fs_script_path, output_path, oobsize,single_user_partition,fs_image_path], None, True)
+ errcode = exec_shell([self.python_path, fs_script_path, output_path, oobsize,single_user_partition,fs_image_path,mkyaffs2image_old], None, True)
if errcode != 0:
print("creat fs image error!")
self.print_build_result(target, errcode)