diff options
| author | Meco Man <[email protected]> | 2022-01-19 23:24:47 -0500 |
|---|---|---|
| committer | Meco Man <[email protected]> | 2022-01-19 23:24:47 -0500 |
| commit | 884218588ae6a68ed923e4a9774f2ea4d76b90db (patch) | |
| tree | a38da0a8e209f9d1d8ce8ff6f3fe724afa8cb360 /bsp | |
| parent | 3448a8b6d53bfc27c8d6946b3f294ba17aac62c0 (diff) | |
[sconscript.platform] 优化针对编译器判断的脚本
- 删除啰嗦的代码
related: https://github.com/RT-Thread/rt-thread/issues/3046
Diffstat (limited to 'bsp')
| -rw-r--r-- | bsp/stm32/stm32l475-atk-pandora/board/ports/fal/SConscript | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/bsp/stm32/stm32l475-atk-pandora/board/ports/fal/SConscript b/bsp/stm32/stm32l475-atk-pandora/board/ports/fal/SConscript index 4a53bd1c97..2b71fcc93c 100644 --- a/bsp/stm32/stm32l475-atk-pandora/board/ports/fal/SConscript +++ b/bsp/stm32/stm32l475-atk-pandora/board/ports/fal/SConscript @@ -10,13 +10,12 @@ src += Glob('*.c') CPPPATH = [cwd] LOCAL_CCFLAGS = '' -if rtconfig.CROSS_TOOL == 'gcc': +if rtconfig.PLATFORM == 'gcc': + LOCAL_CCFLAGS += ' -std=c99' +elif rtconfig.PLATFORM == 'armcc': + LOCAL_CCFLAGS += ' --c99' +elif rtconfig.PLATFORM == 'armclang': LOCAL_CCFLAGS += ' -std=c99' -elif rtconfig.CROSS_TOOL == 'keil': - if rtconfig.PLATFORM == 'armcc': - LOCAL_CCFLAGS += ' --c99' - elif rtconfig.PLATFORM == 'armclang': - LOCAL_CCFLAGS += ' -std=c99' group = DefineGroup('FAL', src, depend = ['PKG_USING_FAL'], CPPPATH = CPPPATH, LOCAL_CCFLAGS = LOCAL_CCFLAGS) |
