summaryrefslogtreecommitdiff
path: root/components/libc/compilers/common/SConscript
diff options
context:
space:
mode:
authorchenyingchun0312 <[email protected]>2020-09-22 17:10:48 +0800
committerchenyingchun0312 <[email protected]>2020-09-22 17:10:48 +0800
commit797ce29ae0ed103d9684360dd931e58820ad7511 (patch)
tree619159c581c6cec8afdda8088bc987078dcca22f /components/libc/compilers/common/SConscript
parent02a609e33fbf811f043cd0c628b7d1266a4d41c2 (diff)
parent8302a7224302c0624b9918855a25e12f3a3ede59 (diff)
Merge remote-tracking branch 'upstream/master'
Diffstat (limited to 'components/libc/compilers/common/SConscript')
-rw-r--r--components/libc/compilers/common/SConscript11
1 files changed, 7 insertions, 4 deletions
diff --git a/components/libc/compilers/common/SConscript b/components/libc/compilers/common/SConscript
index a8d2606820..2407301405 100644
--- a/components/libc/compilers/common/SConscript
+++ b/components/libc/compilers/common/SConscript
@@ -8,12 +8,15 @@ group = []
CPPPATH = [cwd]
if GetDepend('RT_USING_LIBC'):
- src += Glob('*.c')
+ src += Glob('*.c')
else:
- if GetDepend('RT_LIBC_USING_TIME'):
+ if GetDepend('RT_LIBC_USING_TIME') and not GetDepend('RT_USING_MINILIBC'):
src += ['time.c']
-if (rtconfig.PLATFORM == 'armcc' or rtconfig.PLATFORM == 'iar') and rtconfig.ARCH != 'sim' :
- group = DefineGroup('libc', src, depend = [''], CPPPATH = CPPPATH)
+if GetDepend('RT_USING_POSIX') == False:
+ SrcRemove(src, ['unistd.c'])
+
+if not GetDepend('RT_USING_MINILIBC') and (GetDepend('RT_USING_LIBC') or GetDepend('RT_LIBC_USING_TIME')):
+ group = DefineGroup('libc', src, depend = [''], CPPPATH = CPPPATH)
Return('group')