From 5b3320624da5149fc21c2d3e1f321d855e3d0dfe Mon Sep 17 00:00:00 2001 From: Supper Thomas <78900636@qq.com> Date: Sun, 16 Feb 2025 22:02:42 +0800 Subject: [src/ktime] fix the bug when use keil AC6 and open RT_USING_HOOKLIST … (#9993) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * [src/ktime] fix the bug when use keil AC6 and open RT_USING_HOOKLIST and RT_USING_KTIME --- components/drivers/ktime/SConscript | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'components/drivers/ktime/SConscript') diff --git a/components/drivers/ktime/SConscript b/components/drivers/ktime/SConscript index 6eedb84818..3fb3139025 100644 --- a/components/drivers/ktime/SConscript +++ b/components/drivers/ktime/SConscript @@ -13,7 +13,12 @@ if rtconfig.ARCH in list: else: src += Glob("src/" + rtconfig.ARCH + "/*.c") CPPPATH = [cwd, cwd + "/inc"] +LOCAL_CCFLAGS = '' +if rtconfig.PLATFORM in ['gcc', 'armclang']: + LOCAL_CCFLAGS += ' -std=gnu99' +elif rtconfig.PLATFORM in ['armcc']: + LOCAL_CCFLAGS += ' --c99 --gnu' -group = DefineGroup('ktime', src, depend=['RT_USING_KTIME'], CPPPATH=CPPPATH) +group = DefineGroup('ktime', src, depend=['RT_USING_KTIME'], CPPPATH=CPPPATH, LOCAL_CCFLAGS = LOCAL_CCFLAGS) Return('group') -- cgit v1.3.1