https://gcc.gnu.org/bugzilla/show_bug.cgi?id=53769

--- Comment #21 from Florian Weimer <fw at gcc dot gnu.org> ---
(In reply to Jakub Jelinek from comment #20)
> It is not that easy.  __STDC_NO_THREADS__ is a predefined macro, so it would
> mean (at least on targets without stdc-predef.h, with that header one would
> hope that the library describes its implementation correctly) the compiler
> would need on every single compilation try to internally #if
> !__has_include(<threads.h>) #define __STDC_NO_THREADS__ #endif or so.

I think this would have to be configured at compiler build time. Otherwise the
macro gets defined if an -I directory happens to contain a file called
threads.h.

I don't think alternative libcs are a thing on Darwin, and I don't expect Apple
to implement support, so it's probably safe for now to define
__STDC_NO_THREADS__ unconditionally on Darwin.

Reply via email to