// -*- mode: cpp; mode: fold -*-
// Description /*{{{*/
-// $Id: error.cc,v 1.6 1999/01/18 06:20:07 jgg Exp $
+// $Id: error.cc,v 1.7 1999/08/05 05:55:45 jgg Exp $
/* ######################################################################
Global Erorr Class - Global error mechanism
#include <stdarg.h>
#include <unistd.h>
+#include "config.h"
/*}}}*/
// Global Error Object /*{{{*/
is compiled to be thread safe otherwise a non-safe version is used. A
Per-Thread error object is maintained in much the same manner as libc
manages errno */
-#if _POSIX_THREADS == 1
+#if _POSIX_THREADS == 1 && defined(HAVE_PTHREAD)
#include <pthread.h>
+ #error PTHREAD
static pthread_key_t ErrorKey;
static void ErrorDestroy(void *Obj) {delete (GlobalError *)Obj;};
fi
dnl Checks for pthread
-AC_CHECK_LIB(pthread, pthread_create,[AC_DEFINE(HAVE_PTHREAD) PTHREADLIB="-lpthread"])
+#AC_CHECK_LIB(pthread, pthread_create,[AC_DEFINE(HAVE_PTHREAD) PTHREADLIB="-lpthread"])
AC_SUBST(PTHREADLIB)
#if test "$PTHREADLIB" != "-lpthread"; then
# AC_MSG_ERROR(failed: I need posix threads, pthread)