[posix][libc] 优化libc中posix结构

This commit is contained in:
Meco Man
2021-10-26 00:51:32 -04:00
parent 50bb6e33d1
commit a9910a780e
36 changed files with 361 additions and 704 deletions

View File

@@ -7,16 +7,16 @@
* Date Author Notes
* 2017/10/15 bernard the first version
*/
#include <rtthread.h>
#ifdef RT_LIBC_USING_FILEIO
#include <stdio.h>
#include <stdlib.h>
#include <fcntl.h>
#include <rtthread.h>
#include "libc.h"
#define STDIO_DEVICE_NAME_MAX 32
int _EXFUN(fileno, (FILE *));
static FILE* std_console = NULL;
int libc_stdio_set_console(const char* device_name, int mode)
@@ -79,3 +79,5 @@ int libc_stdio_get_console(void)
else
return -1;
}
#endif /* RT_LIBC_USING_FILEIO */