]> asedeno.scripts.mit.edu Git - PuTTY.git/commitdiff
Check for <sys/sockio.h> and include it in uxnet.c if we find it. It's
authorBen Harris <bjh21@bjh21.me.uk>
Mon, 25 Apr 2005 18:51:15 +0000 (18:51 +0000)
committerBen Harris <bjh21@bjh21.me.uk>
Mon, 25 Apr 2005 18:51:15 +0000 (18:51 +0000)
necessary on Solaris if we want to use SIOCATMARK.  Using sockatmark() might
be preferable, but despite being notionally standard it's missing on
Solaris 9 and Mac OS X 10.3.9, whereas everyone seems to have SIOCATMARK
somewhere.

[originally from svn r5676]

unix/configure.ac
unix/uxnet.c

index 91563562ff5fded37950bc340870158cd9a14e4a..e1e33acbd5ae1e1e743f40010b5a40a0f54125ad 100644 (file)
@@ -14,6 +14,8 @@ if test "X$GCC" = Xyes; then
     CFLAGS="$CFLAGS -Wall -Werror"
 fi
 
+AC_CHECK_HEADERS([sys/sockio.h],,,[ ])
+
 AM_PATH_GTK([1.2.0], [all_targets="all-cli all-gtk"], [all_targets="all-cli"])
 AC_SUBST([all_targets])
 
index 31b12921d733f9fcc0f0fb2815aed1508c46db98..5d4ace44cb241044ce3dca8584f44d3d16ae1a0d 100644 (file)
 #include "network.h"
 #include "tree234.h"
 
+/* Solaris needs <sys/sockio.h> for SIOCATMARK. */
+#ifdef HAVE_SYS_SOCKIO_H
+#include <sys/sockio.h>
+#endif
+
 #ifndef X11_UNIX_PATH
 # define X11_UNIX_PATH "/tmp/.X11-unix/X"
 #endif