Index: include/support/newlib/xlocale.h =================================================================== --- include/support/newlib/xlocale.h +++ include/support/newlib/xlocale.h @@ -16,7 +16,11 @@ #include #include #include +#if defined(__NEWLIB__) && (__NEWLIB__ == 2) \ + && defined(__NEWLIB_MINOR__) && (__NEWLIB_MINOR__ >= 5) \ + && (!defined(__POSIX_VISIBLE) || (__POSIX_VISIBLE < 200809)) #include +#endif #include #include