summaryrefslogtreecommitdiffstats
path: root/configure.in
diff options
context:
space:
mode:
authorThomas Radke <tradke@aei.mpg.de>2000-11-08 20:04:36 (GMT)
committerThomas Radke <tradke@aei.mpg.de>2000-11-08 20:04:36 (GMT)
commit36456dcccfec8f64fad1f6b3450e8d03973b5b19 (patch)
tree780ba289f7bdc10ccb275454a663a51117b12272 /configure.in
parent8073cbe745f7387c33193e8b5497ecd79a14b671 (diff)
downloadhdf5-36456dcccfec8f64fad1f6b3450e8d03973b5b19.zip
hdf5-36456dcccfec8f64fad1f6b3450e8d03973b5b19.tar.gz
hdf5-36456dcccfec8f64fad1f6b3450e8d03973b5b19.tar.bz2
[svn-r2815]
Purpose: Bugfix Description: Detect whether the 'struct socklen_t' type is defined in the system include header files. Solution: Added an AC_TRY_COMPILE test for 'struct socklen_t' to the configure script. This test is only executed if the Stream VFD is configured. Also added detection of <sys/types.h> and <sys/socket.h> system header files. Platforms tested: Solaris 2.6 and 2.7 IRIX64 Linux Windows NT (command line configure with gcc and cl)
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in22
1 files changed, 22 insertions, 0 deletions
diff --git a/configure.in b/configure.in
index 549dc32..d044713 100644
--- a/configure.in
+++ b/configure.in
@@ -385,6 +385,7 @@ AC_HEADER_STDC
AC_HEADER_TIME
dnl Unix
AC_CHECK_HEADERS(sys/resource.h sys/time.h unistd.h sys/ioctl.h sys/stat.h)
+AC_CHECK_HEADERS(sys/socket.h sys/types.h)
AC_CHECK_HEADERS(stddef.h setjmp.h)
AC_CHECK_HEADERS(stdint.h, C9x=yes)
dnl Windows
@@ -798,6 +799,27 @@ case "$withval" in
AC_MSG_RESULT(yes)
AC_CHECK_HEADERS(netinet/tcp.h)
AC_DEFINE(HAVE_STREAM)
+
+ dnl Check if we have struct socklen_t available
+ AC_MSG_CHECKING([if struct socklen_t is defined])
+ AC_TRY_COMPILE(
+ [
+#include <stdio.h>
+#include <stdlib.h>
+#ifdef HAVE_UNISTD_H
+#include <unistd.h>
+#endif
+#ifdef HAVE_SYS_TYPES_H
+#include <sys/types.h>
+#endif
+#ifdef HAVE_SYS_SOCKET_H
+#include <sys/socket.h>
+#endif
+ ],
+ [socklen_t foo; return 0;],
+ AC_DEFINE(HAVE_STRUCT_SOCKLEN_T) AC_MSG_RESULT(yes),
+ AC_MSG_RESULT(no)
+ )
;;
*)
AC_MSG_RESULT(not configured)