From 6240c62cec247fa9c3f0402a612125e326f77f13 Mon Sep 17 00:00:00 2001 From: Bill Currie Date: Mon, 13 May 2002 21:53:52 +0000 Subject: [PATCH] this should fix the problems with building the master server on bsd systems --- configure.ac | 14 ++++++++++++++ qw/source/master.c | 2 +- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index 43299bb24..bff9282ae 100644 --- a/configure.ac +++ b/configure.ac @@ -269,6 +269,20 @@ AC_TRY_COMPILE( ) ) +if test "x$ac_cv_header_sys_uio_h" = xyes; then + AC_MSG_CHECKING(for struct in_pktinfo) + AC_TRY_COMPILE( + [#include + #include + #include + #include ], + [struct in_pktinfo x;], + AC_DEFINE(HAVE_IN_PKTINFO, 1, [Define this if your system has struct in_pktinfo]) + AC_MSG_RESULT(yes), + AC_MSG_RESULT(no) + ) +fi + AC_MSG_CHECKING(for underscore prefix in names) AC_TRY_LINK( [asm(".long _bar"); diff --git a/qw/source/master.c b/qw/source/master.c index d299866bb..233846368 100644 --- a/qw/source/master.c +++ b/qw/source/master.c @@ -66,7 +66,7 @@ static const char rcsid[] = #include "protocol.h" -#ifdef HAVE_SYS_UIO_H +#ifdef HAVE_IN_PKTINFO static int qf_sendmsg (int sock, void *data, size_t len, struct msghdr *msghdr) {