OpenCores
URL https://opencores.org/ocsvn/or1k/or1k/trunk

Subversion Repositories or1k

[/] [or1k/] [trunk/] [newlib/] [newlib/] [libc/] [include/] [sys/] [types.h] - Diff between revs 39 and 56

Go to most recent revision | Show entire file | Details | Blame | View Log

Rev 39 Rev 56
Line 16... Line 16...
 */
 */
 
 
#ifndef _SYS_TYPES_H
#ifndef _SYS_TYPES_H
#define _SYS_TYPES_H
#define _SYS_TYPES_H
 
 
 
#if defined (_WIN32) || defined (__CYGWIN__)
 
#define __MS_types__
 
#endif
 
 
#ifdef __i386__
#ifdef __i386__
#if defined (GO32) || defined (__MSDOS__) || defined (_WIN32)
#if defined (GO32) || defined (__MSDOS__)
#define __MS_types__
#define __MS_types__
#endif
#endif
#endif
#endif
 
 
# include <stddef.h>
# include <stddef.h>
Line 43... Line 47...
# ifndef        _POSIX_SOURCE
# ifndef        _POSIX_SOURCE
 
 
#  define       physadr         physadr_t
#  define       physadr         physadr_t
#  define       quad            quad_t
#  define       quad            quad_t
 
 
#ifndef _GNU_H_WINDOWS32_SOCKETS
#ifndef _WINSOCK_H
typedef unsigned char   u_char;
typedef unsigned char   u_char;
typedef unsigned short  u_short;
typedef unsigned short  u_short;
typedef unsigned int    u_int;
typedef unsigned int    u_int;
typedef unsigned long   u_long;
typedef unsigned long   u_long;
#endif
#endif
Line 128... Line 132...
/* We don't define fd_set and friends if we are compiling POSIX
/* We don't define fd_set and friends if we are compiling POSIX
   source, or if we have included the Windows Sockets.h header (which
   source, or if we have included the Windows Sockets.h header (which
   defines Windows versions of them).  Note that a program which
   defines Windows versions of them).  Note that a program which
   includes the Windows sockets.h header must know what it is doing;
   includes the Windows sockets.h header must know what it is doing;
   it must not call the cygwin32 select function.  */
   it must not call the cygwin32 select function.  */
# if ! defined (_POSIX_SOURCE) && ! defined (_GNU_H_WINDOWS32_SOCKETS)
# if ! defined (_POSIX_SOURCE) && ! defined (_WINSOCK_H)
 
 
#  define       NBBY    8               /* number of bits in a byte */
#  define       NBBY    8               /* number of bits in a byte */
/*
/*
 * Select uses bit masks of file descriptors in longs.
 * Select uses bit masks of file descriptors in longs.
 * These macros manipulate such bit fields (the filesystem macros use chars).
 * These macros manipulate such bit fields (the filesystem macros use chars).
Line 160... Line 164...
#  define       FD_SET(n, p)    ((p)->fds_bits[(n)/NFDBITS] |= (1L << ((n) % NFDBITS)))
#  define       FD_SET(n, p)    ((p)->fds_bits[(n)/NFDBITS] |= (1L << ((n) % NFDBITS)))
#  define       FD_CLR(n, p)    ((p)->fds_bits[(n)/NFDBITS] &= ~(1L << ((n) % NFDBITS)))
#  define       FD_CLR(n, p)    ((p)->fds_bits[(n)/NFDBITS] &= ~(1L << ((n) % NFDBITS)))
#  define       FD_ISSET(n, p)  ((p)->fds_bits[(n)/NFDBITS] & (1L << ((n) % NFDBITS)))
#  define       FD_ISSET(n, p)  ((p)->fds_bits[(n)/NFDBITS] & (1L << ((n) % NFDBITS)))
#  define       FD_ZERO(p)      bzero((caddr_t)(p), sizeof (*(p)))
#  define       FD_ZERO(p)      bzero((caddr_t)(p), sizeof (*(p)))
 
 
# endif /* ! defined (_POSIX_SOURCE) && ! defined (GNU_H_WINDOWS32_SOCKETS) */
# endif /* ! defined (_POSIX_SOURCE) && ! defined (_WINSOCK_H) */
 
 
#undef __MS_types__
#undef __MS_types__
#undef _ST_INT32
#undef _ST_INT32
 
 
#endif  /* _SYS_TYPES_H */
#endif  /* _SYS_TYPES_H */

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.