[keil.py] 修复生成Keil4/5工程文件时,头文件路径重复的问题

This commit is contained in:
Meco Man 2022-08-21 01:35:44 -04:00 committed by Man, Jianting (Meco)
parent aab2428d41
commit ecd9cd32b7
1 changed files with 1 additions and 1 deletions

View File

@ -268,7 +268,7 @@ def MDK45Project(tree, target, script):
# write include path, definitions and link flags # write include path, definitions and link flags
IncludePath = tree.find('Targets/Target/TargetOption/TargetArmAds/Cads/VariousControls/IncludePath') IncludePath = tree.find('Targets/Target/TargetOption/TargetArmAds/Cads/VariousControls/IncludePath')
IncludePath.text = ';'.join([_make_path_relative(project_path, os.path.normpath(i)) for i in CPPPATH]) IncludePath.text = ';'.join([_make_path_relative(project_path, os.path.normpath(i)) for i in set(CPPPATH)])
Define = tree.find('Targets/Target/TargetOption/TargetArmAds/Cads/VariousControls/Define') Define = tree.find('Targets/Target/TargetOption/TargetArmAds/Cads/VariousControls/Define')
Define.text = ', '.join(set(CPPDEFINES)) Define.text = ', '.join(set(CPPDEFINES))