From: rsandifo Date: Wed, 14 Mar 2007 13:58:21 +0000 (+0000) Subject: gcc/ X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=efe5559cf8684fd0d186df505ac5246722ec3901;p=thirdparty%2Fgcc.git gcc/ 200x-xx-xx Richard Sandiford Phil Edwards * gthr-vxworks.h: Add an extern "C" wrapper for C++. (__gthread_once_t): Remove busy field for RTPs. (__GTHREAD_ONCE_INIT): Update accordingly. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@122923 138bc75d-0d04-0410-961f-82ee72b054a4 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index dcbe122aabc7..9cb848dcd0e8 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,10 @@ +2007-03-14 Richard Sandiford + Phil Edwards + + * gthr-vxworks.h: Add an extern "C" wrapper for C++. + (__gthread_once_t): Remove busy field for RTPs. + (__GTHREAD_ONCE_INIT): Update accordingly. + 2007-03-14 Richard Sandiford * doc/invoke.texi: Document VxWorks options. diff --git a/gcc/gthr-vxworks.h b/gcc/gthr-vxworks.h index 5ff5234219fc..c11d3a20cabb 100644 --- a/gcc/gthr-vxworks.h +++ b/gcc/gthr-vxworks.h @@ -37,6 +37,10 @@ Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA #else +#ifdef __cplusplus +extern "C" { +#endif + #define __GTHREADS 1 #define __gthread_active_p() 1 @@ -103,12 +107,18 @@ __gthread_recursive_mutex_unlock (__gthread_recursive_mutex_t *mutex) typedef struct { +#ifndef __RTP__ volatile unsigned char busy; +#endif volatile unsigned char done; } __gthread_once_t; -#define __GTHREAD_ONCE_INIT { 0, 0 } +#ifndef __RTP__ +# define __GTHREAD_ONCE_INIT { 0, 0 } +#else +# define __GTHREAD_ONCE_INIT { 0 } +#endif extern int __gthread_once (__gthread_once_t *once, void (*func)(void)); @@ -125,6 +135,10 @@ extern int __gthread_key_delete (__gthread_key_t key); extern void *__gthread_getspecific (__gthread_key_t key); extern int __gthread_setspecific (__gthread_key_t key, void *ptr); +#ifdef __cplusplus +} +#endif + #endif /* not _LIBOBJC */ #endif /* gthr-vxworks.h */