-
-#if defined( HAVE_PTHREADS )
-/**********************************
- * *
- * definitions for POSIX Threads *
- * *
- **********************************/
-
-#include <pthread.h>
-#ifdef HAVE_SCHED_H
-#include <sched.h>
-#endif
-
-LDAP_BEGIN_DECL
-
-typedef pthread_t ldap_pvt_thread_t;
-typedef pthread_mutex_t ldap_pvt_thread_mutex_t;
-typedef pthread_cond_t ldap_pvt_thread_cond_t;
-
-#if defined( _POSIX_REENTRANT_FUNCTIONS ) || \
- defined( _POSIX_THREAD_SAFE_FUNCTIONS ) || \
- defined( _POSIX_THREADSAFE_FUNCTIONS )
-#define HAVE_REENTRANT_FUNCTIONS 1
-#endif
-
-#if defined( HAVE_PTHREAD_GETCONCURRENCY ) || \
- defined( HAVE_THR_GETCONCURRENCY )
-#define HAVE_GETCONCURRENCY 1
-#endif
-
-#if defined( HAVE_PTHREAD_SETCONCURRENCY ) || \
- defined( HAVE_THR_SETCONCURRENCY )
-#define HAVE_SETCONCURRENCY 1
-#endif
-
-LDAP_END_DECL
-
-#elif defined ( HAVE_MACH_CTHREADS )
-/**********************************
- * *
- * definitions for Mach CThreads *
- * *
- **********************************/
-
-#include <mach/cthreads.h>
-
-LDAP_BEGIN_DECL
-
-typedef cthread_t ldap_pvt_thread_t;
-typedef struct mutex ldap_pvt_thread_mutex_t;
-typedef struct condition ldap_pvt_thread_cond_t;
-
-LDAP_END_DECL
-
-#elif defined( HAVE_THR )
-/********************************************
- * *
- * thread definitions for Solaris LWP (THR) *
- * *
- ********************************************/
-
-#include <thread.h>
-#include <synch.h>
-
-LDAP_BEGIN_DECL
-
-typedef thread_t ldap_pvt_thread_t;
-typedef mutex_t ldap_pvt_thread_mutex_t;
-typedef cond_t ldap_pvt_thread_cond_t;
-
-#define HAVE_REENTRANT_FUNCTIONS 1
-
-#ifdef HAVE_THR_GETCONCURRENCY
-#define HAVE_GETCONCURRENCY 1
-#endif
-#ifdef HAVE_THR_SETCONCURRENCY
-#define HAVE_SETCONCURRENCY 1
-#endif
-
-LDAP_END_DECL
-
-#elif defined( HAVE_LWP )
-/*************************************
- * *
- * thread definitions for SunOS LWP *
- * *
- *************************************/
-
-#include <lwp/lwp.h>
-#include <lwp/stackdep.h>
-
-LDAP_BEGIN_DECL
-
-typedef thread_t ldap_pvt_thread_t;
-typedef mon_t ldap_pvt_thread_mutex_t;
-struct lwpcv {
- int lcv_created;
- cv_t lcv_cv;
-};
-typedef struct lwpcv ldap_pvt_thread_cond_t;
-
-#define HAVE_REENTRANT_FUNCTIONS 1
-
-LDAP_END_DECL
-
-#elif HAVE_NT_THREADS
-
-#include <windows.h>
-#include <process.h>