[tools] add GetGCCLikePLATFORM

GCC like means the toolchains which are compatible with GCC
This commit is contained in:
Meco Man
2023-08-21 01:25:52 -04:00
parent 290678b665
commit 30c793fdb9
7 changed files with 16 additions and 7 deletions
+2 -1
View File
@@ -1,4 +1,5 @@
from building import *
from gcc import *
import rtconfig
cwd = GetCurrentDir()
@@ -29,7 +30,7 @@ if GetDepend('RT_USING_SFUD'):
if GetDepend('RT_SFUD_USING_SFDP'):
src_device += ['sfud/src/sfud_sfdp.c']
if rtconfig.PLATFORM in ['gcc', 'armclang', 'llvm-arm']:
if rtconfig.PLATFORM in GetGCCLikePLATFORM():
LOCAL_CFLAGS += ' -std=c99'
elif rtconfig.PLATFORM in ['armcc']:
LOCAL_CFLAGS += ' --c99'