[PATCH] build: define 'inline' iff HAVE_LIBNL1

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

 



Previous commit 0b4b53bb80 defined 'inline' to prevent broken build on
systems with libnl1 headers. However, it broke build on systems with
libnl3 headers. Therefore we must make that fix conditional.
---

Pushed under build breaker rule.

 src/util/virnetlink.h |    8 ++++++--
 1 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/src/util/virnetlink.h b/src/util/virnetlink.h
index 82154de..b1a1750 100644
--- a/src/util/virnetlink.h
+++ b/src/util/virnetlink.h
@@ -28,9 +28,13 @@
 
 /* Work around a bug where older libnl-1 headers expected older gcc
  * semantics of 'extern inline' that conflict with C99 semantics.  */
-#  define inline
+#  ifdef HAVE_LIBNL1
+#   define inline
+#  endif
 #  include <netlink/msg.h>
-#  undef inline
+#  ifdef HAVE_LIBNL1
+#   undef inline
+#  endif
 
 # else
 
-- 
1.7.8.6

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list


[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]