https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103949
--- Comment #6 from Andrew Pinski <pinskia at gcc dot gnu.org> --- If you want __STDC_NO_THREADS defined file a bug about that but gcc will need to record which versions of glibc has C11 thread defined or not. You could use __has_include extension which will handle that mostly for you really.