]> Zhao Yanbai Git Server - minix.git/commitdiff
LLVM clientctl: activate the KVM module only if available
authorErik van der Kouwe <erik@minix3.org>
Sun, 22 Jun 2014 07:10:46 +0000 (00:10 -0700)
committerLionel Sambuc <lionel@minix3.org>
Mon, 28 Jul 2014 15:06:10 +0000 (17:06 +0200)
minix/llvm/clientctl

index d5cf4b7641040f1b49efc0ef8c6a8f7739637030..e8921d633b8989ea7d912da454c7bce83c41a8e8 100755 (executable)
@@ -13,8 +13,10 @@ case "$mode" in
   'run')
     if which kvm > /dev/null; then
       hypervisor=kvm
-    else
+    elif [ -e /dev/kvm ]; then
       hypervisor="qemu-system-i386 --enable-kvm"
+    else
+      hypervisor=qemu-system-i386
     fi
     (cd ../../../obj.i386/destdir.i386/multiboot && $hypervisor -nographic -kernel kernel -append "console=tty00 rootdevname=c0d0p1" -initrd "mod01_ds,mod02_rs,mod03_pm,mod04_sched,mod05_vfs,mod06_memory,mod07_tty,mod08_mfs,mod09_vm,mod10_pfs,mod11_init" -hda $IMAGE)
     ;;