mirror of
https://github.com/RT-Thread/rt-thread.git
synced 2025-10-20 05:25:04 +08:00
[Libc][dlib] Auto remove macro _DLIB_THREAD_SUPPORT when IAR version higher than 8.20.1
This commit is contained in:
@@ -1,4 +1,7 @@
|
|||||||
from building import *
|
from building import *
|
||||||
|
from distutils.version import LooseVersion
|
||||||
|
from iar import IARVersion
|
||||||
|
|
||||||
Import('rtconfig')
|
Import('rtconfig')
|
||||||
|
|
||||||
src = Glob('*.c')
|
src = Glob('*.c')
|
||||||
@@ -11,7 +14,10 @@ CPPDEFINES = ['RT_USING_DLIBC']
|
|||||||
if rtconfig.PLATFORM == 'iar':
|
if rtconfig.PLATFORM == 'iar':
|
||||||
|
|
||||||
if GetDepend('RT_USING_DFS'):
|
if GetDepend('RT_USING_DFS'):
|
||||||
CPPDEFINES = CPPDEFINES + ['_DLIB_FILE_DESCRIPTOR', '_DLIB_THREAD_SUPPORT']
|
CPPDEFINES = CPPDEFINES + ['_DLIB_FILE_DESCRIPTOR']
|
||||||
|
|
||||||
|
if LooseVersion(IARVersion()) < LooseVersion("8.20.1"):
|
||||||
|
CPPDEFINES = CPPDEFINES + ['_DLIB_THREAD_SUPPORT']
|
||||||
|
|
||||||
group = DefineGroup('dlib', src, depend = ['RT_USING_LIBC'],
|
group = DefineGroup('dlib', src, depend = ['RT_USING_LIBC'],
|
||||||
CPPPATH = CPPPATH, CPPDEFINES = CPPDEFINES)
|
CPPPATH = CPPPATH, CPPDEFINES = CPPDEFINES)
|
||||||
|
Reference in New Issue
Block a user