diff configure.ac @ 3150:0097f5462ac2

[gaim-migrate @ 3166] Patches by Max Horn, Nathan Walp and Danny Colascione. Thanks, guys. committer: Tailor Script <tailor@pidgin.im>
author Sean Egan <seanegan@gmail.com>
date Mon, 15 Apr 2002 03:23:09 +0000
parents 0cb6d9120f1d
children 3fd77e1a6fa1
line wrap: on
line diff
--- a/configure.ac	Sun Apr 14 22:44:28 2002 +0000
+++ b/configure.ac	Mon Apr 15 03:23:09 2002 +0000
@@ -41,6 +41,21 @@
 AC_CHECK_FUNC(inet_aton, , [AC_CHECK_LIB(resolv, inet_aton, , 
 				         [AC_ERROR(inet_aton not found)])])
 
+dnl Check for socklen_t (in Unix98)
+AC_MSG_CHECKING(for socklen_t)
+AC_TRY_COMPILE([#include <sys/types.h>
+#include <sys/socket.h>
+socklen_t x;
+], [], [AC_MSG_RESULT(yes)], [
+AC_TRY_COMPILE([#include <sys/types>
+#include <sys/socket.h>
+int accept(int, struct sockaddr *, size_t *);
+], [], [
+AC_MSG_RESULT(size_t)
+AC_DEFINE(socklen_t, size_t)]. [
+AC_MSG_RESULT(int)
+AC_DEFINE(socklen_t, int)])])
+
 dnl This is a bad, bad hack.  I am a bad, bad man.
 CFLAGS="$CFLAGS -I/usr/local/include -I/opt/include -I\$(top_srcdir)"