Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date: Fri, 14 Jul 2017 17:23:44 +0300
From: Jukka Jylänki <>
To:, Jukka Jylänki <>
Subject: Re: Typo in include/pthreads.h

Thanks for the clarification. Now I notice it looks like the
discrepancy comes from the generation of alltypes.h, which is expected
to become

#if defined(__NEED_pthread_mutex_t) && !defined(__DEFINED_pthread_mutex_t)
typedef struct { union { int __i[10]; volatile int __vi[10]; volatile
void *volatile __p[5]; } __u; } pthread_mutex_t;
#define __DEFINED_pthread_mutex_t

#if defined(__NEED_mtx_t) && !defined(__DEFINED_mtx_t)
typedef struct { union { int __i[10]; volatile int __vi[10]; volatile
void *volatile __p[5]; } __u; } mtx_t;
#define __DEFINED_mtx_t

rather than merge those two into the same. In Emscripten we have
preconfigured alltypes.h statically for distribution, and it looks
like that header has not been updated since we have last moved to a
newer Emscripten version. Thanks!

2017-07-14 17:02 GMT+03:00 Szabolcs Nagy <>:
> * Jukka Jylänki <> [2017-07-14 16:39:52 +0300]:
>> a contributor to Emscripten noticed that in include/pthreads.h, there
> you mean c11 include/threads.h, not posix pthread.h
>> are two lines
>> #define __NEED_cnd_t
>> #define __NEED_mtx_t
>> that look like they should be
>> #define __NEED_pthread_cond_t
>> #define __NEED_pthread_mutex_t
> no, the code in musl is correct.
> pthread_ types would violate c11 namespace rules here.
>> The first two names appear nowhere else in the musl repository. The
>> effect of this is that including <threads.h> as the first include
>> directive (or in practice, before other threading related headers)
>> fails to parse. See
> does not fail for me: mtx_t is defined for all supported targets
> in bits/ as far as i can see

Powered by blists - more mailing lists

Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.