Commit 92a747a7 authored by sof's avatar sof
Browse files

[project @ 1999-07-03 19:15:26 by sof]

Don't use WinSock under cygwin
parent e95d9ed1
......@@ -1252,7 +1252,7 @@ use @withSocketsDo@...:
\begin{code}
withSocketsDo :: IO a -> IO a
#ifndef _WIN32
#if !defined(HAVE_WINSOCK_H) || defined(__CYGWIN32__)
withSocketsDo x = x
#else
withSocketsDo act = do
......
#ifndef GHC_SOCKETS_H
#define GHC_SOCKETS_H
#ifdef HAVE_WINSOCK_H
#if defined(HAVE_WINSOCK_H) && !defined(__CYGWIN__)
#include <winsock.h>
#else
......@@ -94,7 +94,7 @@ StgInt setSocketOption__ (StgInt, StgInt, StgInt);
StgInt writeDescriptor (StgInt, StgAddr, StgInt);
/* initWinSock.c */
#ifdef _WIN32
#if defined(HAVE_WINSOCK_H) && !defined(__CYGWIN__)
StgInt initWinSock();
void shutdownWinSock();
#endif
......
......@@ -5,10 +5,13 @@
#include "stgio.h"
#ifdef _WIN32
#if defined(HAVE_WINSOCK_H) && !defined(__CYGWIN__)
#define USE_WINSOCK
#endif
/* Initialising WinSock... */
#ifdef USE_WINSOCK
/* Initialising WinSock... */
StgInt
initWinSock ()
{
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment