diff options
| author | Bernard Xiong <[email protected]> | 2014-10-30 07:22:34 +0800 |
|---|---|---|
| committer | Bernard Xiong <[email protected]> | 2014-10-30 07:22:34 +0800 |
| commit | a9952648322ee8b99a2f2798408162423d7d0d84 (patch) | |
| tree | c15e841a4975846c9ff84da4fa26a370f953001f /components/libc/newlib/SConscript | |
| parent | 372926477b31674db1475fd3e88871fb2af9289f (diff) | |
| parent | 692e597847c53fe7bb248836f74795eb39e37b0c (diff) | |
Merge pull request #360 from BernardXiong/master
[LIBC] Use RT_USING_LIBC instead of libs option for each compiler
Diffstat (limited to 'components/libc/newlib/SConscript')
| -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') |
