diff options
| author | Bernard Xiong <[email protected]> | 2014-10-28 03:45:43 +0000 |
|---|---|---|
| committer | Bernard Xiong <[email protected]> | 2014-10-28 03:45:43 +0000 |
| commit | 802c768475b5575192c0b2b5e7802e8d4aebceba (patch) | |
| tree | 730ae3ef21502b04268f164f6e07af09e6a5c6f9 /components/libc/newlib | |
| parent | 372926477b31674db1475fd3e88871fb2af9289f (diff) | |
[LIBC] Use RT_USING_LIBC instead of libs option for each compiler
Diffstat (limited to 'components/libc/newlib')
| -rw-r--r-- | components/libc/newlib/SConscript | 15 |
1 files changed, 5 insertions, 10 deletions
diff --git a/components/libc/newlib/SConscript b/components/libc/newlib/SConscript index ae8e8756e1..574c2a8d1f 100644 --- a/components/libc/newlib/SConscript +++ b/components/libc/newlib/SConscript @@ -1,15 +1,10 @@ -Import('rtconfig') from building import * -if GetDepend('RT_USING_NEWLIB') and rtconfig.CROSS_TOOL != 'gcc': - print '================ERROR============================' - print 'Please use GNU GCC compiler if using newlib' - print '=================================================' - exit(0) - +src = Glob('*.c') cwd = GetCurrentDir() -src = Glob('*.c') + CPPPATH = [cwd] +CPPDEFINES = ['RT_USING_NEWLIB'] # link with libc and libm: # libm is a frequently used lib. Newlib is compiled with -ffunction-sections in @@ -17,7 +12,7 @@ CPPPATH = [cwd] # been referenced. So setting this won't result in bigger text size. LIBS = ['c', 'm'] -group = DefineGroup('newlib', src, depend = ['RT_USING_NEWLIB'], - CPPPATH = CPPPATH, LIBS = LIBS) +group = DefineGroup('newlib', src, depend = ['RT_USING_LIBC'], + CPPPATH = CPPPATH, CPPDEFINES = CPPDEFINES, LIBS = LIBS) Return('group') |
