소스 검색

修复 scons --target=eclipse 时,部分带值宏出错的问题

guozhanxin 5 년 전
부모
커밋
c1b35a48a5
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      tools/eclipse.py

+ 1 - 1
tools/eclipse.py

@@ -228,7 +228,7 @@ def HandleToolOption(tools, env, project, reset):
         with open('rtconfig_preinc.h', mode = 'w+') as f:
             f.write(file_header)
             for cppdef in CPPDEFINES:
-                f.write("#define " + cppdef + '\n')
+                f.write("#define " + cppdef.replace('=', ' ') + '\n')
             f.write(file_tail)
         #  change the c.compiler.include.files
         files = option.findall('listOptionValue')