unofficial mirror of guile-devel@gnu.org 
 help / color / mirror / Atom feed
From: Tristan Colgate <tcolgate@gmail.com>
To: guile-devel@gnu.org
Subject: [PATCH 1/2] Fix struct ip_mreq detection
Date: Tue, 19 Oct 2010 16:31:18 +0100	[thread overview]
Message-ID: <AANLkTikrHeEuwgoX0=RprqsobgrYbm0aw972JvbjLZAT@mail.gmail.com> (raw)

Probably not the ideal fix, I tried using AC_CHECK_TYPE and adding
netinet/in.h but it didn't work. I've just copied the approach used
for LINGER

-- 
Tristan Colgate-McFarlane
----
  "You can get all your daily vitamins from 52 pints of guiness, and a
glass of milk"

 configure.ac |   17 ++++++++++++++++-
 1 files changed, 16 insertions(+), 1 deletions(-)

diff --git a/configure.ac b/configure.ac
index 34ec603..ec82791 100644
--- a/configure.ac
+++ b/configure.ac
@@ -673,7 +673,22 @@ AC_CHECK_TYPE(socklen_t, ,
 #endif
 #include <sys/socket.h>
 ])
-AC_CHECK_TYPE(struct ip_mreq)
+
+AC_MSG_CHECKING(for struct ip_mreq)
+AC_CACHE_VAL(scm_cv_struct_ip_mreq,
+        AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
+#include <sys/types.h>
+#include <sys/socket.h>
+#include <netinet/in.h>]],
+                          [[struct ip_mreq req;]])],
+                          [scm_cv_struct_ip_mreq="yes"],
+                          [scm_cv_struct_ip_mreq="no"]))
+AC_MSG_RESULT($scm_cv_struct_ip_mreq)
+if test $scm_cv_struct_ip_mreq = yes; then
+        AC_DEFINE([HAVE_STRUCT_IP_MREQ], 1,
+          [Define this if your system defines struct ip_mreq, for use with the
+          setsockopt system call.])
+fi

 GUILE_HEADER_LIBC_WITH_UNISTD

-- 
1.7.2.3



             reply	other threads:[~2010-10-19 15:31 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-10-19 15:31 Tristan Colgate [this message]
2010-10-19 18:52 ` [PATCH 1/2] Fix struct ip_mreq detection Andy Wingo
     [not found]   ` <AANLkTik9+GeGDexi4PozcDPtF-RSZAtwKg91mkNxZaV9@mail.gmail.com>
     [not found]     ` <AANLkTimJ3wo_cTsBOBacu8e7bWVa5s2BQ1f1swh94F1J@mail.gmail.com>
2010-10-20 21:16       ` Andy Wingo

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/guile/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='AANLkTikrHeEuwgoX0=RprqsobgrYbm0aw972JvbjLZAT@mail.gmail.com' \
    --to=tcolgate@gmail.com \
    --cc=guile-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).