[PATCH 1/2] qemu-kvm: Use kvm-kmod headers if available

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

 



Since kvm-kmod-2.6.32.2 we have an alternative source for recent KVM
kernel headers. Use it when available and not overruled by --kerneldir.
If there is no kvm-kmod and no --kerneldir, we continue to fall back to
the qemu-kvm's kernel headers.

Signed-off-by: Jan Kiszka <jan.kiszka@xxxxxxxxxxx>
---

 configure |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/configure b/configure
index 20c374a..6ba565a 100755
--- a/configure
+++ b/configure
@@ -1424,6 +1424,8 @@ EOF
             kvm_cflags="$kvm_cflags -I$kerneldir/arch/$cpu/include"
       fi
   else
+    kvm_cflags=`pkg-config --cflags kvm-kmod 2> /dev/null`
+    if test "$kvm_cflags" = ""; then
       case "$cpu" in
       i386 | x86_64)
         kvm_arch="x86"
@@ -1438,6 +1440,7 @@ EOF
       kvm_cflags="-I$source_path/kvm/include"
       kvm_cflags="$kvm_cflags -include $source_path/kvm/include/linux/config.h"
       kvm_cflags="$kvm_cflags -I$source_path/kvm/include/$kvm_arch"
+    fi
   fi
   kvm_cflags="$kvm_cflags -idirafter $source_path/compat"
   if compile_prog "$kvm_cflags" "" ; then
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux