From 8a38307e2cce628017e9eb7153ae7a2430a3d9ef Mon Sep 17 00:00:00 2001 From: bernard Date: Tue, 17 Oct 2017 22:27:06 +0800 Subject: [libc] Add RT_USING_POSIX macro. 1. Add macro check in rtdebug.h; 2. Use RT_USING_POSIX for poll/select, stdin etc. 3. Split dfs_posix.h to dfs_posix.h, dfs_poll.h and dfs_select.h; --- components/libc/compilers/dlib/syscall_read.c | 2 +- components/libc/compilers/dlib/syscall_write.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'components/libc/compilers/dlib') diff --git a/components/libc/compilers/dlib/syscall_read.c b/components/libc/compilers/dlib/syscall_read.c index 9dcaa9df65..e7e99629d7 100644 --- a/components/libc/compilers/dlib/syscall_read.c +++ b/components/libc/compilers/dlib/syscall_read.c @@ -38,7 +38,7 @@ size_t __read(int handle, unsigned char *buf, size_t len) if (handle == _LLIO_STDIN) { -#ifdef RT_USING_POSIX_STDIN +#ifdef RT_USING_POSIX return libc_stdio_read(buf, len); #else return _LLIO_ERROR; diff --git a/components/libc/compilers/dlib/syscall_write.c b/components/libc/compilers/dlib/syscall_write.c index e2cb04000b..79d702339a 100644 --- a/components/libc/compilers/dlib/syscall_write.c +++ b/components/libc/compilers/dlib/syscall_write.c @@ -43,7 +43,7 @@ size_t __write(int handle, const unsigned char *buf, size_t len) return _LLIO_ERROR; #else -#ifdef RT_USING_POSIX_STDIN +#ifdef RT_USING_POSIX return libc_stdio_write((void*)buf, len); #else rt_device_t console_device; -- cgit v1.3.1