1--- a/lib/stdio.in.h
2+++ b/lib/stdio.in.h
3@@ -138,8 +138,10 @@
4 /* It is very rare that the developer ever has full control of stdin,
5 so any use of gets warrants an unconditional warning. Assume it is
6 always declared, since it is required by C89. */
7-#undef gets
8+#ifdef gets
9+# undef gets
10 _GL_WARN_ON_USE (gets, "gets is a security hole - use fgets instead");
11+#endif
12
13 #if @GNULIB_FOPEN@
14 # if @REPLACE_FOPEN@