On AIX 6.1, I'm seeing this compilation failure: gcc -mlong-double-64 -D_ALL_SOURCE -DHAVE_CONFIG_H -I. -I.. -DGNULIB_STRICT_CHECKING=1 -Wall -g -O2 -MT openpty.o -MD -MP -MF .deps/openpty.Tpo -c -o openpty.o openpty.c openpty.c:50: error: conflicting types for 'openpty' ./pty.h:407: error: previous declaration of 'openpty' was here make: 1254-004 The error code from the last command is 1.
The reason is that 'struct winsize' was not yet defined at the moment of the declaration in pty.h. This fixes it: 2011-10-20 Bruno Haible <br...@clisp.org> openpty: Avoid compilation error on AIX 6.1. * lib/pty.in.h [AIX]: Include <sys/ioctl.h>, for 'struct winsize'. --- lib/pty.in.h.orig Fri Oct 21 02:10:44 2011 +++ lib/pty.in.h Fri Oct 21 02:09:14 2011 @@ -42,6 +42,9 @@ /* Get 'struct termios' and 'struct winsize'. */ #include <termios.h> +#if defined _AIX +# include <sys/ioctl.h> +#endif /* The definitions of _GL_FUNCDECL_RPL etc. are copied here. */ -- In memoriam Eduard Brücklmeier <http://en.wikipedia.org/wiki/Eduard_Brücklmeier>