1
0
Эх сурвалжийг харах

[bug fix]对各个libc库的termios.h增加宏定义,以防止在termios函数没有定义时,将posix_termios.h头文件引入导致报错

mysterywolf 4 жил өмнө
parent
commit
f13014526c

+ 2 - 0
components/libc/compilers/armlibc/termios.h

@@ -9,7 +9,9 @@
 #ifndef _TERMIOS_H__
 #define _TERMIOS_H__
 
+#ifdef RT_USING_POSIX_TERMIOS
 #include <sys/types.h>
 #include <posix_termios.h>
+#endif
 
 #endif

+ 2 - 0
components/libc/compilers/dlib/termios.h

@@ -9,7 +9,9 @@
 #ifndef _TERMIOS_H__
 #define _TERMIOS_H__
 
+#ifdef RT_USING_POSIX_TERMIOS
 #include <sys/types.h>
 #include <posix_termios.h>
+#endif
 
 #endif

+ 2 - 0
components/libc/compilers/newlib/termios.h

@@ -9,7 +9,9 @@
 #ifndef _TERMIOS_H__
 #define _TERMIOS_H__
 
+#ifdef RT_USING_POSIX_TERMIOS
 #include <sys/types.h>
 #include <posix_termios.h>
+#endif
 
 #endif