1 |
|
/* |
2 |
|
* timer_unix.cpp - Time Manager emulation, Unix specific stuff |
3 |
|
* |
4 |
< |
* Basilisk II (C) 1997-2001 Christian Bauer |
4 |
> |
* Basilisk II (C) 1997-2005 Christian Bauer |
5 |
|
* |
6 |
|
* This program is free software; you can redistribute it and/or modify |
7 |
|
* it under the terms of the GNU General Public License as published by |
228 |
|
// Linux select() changes its timeout parameter upon return to contain |
229 |
|
// the remaining time. Most other unixen leave it unchanged or undefined. |
230 |
|
#define SELECT_SETS_REMAINING |
231 |
< |
#elif defined(__FreeBSD__) || defined(__sun__) |
231 |
> |
#elif defined(__FreeBSD__) || defined(__sun__) || (defined(__MACH__) && defined(__APPLE__)) |
232 |
|
#define USE_NANOSLEEP |
233 |
|
#elif defined(HAVE_PTHREADS) && defined(sgi) |
234 |
|
// SGI pthreads has a bug when using pthreads+signals+nanosleep, |
235 |
|
// so instead of using nanosleep, wait on a CV which is never signalled. |
236 |
+ |
#include <pthread.h> |
237 |
|
#define USE_COND_TIMEDWAIT |
238 |
|
#endif |
239 |
|
|