Index: linc-protocols.c
===================================================================
RCS file: /cvs/gnome/linc/src/linc-protocols.c,v
retrieving revision 1.42
diff -u -r1.42 linc-protocols.c
--- linc-protocols.c	9 Apr 2002 15:41:02 -0000	1.42
+++ linc-protocols.c	22 Apr 2002 09:03:52 -0000
@@ -10,6 +10,7 @@
  *                 Sun Microsystems, Inc.
  */
 #include <config.h>
+#include <sys/types.h>
 #include <dirent.h>
 #include "linc-compat.h"
 #include <linc/linc-protocol.h>
@@ -154,7 +155,7 @@
 #define LINC_SET_SOCKADDR_LEN(saddr, len)
 #endif
 
-#ifdef AF_INET6
+#if defined(AF_INET6) && defined (RES_USE_INET6)
 #define LINC_RESOLV_SET_IPV6     _res.options |= RES_USE_INET6
 #define LINC_RESOLV_CLEAR_IPV6   _res.options &= ~RES_USE_INET6
 #else
@@ -619,6 +620,13 @@
  * Return Value: #TRUE if the function succeeds, #FALSE otherwise.
  */
 #ifdef AF_INET6
+
+/* on Mac OS X 10.1 inaddr6_any isn't exported by libc */
+#ifndef in6addr_any
+static const struct in6_addr in6addr_any =
+  { { { 0 } } };
+#endif
+
 static gboolean
 linc_protocol_get_sockinfo_ipv6 (const LINCProtocolInfo  *proto,
 				 const struct sockaddr   *saddr,
