diff options
| author | Meco Man <[email protected]> | 2021-12-22 19:21:52 -0500 |
|---|---|---|
| committer | Bernard Xiong <[email protected]> | 2021-12-29 12:10:02 +0800 |
| commit | 29b73ecb6f75c53d36a7e03dde7bdafd464b08d9 (patch) | |
| tree | 0b9bc6e89daf6213559ee38de1287eccbf96180e /components/libc/compilers/common | |
| parent | 78fa23bebe7c9a1ce1bccf417130affabf2310e8 (diff) | |
[newlib] 处理newlib版本不一致导致的问题
Diffstat (limited to 'components/libc/compilers/common')
| -rw-r--r-- | components/libc/compilers/common/nogcc/sys/select.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/components/libc/compilers/common/nogcc/sys/select.h b/components/libc/compilers/common/nogcc/sys/select.h index 02fb77dd89..44f9b4ed91 100644 --- a/components/libc/compilers/common/nogcc/sys/select.h +++ b/components/libc/compilers/common/nogcc/sys/select.h @@ -6,6 +6,7 @@ * Change Logs: * Date Author Notes * 2021-07-21 Meco Man The first version + * 2021-12-25 Meco Man Handle newlib 2.2.0 or lower version */ #ifndef __SYS_SELECT_H__ @@ -33,13 +34,12 @@ typedef long fd_mask; #ifndef _WIN32 -#ifndef _SYS_TYPES_FD_SET /* MIPS */ - +#ifndef _SYS_TYPES_FD_SET /* Newlib 2.2.0 or lower version */ #define NBBY 8 /* number of bits in a byte */ #define NFDBITS (sizeof (fd_mask) * NBBY) /* bits per mask */ #ifndef howmany #define howmany(x,y) (((x)+((y)-1))/(y)) -#endif +#endif /* howmany */ typedef struct _types_fd_set { fd_mask fds_bits[howmany(FD_SETSIZE, NFDBITS)]; |
