4
0
mirror of https://github.com/RT-Thread/rt-thread.git synced 2025-01-27 06:07:24 +08:00
zhkag 9c14c518db
[bsp][mm32] 修复编译问题 (#7780)
Co-authored-by: Supper Thomas <78900636@qq.com>
2023-07-05 18:20:08 +08:00

17 lines
656 B
Python

from building import *
import rtconfig
cwd = GetCurrentDir()
src = ['MM32F327x/Source/system_mm32f327x.c']
CPPPATH = [cwd + '/CMSIS/KEIL_CORE', cwd + '/MM32F327x/Include', cwd + '/MM32F327x/Source', cwd + '/MM32F327x/HAL_Lib/Inc']
src += Glob('MM32F327x/HAL_lib/src/*.c')
CPPDEFINES = ['USE_STDPERIPH_DRIVER']
if rtconfig.PLATFORM in ['armcc', 'armclang']:
src += ['MM32F327x/Source/KEIL_StartAsm/startup_mm32f327x_keil.s']
elif rtconfig.PLATFORM in ['iccarm']:
src += ['MM32F327x/Source/IAR_StartAsm/startup_mm32f327x_iar.s']
group = DefineGroup('Libraries', src, depend = [''], CPPPATH = CPPPATH, CPPDEFINES = CPPDEFINES)
Return('group')