Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'winsup/w32api/include')
-rw-r--r--winsup/w32api/include/windows.h2
-rw-r--r--winsup/w32api/include/winnt.h4
-rw-r--r--winsup/w32api/include/winsock.h32
-rw-r--r--winsup/w32api/include/winsock2.h32
4 files changed, 35 insertions, 35 deletions
diff --git a/winsup/w32api/include/windows.h b/winsup/w32api/include/windows.h
index 3b9273a97..64e70c99b 100644
--- a/winsup/w32api/include/windows.h
+++ b/winsup/w32api/include/windows.h
@@ -142,7 +142,7 @@
#define __USE_W32_SOCKETS
#endif
#endif
-#if defined(__USE_W32_SOCKETS) || !(defined(__INSIDE_CYGWIN__) || defined(__CYGWIN__) || defined(__CYGWIN32__) || defined(_UWIN))
+#if defined(__USE_W32_SOCKETS) || !(defined(__CYGWIN__) || defined(__MSYS__) || defined(_UWIN))
#if (_WIN32_WINNT >= 0x0400) && (__W32API_MAJOR_VERSION > 0)
#include <winsock2.h>
/*
diff --git a/winsup/w32api/include/winnt.h b/winsup/w32api/include/winnt.h
index 4e120770b..8e7c9f007 100644
--- a/winsup/w32api/include/winnt.h
+++ b/winsup/w32api/include/winnt.h
@@ -1705,7 +1705,7 @@ typedef union _LARGE_INTEGER {
DWORD LowPart;
LONG HighPart;
} u;
-#if _ANONYMOUS_STRUCT
+#if _ANONYMOUS_STRUCT || defined __cplusplus
struct {
DWORD LowPart;
LONG HighPart;
@@ -1718,7 +1718,7 @@ typedef union _ULARGE_INTEGER {
DWORD LowPart;
DWORD HighPart;
} u;
-#if _ANONYMOUS_STRUCT
+#if _ANONYMOUS_STRUCT || defined __cplusplus
struct {
DWORD LowPart;
DWORD HighPart;
diff --git a/winsup/w32api/include/winsock.h b/winsup/w32api/include/winsock.h
index 950dbc295..e88ad3b87 100644
--- a/winsup/w32api/include/winsock.h
+++ b/winsup/w32api/include/winsock.h
@@ -78,7 +78,7 @@ for (__i = 0; __i < ((fd_set *)(set))->fd_count ; __i++) {\
This can cause runtime problems with W32 sockets"
#endif /* ndef _SYS_TYPES_FD_SET */
-#ifndef __INSIDE_CYGWIN__
+#if !(defined (__INSIDE_CYGWIN__) || defined (__INSIDE_MSYS__))
struct timeval {
long tv_sec;
long tv_usec;
@@ -101,19 +101,19 @@ struct linger {
((tvp)->tv_sec cmp (uvp)->tv_sec) : \
((tvp)->tv_usec cmp (uvp)->tv_usec))
#define timerclear(tvp) (tvp)->tv_sec = (tvp)->tv_usec = 0
-#endif /* ndef __INSIDE_CYGWIN__ */
+#endif /* ! (__INSIDE_CYGWIN__ || __INSIDE_MSYS__) */
#define IOCPARM_MASK 0x7f
#define IOC_VOID 0x20000000
#define IOC_OUT 0x40000000
#define IOC_IN 0x80000000
#define IOC_INOUT (IOC_IN|IOC_OUT)
-#ifndef __INSIDE_CYGWIN__
+#if !(defined (__INSIDE_CYGWIN__) || defined (__INSIDE_MSYS__))
#define _IO(x,y) (IOC_VOID|((x)<<8)|(y))
#define _IOR(x,y,t) (IOC_OUT|(((long)sizeof(t)&IOCPARM_MASK)<<16)|((x)<<8)|(y))
#define _IOW(x,y,t) (IOC_IN|(((long)sizeof(t)&IOCPARM_MASK)<<16)|((x)<<8)|(y))
#define FIONBIO _IOW('f', 126, u_long)
-#endif /* ndef __INSIDE_CYGWIN__ */
+#endif /* ! (__INSIDE_CYGWIN__ || __INSIDE_MSYS__) */
#define FIONREAD _IOR('f', 127, u_long)
#define FIOASYNC _IOW('f', 125, u_long)
@@ -123,7 +123,7 @@ struct linger {
#define SIOCGLOWAT _IOR('s', 3, u_long)
#define SIOCATMARK _IOR('s', 7, u_long)
-#ifndef __INSIDE_CYGWIN__
+#if !(defined (__INSIDE_CYGWIN__) || defined (__INSIDE_MSYS__))
struct netent {
char * n_name;
char **n_aliases;
@@ -141,7 +141,7 @@ struct protoent {
char **p_aliases;
short p_proto;
};
-#endif /* __INSIDE_CYGWIN__ */
+#endif /* ! (__INSIDE_CYGWIN__ || __INSIDE_MSYS__) */
#define IPPROTO_IP 0
#define IPPROTO_ICMP 1
@@ -232,7 +232,7 @@ typedef struct WSAData {
} WSADATA;
typedef WSADATA *LPWSADATA;
-#ifndef __INSIDE_CYGWIN__
+#if !(defined (__INSIDE_CYGWIN__) || defined (__INSIDE_MSYS__))
#define IP_OPTIONS 1
#define SO_DEBUG 1
#define SO_ACCEPTCONN 2
@@ -252,7 +252,7 @@ typedef WSADATA *LPWSADATA;
#define SO_RCVTIMEO 0x1006
#define SO_ERROR 0x1007
#define SO_TYPE 0x1008
-#endif
+#endif /* ! (__INSIDE_CYGWIN__ || __INSIDE_MSYS__) */
/*
* Note that the next 5 IP defines are specific to WinSock 1.1 (wsock32.dll).
* They will cause errors or unexpected results if used with the
@@ -305,13 +305,13 @@ struct ip_mreq {
#define AF_BAN 21
#define AF_ATM 22
#define AF_INET6 23
-#ifndef __INSIDE_CYGWIN__
+#if !(defined (__INSIDE_CYGWIN__) || defined (__INSIDE_MSYS__))
#define AF_MAX 24
struct sockaddr {
u_short sa_family;
char sa_data[14];
};
-#endif /* ndef __INSIDE_CYGWIN__ */
+#endif /* ! (__INSIDE_CYGWIN__ || __INSIDE_MSYS__) */
struct sockproto {
u_short sp_family;
@@ -345,11 +345,11 @@ struct sockproto {
#define PF_MAX AF_MAX
#define SOL_SOCKET 0xffff
#define SOMAXCONN 5
-#ifndef __INSIDE_CYGWIN__
+#if !(defined (__INSIDE_CYGWIN__) || defined (__INSIDE_MSYS__))
#define MSG_OOB 1
#define MSG_PEEK 2
#define MSG_DONTROUTE 4
-#endif /* ndef __INSIDE_CYGWIN__ */
+#endif /* ! (__INSIDE_CYGWIN__ || __INSIDE_MSYS__) */
#define MSG_MAXIOVLEN 16
#define MSG_PARTIAL 0x8000
#define MAXGETHOSTSTRUCT 1024
@@ -412,14 +412,14 @@ struct sockproto {
#define WSANO_RECOVERY (WSABASEERR+1003)
#define WSANO_DATA (WSABASEERR+1004)
#define WSANO_ADDRESS WSANO_DATA
-#ifndef __INSIDE_CYGWIN__
+#if !(defined (__INSIDE_CYGWIN__) || defined (__INSIDE_MSYS__))
#define h_errno WSAGetLastError()
#define HOST_NOT_FOUND WSAHOST_NOT_FOUND
#define TRY_AGAIN WSATRY_AGAIN
#define NO_RECOVERY WSANO_RECOVERY
#define NO_DATA WSANO_DATA
#define NO_ADDRESS WSANO_ADDRESS
-#endif
+#endif /* ! (__INSIDE_CYGWIN__ || __INSIDE_MSYS__) */
SOCKET PASCAL accept(SOCKET,struct sockaddr*,int*);
int PASCAL bind(SOCKET,const struct sockaddr*,int);
int PASCAL closesocket(SOCKET);
@@ -460,14 +460,14 @@ HANDLE PASCAL WSAAsyncGetHostByName(HWND,u_int,const char*,char*,int);
HANDLE PASCAL WSAAsyncGetHostByAddr(HWND,u_int,const char*,int,int,char*,int);
int PASCAL WSACancelAsyncRequest(HANDLE);
int PASCAL WSAAsyncSelect(SOCKET,HWND,u_int,long);
-#ifndef __INSIDE_CYGWIN__
+#if !(defined (__INSIDE_CYGWIN__) || defined (__INSIDE_MSYS__))
u_long PASCAL htonl(u_long);
u_long PASCAL ntohl(u_long);
u_short PASCAL htons(u_short);
u_short PASCAL ntohs(u_short);
int PASCAL select(int nfds,fd_set*,fd_set*,fd_set*,const struct timeval*);
int PASCAL gethostname(char*,int);
-#endif /* ndef __INSIDE_CYGWIN__ */
+#endif /* ! (__INSIDE_CYGWIN__ || __INSIDE_MSYS__) */
#define WSAMAKEASYNCREPLY(b,e) MAKELONG(b,e)
#define WSAMAKESELECTREPLY(e,error) MAKELONG(e,error)
diff --git a/winsup/w32api/include/winsock2.h b/winsup/w32api/include/winsock2.h
index 83c48faec..0de258c7c 100644
--- a/winsup/w32api/include/winsock2.h
+++ b/winsup/w32api/include/winsock2.h
@@ -91,7 +91,7 @@ if (__i == ((fd_set *)(set))->fd_count) {\
#warning "fd_set and associated macros have been defined in sys/types. \
This may cause runtime problems with W32 sockets"
#endif /* ndef _SYS_TYPES_FD_SET */
-#ifndef __INSIDE_CYGWIN__
+#if !(defined (__INSIDE_CYGWIN__) || (__INSIDE_MSYS__))
struct timeval {
long tv_sec;
long tv_usec;
@@ -114,19 +114,19 @@ struct linger {
((tvp)->tv_sec cmp (uvp)->tv_sec) : \
((tvp)->tv_usec cmp (uvp)->tv_usec))
#define timerclear(tvp) (tvp)->tv_sec = (tvp)->tv_usec = 0
-#endif /* ndef __INSIDE_CYGWIN__ */
+#endif /* ! (__INSIDE_CYGWIN__ || __INSIDE_MSYS__) */
#define IOCPARM_MASK 0x7f
#define IOC_VOID 0x20000000
#define IOC_OUT 0x40000000
#define IOC_IN 0x80000000
#define IOC_INOUT (IOC_IN|IOC_OUT)
-#ifndef __INSIDE_CYGWIN__
+#if ! (defined (__INSIDE_CYGWIN__) || defined (__INSIDE_MSYS__))
#define _IO(x,y) (IOC_VOID|((x)<<8)|(y))
#define _IOR(x,y,t) (IOC_OUT|(((long)sizeof(t)&IOCPARM_MASK)<<16)|((x)<<8)|(y))
#define _IOW(x,y,t) (IOC_IN|(((long)sizeof(t)&IOCPARM_MASK)<<16)|((x)<<8)|(y))
#define FIONBIO _IOW('f', 126, u_long)
-#endif /* ndef __INSIDE_CYGWIN__ */
+#endif /* ! (__INSIDE_CYGWIN__ || __INSIDE_MSYS__) */
#define FIONREAD _IOR('f', 127, u_long)
#define FIOASYNC _IOW('f', 125, u_long)
@@ -136,7 +136,7 @@ struct linger {
#define SIOCGLOWAT _IOR('s', 3, u_long)
#define SIOCATMARK _IOR('s', 7, u_long)
-#ifndef __INSIDE_CYGWIN__
+#if ! (defined (__INSIDE_CYGWIN__) || defined (__INSIDE_MSYS__))
struct netent {
char * n_name;
char **n_aliases;
@@ -154,7 +154,7 @@ struct protoent {
char **p_aliases;
short p_proto;
};
-#endif /* __INSIDE_CYGWIN__ */
+#endif /* ! (__INSIDE_CYGWIN__ || __INSIDE_MSYS__) */
#define IPPROTO_IP 0
#define IPPROTO_ICMP 1
@@ -245,7 +245,7 @@ typedef struct WSAData {
} WSADATA;
typedef WSADATA *LPWSADATA;
-#ifndef __INSIDE_CYGWIN__
+#if ! (defined (__INSIDE_CYGWIN__) || defined (__INSIDE_MSYS__))
#define IP_OPTIONS 1
#define SO_DEBUG 1
#define SO_ACCEPTCONN 2
@@ -265,7 +265,7 @@ typedef WSADATA *LPWSADATA;
#define SO_RCVTIMEO 0x1006
#define SO_ERROR 0x1007
#define SO_TYPE 0x1008
-#endif
+#endif ./* ! (__INSIDE_CYGWIN__ || __INSIDE_MSYS__) */
#define INVALID_SOCKET (SOCKET)(~0)
#define SOCKET_ERROR (-1)
@@ -305,13 +305,13 @@ typedef WSADATA *LPWSADATA;
#define AF_12844 25
#define AF_IRDA 26
#define AF_NETDES 28
-#ifndef __INSIDE_CYGWIN__
+#if !(defined (__INSIDE_CYGWIN__) || defined (__INSIDE_MSYS__))
#define AF_MAX 29
struct sockaddr {
u_short sa_family;
char sa_data[14];
};
-#endif /* ndef __INSIDE_CYGWIN__ */
+#endif /* ! (__INSIDE_CYGWIN__ || __INSIDE_MSYS__) */
struct sockproto {
u_short sp_family;
@@ -344,12 +344,12 @@ struct sockproto {
#define PF_INET6 AF_INET6
#define PF_MAX AF_MAX
#define SOL_SOCKET 0xffff
-#ifndef __INSIDE_CYGWIN__
+#if ! (defined (__INSIDE_CYGWIN__) || defined (__INSIDE_MSYS__))
#define SOMAXCONN 0x7fffffff /* (5) in WinSock1.1 */
#define MSG_OOB 1
#define MSG_PEEK 2
#define MSG_DONTROUTE 4
-#endif /* ndef __INSIDE_CYGWIN__ */
+#endif /* ! (__INSIDE_CYGWIN__ || __INSIDE_MSYS__) */
#define MSG_MAXIOVLEN 16
#define MSG_PARTIAL 0x8000
#define MAXGETHOSTSTRUCT 1024
@@ -431,14 +431,14 @@ struct sockproto {
#define WSANO_RECOVERY (WSABASEERR+1003)
#define WSANO_DATA (WSABASEERR+1004)
#define WSANO_ADDRESS WSANO_DATA
-#ifndef __INSIDE_CYGWIN__
+#if !(defined (__INSIDE_CYGWIN__) || defined (__INSIDE_MSYS__))
#define h_errno WSAGetLastError()
#define HOST_NOT_FOUND WSAHOST_NOT_FOUND
#define TRY_AGAIN WSATRY_AGAIN
#define NO_RECOVERY WSANO_RECOVERY
#define NO_DATA WSANO_DATA
#define NO_ADDRESS WSANO_ADDRESS
-#endif
+#endif /* ! (__INSIDE_CYGWIN__ || __INSIDE_MSYS__) */
SOCKET PASCAL accept(SOCKET,struct sockaddr*,int*);
int PASCAL bind(SOCKET,const struct sockaddr*,int);
int PASCAL closesocket(SOCKET);
@@ -484,14 +484,14 @@ HANDLE PASCAL WSAAsyncGetHostByName(HWND,u_int,const char*,char*,int);
HANDLE PASCAL WSAAsyncGetHostByAddr(HWND,u_int,const char*,int,int,char*,int);
int PASCAL WSACancelAsyncRequest(HANDLE);
int PASCAL WSAAsyncSelect(SOCKET,HWND,u_int,long);
-#ifndef __INSIDE_CYGWIN__
+#if ! (defined (__INSIDE_CYGWIN__) || defined (__INSIDE_MSYS__))
u_long PASCAL htonl(u_long);
u_long PASCAL ntohl(u_long);
u_short PASCAL htons(u_short);
u_short PASCAL ntohs(u_short);
int PASCAL select(int nfds,fd_set*,fd_set*,fd_set*,const struct timeval*);
int PASCAL gethostname(char*,int);
-#endif /* ndef __INSIDE_CYGWIN__ */
+#endif /* ! (__INSIDE_CYGWIN__ || __INSIDE_MSYS__) */
#define WSAMAKEASYNCREPLY(b,e) MAKELONG(b,e)
#define WSAMAKESELECTREPLY(e,error) MAKELONG(e,error)