* modules/gethostname (configure.ac): Invoke gl_MODULE_INDICATOR.
* lib/unistd.in.h (gethostname): Don't define to
gethostname_used_without_requesting_gnulib_module_gethostname if the
gnulib module 'gethostname' is in use under the same configure.ac.
2024-07-24 Bruno Haible <bruno@clisp.org>
+ Avoid false gethostname_used_without_requesting_gnulib_module_gethostname.
+ * modules/gethostname (configure.ac): Invoke gl_MODULE_INDICATOR.
+ * lib/unistd.in.h (gethostname): Don't define to
+ gethostname_used_without_requesting_gnulib_module_gethostname if the
+ gnulib module 'gethostname' is in use under the same configure.ac.
+
Avoid false error close_used_without_requesting_gnulib_module_close.
Reported by Frédéric at <https://savannah.gnu.org/bugs/?65958>.
* modules/close (configure.ac): Invoke gl_MODULE_INDICATOR.
# endif
_GL_CXXALIASWARN (gethostname);
#elif @UNISTD_H_HAVE_WINSOCK2_H@
-# undef gethostname
-# define gethostname gethostname_used_without_requesting_gnulib_module_gethostname
+# if !GNULIB_GETHOSTNAME
+# undef gethostname
+# define gethostname gethostname_used_without_requesting_gnulib_module_gethostname
+# endif
#elif defined GNULIB_POSIXCHECK
# undef gethostname
# if HAVE_RAW_DECL_GETHOSTNAME
gl_PREREQ_GETHOSTNAME
])
gl_UNISTD_MODULE_INDICATOR([gethostname])
+gl_MODULE_INDICATOR([gethostname])
Makefile.am:
if GL_COND_OBJ_GETHOSTNAME