[Asterisk-Dev] PTHREAD_MUTEX_RECURSIVE

Sam Bingner sam at bingner.com
Sat Jun 19 05:01:37 MST 2004


You have to look at features.h

#ifdef  _GNU_SOURCE
# define __USE_GNU      1
#endif

Then if you look in pthread.h for __USE_GNU you find it a billion places.
It's the same on every version I've seen so far, including redhat 9.

Sam


-----Original Message-----
From: asterisk-dev-admin at lists.digium.com
[mailto:asterisk-dev-admin at lists.digium.com] On Behalf Of Dr. Rich Murphey
Sent: Friday, June 18, 2004 11:10 PM
To: asterisk-dev at lists.digium.com
Subject: RE: [Asterisk-Dev] PTHREAD_MUTEX_RECURSIVE


Perhaps that's a difference between redhat and others? _GNU_SOURCE doesn't
appear in pthread.h on redhat 9.

Cheers,
Rich


> -----Original Message-----
> From: asterisk-dev-admin at lists.digium.com [mailto:asterisk-dev-
> admin at lists.digium.com] On Behalf Of steve at daviesfam.org
> Sent: Saturday, June 19, 2004 1:18 AM
> To: asterisk-dev at lists.digium.com
> Subject: RE: [Asterisk-Dev] PTHREAD_MUTEX_RECURSIVE
>
>
>
> On Fri, 18 Jun 2004, Dr. Rich Murphey wrote:
>
> > PTHREAD_MUTEX_RECURSIVE is generally defined by the OS or system.
> > In general it would be defined in pthread.h.
> >
> > You have a native posix library I believe, so there must be an
> appropriate
> > header to define it, if it's not pthread.h.
> >
> > Cheers,
> > Rich
>
> IIRC, you need to #define _GNU_SOURCE before the includes.
>
> Check pthread.h and look at the #ifdefs.
>
> Steve
> _______________________________________________
> Asterisk-Dev mailing list
> Asterisk-Dev at lists.digium.com
> http://lists.digium.com/mailman/listinfo/asterisk-dev
> To UNSUBSCRIBE or update options visit:
>    http://lists.digium.com/mailman/listinfo/asterisk-dev
>



_______________________________________________
Asterisk-Dev mailing list
Asterisk-Dev at lists.digium.com
http://lists.digium.com/mailman/listinfo/asterisk-dev
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-dev
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 3047 bytes
Desc: not available
Url : http://lists.digium.com/pipermail/asterisk-dev/attachments/20040619/b2e5df65/smime.bin


More information about the asterisk-dev mailing list