* sys_select: tweak for AIX
@ 2011-06-05 12:20 Bruno Haible
0 siblings, 0 replies; only message in thread
From: Bruno Haible @ 2011-06-05 12:20 UTC (permalink / raw
To: bug-gnulib
On AIX 7.1 with gcc, I'm seeing this warning:
test-sys_select.c:32: warning: implicit declaration of function 'memset'
test-sys_select.c:32: warning: incompatible implicit declaration of built-in function 'memset'
This should fix it.
2011-06-05 Bruno Haible <bruno@clisp.org>
sys_select: Ensure memset is declared also on AIX 7.
* lib/sys_select.in.h: Include <string.h> also on AIX.
* doc/posix-headers/sys_select.texi: Mention that <sys/select.h> is not
self-contained also on AIX 7.1.
--- doc/posix-headers/sys_select.texi.orig Sun Jun 5 14:17:27 2011
+++ doc/posix-headers/sys_select.texi Sun Jun 5 14:15:26 2011
@@ -19,7 +19,7 @@
@item
This header file is not self-contained --- it requires @code{<string.h>}
before @code{FD_ZERO} can be used --- on some platforms:
-Solaris 11 2010-11.
+AIX 7.1, Solaris 11 2010-11.
@end itemize
Portability problems not fixed by Gnulib:
--- lib/sys_select.in.h.orig Sun Jun 5 14:17:27 2011
+++ lib/sys_select.in.h Sun Jun 5 14:16:06 2011
@@ -51,10 +51,10 @@
# include <sys/time.h>
# endif
-/* On Solaris 10, <sys/select.h> provides an FD_ZERO implementation
+/* On AIX 7 and Solaris 10, <sys/select.h> provides an FD_ZERO implementation
that relies on memset(), but without including <string.h>.
But in any case avoid namespace pollution on glibc systems. */
-# if (defined __OpenBSD__ || defined __sun || defined __osf__ || defined __BEOS__) \
+# if (defined __OpenBSD__ || defined _AIX || defined __sun || defined __osf__ || defined __BEOS__) \
&& ! defined __GLIBC__
# include <string.h>
# endif
--
In memoriam Eduard Lederer <http://de.wikipedia.org/wiki/Eduard_Lederer>
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2011-06-05 12:20 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-06-05 12:20 sys_select: tweak for AIX Bruno Haible
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).