浏览代码

Fixed an error by running scons --tartget=cmake under LINUX, #10113 (#10164)

Fixed an error by running scons --tartget=cmake under LINUX, and associated issue #10113
keeping passionate! 2 周之前
父节点
当前提交
7c39352f4c
共有 1 个文件被更改,包括 2 次插入1 次删除
  1. 2 1
      tools/cmake.py

+ 2 - 1
tools/cmake.py

@@ -64,7 +64,8 @@ def GenerateCFiles(env, project, project_name):
 
     CFLAGS = env['CFLAGS'].replace('\\', "/").replace('\"', "\\\"")
     if 'CXXFLAGS' in dir(rtconfig):
-        CXXFLAGS = env['CXXFLAGS'].replace('\\', "/").replace('\"', "\\\"")
+        cflag_str=''.join(env['CXXFLAGS'])
+        CXXFLAGS = cflag_str.replace('\\', "/").replace('\"', "\\\"")
     else:
         CXXFLAGS = CFLAGS
     AFLAGS = env['ASFLAGS'].replace('\\', "/").replace('\"', "\\\"")