mirror of
https://gitee.com/openharmony/startup_init
synced 2024-11-27 18:30:52 +00:00
修改param_cfg_to_code.py
Signed-off-by: laiguizhong <laiguizhong@huawei.com>
This commit is contained in:
parent
0e7cfe2df8
commit
c8c1b0d8e1
@ -64,11 +64,14 @@ def GetParamFromCCode(codeName):
|
||||
if len(name) != 0 and len(value) != 0:
|
||||
dict[name] = value
|
||||
data = afile.readline()
|
||||
afile.truncate(0)
|
||||
return dict
|
||||
|
||||
def WriteMapToCode(codeName, dict):
|
||||
try:
|
||||
f = open(codeName, 'w')
|
||||
# start with 0
|
||||
f.seek(0)
|
||||
# write file header
|
||||
f.write('#ifndef PARAM_LITE_DEF_CFG_' + os.linesep)
|
||||
f.write('#define PARAM_LITE_DEF_CFG_' + os.linesep)
|
||||
|
Loading…
Reference in New Issue
Block a user