summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac35
1 files changed, 14 insertions, 21 deletions
diff --git a/configure.ac b/configure.ac
index aa05bda..b180d42 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,45 +1,38 @@
AC_PREREQ([2.57])
AC_INIT([Xproto], [7.0], [xorg@lists.freedesktop.org])
AM_INIT_AUTOMAKE([foreign dist-bzip2])
-#
-
-PROTO_DEFINES=
-
-
-# Find out what defines are necessary to make struct fd_set contain
-# fds_bits
-#
fds_bits_found=false;
-# No defines necessary?
-if test x$fds_bits_found = xfalse ; then
+if test "x$fds_bits_found" = xfalse ; then
AC_CHECK_MEMBER(fd_set.fds_bits,
[
- fds_bits_found=true
+ fds_bits_found=plain
+ USE_FDS_BITS="fds_bits"
],,
[
#include <sys/select.h>
])
fi
-# With _XOPEN_SOURCE?
-
-unset ac_cv_member_fd_set_fds_bits
-
-if test x$fds_bits_found = xfalse ; then
- AC_CHECK_MEMBER(fd_set.fds_bits,
+if test "x$fds_bits_found" = xfalse ; then
+ AC_CHECK_MEMBER(fd_set.__fds_bits,
[
- fds_bits_found=true
- PROTO_DEFINES="$PROTO_DEFINES -D_XOPEN_SOURCE"
+ fds_bits_found=underscores
+ USE_FDS_BITS="__fds_bits"
],,
[
- #define _XOPEN_SOURCE
#include <sys/select.h>
])
fi
-AC_SUBST(PROTO_DEFINES)
+if test "x$fds_bits_found" = xfalse ; then
+ AC_MSG_ERROR([Could not determine how to access the fds_bits or equivalent
+ structure in fd_set on your platform.])
+fi
+
+AC_SUBST([USE_FDS_BITS])
AC_OUTPUT([Makefile
+ Xpoll.h
xproto.pc])