8 #define WIN32_LEAN_AND_MEAN
11 typedef DWORD althread_key_t
;
12 int althread_key_create(althread_key_t
*key
, void (*callback
)(void*));
13 int althread_key_delete(althread_key_t key
);
14 void *althread_getspecific(althread_key_t key
);
15 int althread_setspecific(althread_key_t key
, void *val
);
17 typedef LONG althread_once_t
;
18 #define ALTHREAD_ONCE_INIT 0
19 void althread_once(althread_once_t
*once
, void (*callback
)(void));
21 inline int alsched_yield(void)
22 { SwitchToThread(); return 0; }
24 WCHAR
*strdupW(const WCHAR
*str
);
26 #define HAVE_DYNLOAD 1
32 typedef pthread_mutex_t CRITICAL_SECTION
;
33 void InitializeCriticalSection(CRITICAL_SECTION
*cs
);
34 void DeleteCriticalSection(CRITICAL_SECTION
*cs
);
35 void EnterCriticalSection(CRITICAL_SECTION
*cs
);
36 void LeaveCriticalSection(CRITICAL_SECTION
*cs
);
38 ALuint
timeGetTime(void);
41 #define althread_key_t pthread_key_t
42 #define althread_key_create pthread_key_create
43 #define althread_key_delete pthread_key_delete
44 #define althread_getspecific pthread_getspecific
45 #define althread_setspecific pthread_setspecific
47 #define althread_once_t pthread_once_t
48 #define ALTHREAD_ONCE_INIT PTHREAD_ONCE_INIT
49 #define althread_once pthread_once
51 #define alsched_yield sched_yield
53 #if defined(HAVE_DLFCN_H) && !defined(IN_IDE_PARSER)
54 #define HAVE_DYNLOAD 1
60 void *LoadLib(const char *name
);
61 void CloseLib(void *handle
);
62 void *GetSymbol(void *handle
, const char *name
);
65 #endif /* AL_COMPAT_H */