Complete.Org: Mailing Lists: Archives: freeciv-dev: March 2000:
[Freeciv-Dev] Re: Problems when compiling packets.c without HAVE_FCNTL_H
Home

[Freeciv-Dev] Re: Problems when compiling packets.c without HAVE_FCNTL_H

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: freeciv-dev@xxxxxxxxxxx
Subject: [Freeciv-Dev] Re: Problems when compiling packets.c without HAVE_FCNTL_H
From: Vasco Alexandre Da Silva Costa <vasc@xxxxxxxxxxxxxx>
Date: Sat, 18 Mar 2000 22:34:24 +0000 (WET)

On Sat, 18 Mar 2000, Sebastian Bauer wrote:

(snip...)

> But I don't think that the check only for fcntl.h in configure
> is enough. Actually I have this include file but it doesn't
> provide the fcntl() function (ok, I don't run configure anywhy
> but it's a little bit irritating).

Ok... That happens more than it should but lots of platforms try to
do some failed POSIX emulation.  I didn't see this problem comming though.

> I've written a patch which will change the configure script so
> it checks additional for the fcntl() function and ioctl().
> If fcntl() is not avaiable ioctl() is used if available to
> switch to the non-blocking mode. If one of both is available
> NONBLOCKING_SOCKETS is defined in config.h. This is used then in
> server/sernet.c and common/packets.c. Is this Ok?
> (also included the changes needed for the amiga version)

At first glance your changes seem fine to me.  Oh yes, i remembered right
now, Win32 also uses a ioctlsocket() call (notice the lowercase first
letter) similar to AmigaOS for non-blocking sockets.

(But we'll see that whenever we port the server to Win32).

---
Vasco Alexandre da Silva Costa @ Instituto Superior Tecnico, Lisboa




[Prev in Thread] Current Thread [Next in Thread]