+2005-01-17 Ranjit Mathew <rmathew@hotmail.com>
+
+ * gthr-posix.h (__gthread_active_p): Use pthread_cancel instead
+ of pthread_create to find out if threads are enabled.
+ * gthr-posix95.h (__gthread_active_p): Likewise.
+
2005-01-17 Ira Rosen <irar@il.ibm.com>
* fortran/f95-lang.c (gfc_init_builtin_functions): Call
/* Threads compatibility routines for libgcc2 and libobjc. */
/* Compile this one with gcc. */
-/* Copyright (C) 1997, 1999, 2000, 2001, 2002, 2003, 2004
+/* Copyright (C) 1997, 1999, 2000, 2001, 2002, 2003, 2004, 2005
Free Software Foundation, Inc.
This file is part of GCC.
#pragma weak pthread_getspecific
#pragma weak pthread_setspecific
#pragma weak pthread_create
+#pragma weak pthread_cancel
#pragma weak pthread_mutex_lock
#pragma weak pthread_mutex_trylock
__gthread_active_p (void)
{
static void *const __gthread_active_ptr
- = __extension__ (void *) &pthread_create;
+ = __extension__ (void *) &pthread_cancel;
return __gthread_active_ptr != 0;
}
/* Threads compatibility routines for libgcc2 and libobjc. */
/* Compile this one with gcc. */
-/* Copyright (C) 2004 Free Software Foundation, Inc.
+/* Copyright (C) 2004, 2005 Free Software Foundation, Inc.
This file is part of GCC.
#pragma weak pthread_getspecific
#pragma weak pthread_setspecific
#pragma weak pthread_create
+#pragma weak pthread_cancel
#pragma weak pthread_self
#pragma weak pthread_mutex_lock
__gthread_active_p (void)
{
static void *const __gthread_active_ptr
- = __extension__ (void *) &pthread_create;
+ = __extension__ (void *) &pthread_cancel;
return __gthread_active_ptr != 0;
}