diff options
author | Avi Kivity <avi@qumranet.com> | 2008-08-13 15:09:36 +0300 |
---|---|---|
committer | Avi Kivity <avi@qumranet.com> | 2008-08-13 15:09:36 +0300 |
commit | 4c3ad6d2750f4f0ba99e2a2a6219ae04b044e64b (patch) | |
tree | e9e1de5acfabcc68589e28c8d60f7f531eb4029e /configure | |
parent | d0ab6dd3656d95a19da3cd7cdc06bcadc19662fd (diff) |
kvm: configure: fix qemu options with multiple arguments
Signed-off-by: Avi Kivity <avi@qumranet.com>
Diffstat (limited to 'configure')
-rwxr-xr-x | configure | 8 |
1 files changed, 5 insertions, 3 deletions
@@ -8,7 +8,7 @@ objcopy=objcopy want_module=1 qemu_cflags= qemu_ldflags= -qemu_opts= +qemu_opts=() cross_prefix= arch=`uname -m` target_exec= @@ -40,9 +40,11 @@ EOF while [[ "$1" = -* ]]; do opt="$1"; shift arg= + hasarg= if [[ "$opt" = *=* ]]; then arg="${opt#*=}" opt="${opt%%=*}" + hasarg=1 fi case "$opt" in --prefix) @@ -70,7 +72,7 @@ while [[ "$1" = -* ]]; do usage ;; *) - qemu_opts="$qemu_opts $opt" + qemu_opts=("${qemu_opts[@]}" "$opt${hasarg:+=$arg}") ;; esac done @@ -114,7 +116,7 @@ fi --kernel-path="$libkvm_kerneldir" \ --prefix="$prefix" \ ${cross_prefix:+"--cross-prefix=$cross_prefix"} \ - ${cross_prefix:+"--cpu=$arch"} $qemu_opts + ${cross_prefix:+"--cpu=$arch"} "${qemu_opts[@]}" ) || usage |