[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[libvirt] [PATCH] Fiz macvtap test on Debian



Hi,
Debian's (and therefore likely the derivatives') kernel headers are
lacking the typdef for sa_family_t in linux/socket.h so the
compilation of the macvtap check fails. Additionally including
sockaddr.h fixes this and doesn't hurt the other cases where there's
also a typedef in socket.h since these two must be identical.
Cheers,
 -- Guido
>From 4462e5bf45f8cbb4ef964623bae0a84b4fd07813 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Guido=20G=C3=BCnther?= <agx sigxcpu org>
Date: Tue, 9 Mar 2010 13:59:19 +0100
Subject: [PATCH] Include bits/sockaddr.h when checking for macvtap

since Debian's kernel headers don't have the definition sa_family_t in
linux/socket.h (yet).
---
 configure.ac |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/configure.ac b/configure.ac
index 6f4d7e4..98e6e53 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1849,7 +1849,8 @@ AC_ARG_WITH([macvtap],
   [with_macvtap=check])
 
 if test "$with_macvtap" != "no" ; then
-    AC_TRY_COMPILE([ #include <linux/if_link.h> ],
+    AC_TRY_COMPILE([ #include <bits/sockaddr.h> ],
+                   [ #include <linux/if_link.h> ],
                    [ int x = MACVLAN_MODE_BRIDGE; ],
                    [ with_macvtap=yes ],
                    [ if test "$with_macvtap" = "yes" ; then
-- 
1.7.0


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]