Преглед на файлове

[LIBC] remove minilibc when compiling simulator under Linux

Bernard Xiong преди 9 години
родител
ревизия
fd7a65b4be
променени са 2 файла, в които са добавени 4 реда и са изтрити 2 реда
  1. 3 1
      bsp/simulator/drivers/sd_sim.c
  2. 1 1
      components/libc/SConscript

+ 3 - 1
bsp/simulator/drivers/sd_sim.c

@@ -1,6 +1,8 @@
 #include <stdio.h>
-#include <stdlib.h>
 #include <string.h>
+#ifdef _WIN32
+#include <stdlib.h>
+#endif
 
 #include <rtthread.h>
 #include <dfs_def.h>

+ 1 - 1
components/libc/SConscript

@@ -14,7 +14,7 @@ if GetDepend('RT_USING_LIBC'):
     elif rtconfig.PLATFORM == 'iar':
         objs = objs + SConscript('dlib/SConscript')
 else:
-    if rtconfig.PLATFORM == 'gcc':
+    if rtconfig.PLATFORM == 'gcc' and rtconfig.ARCH != 'sim':
         objs = objs + SConscript('minilibc/SConscript')
 
 Return('objs')