From 1ee9af8b09244c898988de797f664f2c348d6dae Mon Sep 17 00:00:00 2001 From: stary-m <2386279494@qq.com> Date: Tue, 1 Apr 2025 22:02:32 +0800 Subject: [PATCH] Fixed an error by running scons --tartget=cmake under LINUX, and associated issue #10113 --- tools/cmake.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tools/cmake.py b/tools/cmake.py index 9a9affad482..7f7c26eb6ce 100644 --- a/tools/cmake.py +++ b/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('\"', "\\\"")