fix mingw for eio

This commit is contained in:
Henry Rawas 2011-07-01 10:58:01 -07:00 committed by Ryan Dahl
parent 35e1c62676
commit ba1c38f2d8
2 changed files with 15 additions and 2 deletions

View File

@ -34,8 +34,8 @@ RUNNER_LINKFLAGS=$(LINKFLAGS)
RUNNER_LIBS=-lws2_32
RUNNER_SRC=test/runner-win.c
uv.a: uv-win.o uv-common.o $(CARES_OBJS)
$(AR) rcs uv.a uv-win.o uv-common.o $(CARES_OBJS)
uv.a: uv-win.o uv-common.o uv-eio.o eio/eio.o $(CARES_OBJS)
$(AR) rcs uv.a uv-win.o uv-common.o uv-eio.o eio/eio.o $(CARES_OBJS)
uv-win.o: uv-win.c uv.h uv-win.h
$(CC) $(CFLAGS) -c uv-win.c -o uv-win.o
@ -43,6 +43,17 @@ uv-win.o: uv-win.c uv.h uv-win.h
uv-common.o: uv-common.c uv.h uv-win.h
$(CC) $(CFLAGS) -c uv-common.c -o uv-common.o
EIO_CPPFLAGS += $(CPPFLAGS)
EIO_CPPFLAGS += -DEIO_CONFIG_H=\"$(EIO_CONFIG)\"
EIO_CPPFLAGS += -DEIO_STACKSIZE=65536
EIO_CPPFLAGS += -D_GNU_SOURCE
eio/eio.o: eio/eio.c
$(CC) $(EIO_CPPFLAGS) $(CFLAGS) -c eio/eio.c -o eio/eio.o
uv-eio.o: uv-eio.c
$(CC) $(CPPFLAGS) -Ieio/ $(CFLAGS) -c uv-eio.c -o uv-eio.o
clean-platform:
-rm -f c-ares/*.o

View File

@ -22,7 +22,9 @@ typedef int ssize_t
#endif
#define NTDDI_VERSION NTDDI_WIN2K // needed to get win2000 api calls
#ifndef _WIN32_WINNT
#define _WIN32_WINNT 0x400
#endif
#include <stdio.h>//D
#include <fcntl.h>
#include <io.h>