From 95189e503f7e7c02dfbf116ccfe2f6dd747089d4 Mon Sep 17 00:00:00 2001 From: Ahurac Date: Mon, 11 Mar 2024 15:11:17 +0100 Subject: [PATCH] =?UTF-8?q?launchers/kvm=20:=20ajout=20architecture=20de?= =?UTF-8?q?=20processeur=20comme=20param=C3=A8tre?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- qemu/launchers/kvm | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/qemu/launchers/kvm b/qemu/launchers/kvm index ff41c26..36d0273 100755 --- a/qemu/launchers/kvm +++ b/qemu/launchers/kvm @@ -1,6 +1,10 @@ #!/usr/bin/env sh set -x +# What processor architecture to use +arch=$QEMUSH_ARCH +[ -z "$arch" ] && arch=$(uname -m) + # How many CPU cores to use nproc=$QEMUSH_NPROC [ -z "$nproc" ] && nproc=$(($(nproc) / 2)) @@ -10,7 +14,7 @@ ram=$QEMUSH_RAM [ -z "$ram" ] && ram=$(($(free | grep '^Mem:\s' | awk '{ print $NF }') / 2))K # Set the arguments -set -- qemu-system-x86_64 \ +set -- "qemu-system-${arch}" \ -enable-kvm \ -M q35 \ -cpu host -smp "$nproc" \