#if defined(__hppa) && defined(__hpux)
/* PA HP-UX doesn't have the entire C99 runtime. */
-#elif defined(__sun) && __STDC_VERSION__ - 0 < 199901L
-/* Solaris up to 9 doesn't have the entire C99 runtime.
- Solaris 10 defines _STDC_C99 if __STDC_VERSION__ is >= 199901L.
- But, if you're including this file, you probably want to test the
- newer behaviour, so: */
-#error forgot to set -std=c99.
-#elif defined(__sun) && ! defined (_STDC_C99)
-/* Solaris up to 9 doesn't have the entire C99 runtime.
- Solaris 10 defines _STDC_C99 if __STDC_VERSION__ is >= 199901L. */
#elif defined(__sgi)
/* Irix6 doesn't have the entire C99 runtime. */
#elif defined(__FreeBSD__) && (__FreeBSD__ < 5)
lacks the C99 functions. */
#include <sys/types.h>
#if defined(_NEWLIB_VERSION) || defined(__UCLIBC__)
+#elif defined(__sun) && __STDC_VERSION__ - 0 < 199901L
+/* If you're including this file, you probably want to test the newer
+ behaviour, so ensure the right flags were used for each test: */
+#error forgot to set -std=c99.
+#elif defined(__sun) && ! defined (_STDC_C99)
+/* Solaris up to 9 doesn't have the entire C99 runtime.
+ Solaris 10 defines _STDC_C99 if __STDC_VERSION__ is >= 199901L.
+ This macro is defined in <sys/feature_tests.h> which is included by
+ various system headers, in this case <sys/types.h> above. */
#else
#define HAVE_C99_RUNTIME
#endif