diff options
author | Uri Lublin <uril@qumranet.com> | 2007-01-17 12:58:30 +0000 |
---|---|---|
committer | Uri Lublin <uril@qumranet.com> | 2007-01-17 12:58:30 +0000 |
commit | e9b92bd935ca729d6b7cfdb5676ec5b903b72112 (patch) | |
tree | 7157eed57a6d92758be89e75fe1235a4986fa23d /configure | |
parent | 79a0f951b60fa3949733e00eddd4697024c6b110 (diff) |
kvm configure: prefer gcc for qemu_cc (over compat) if its version is 3.*
For some distributions, the installed (default) gcc version is 3.4 while
the compat-gcc version is 3.2 (or older). In those cases prefer the
more recent gcc.
Diffstat (limited to 'configure')
-rwxr-xr-x | configure | 8 |
1 files changed, 8 insertions, 0 deletions
@@ -22,6 +22,14 @@ EOF exit 1 } + +# prefer gcc if its version is 3.* ( over a compat-gcc ) +# do it before parsing command line arguments to enable the user +# to specify a specific gcc he/she likes. +if gcc -v 2>&1 | grep -q 'gcc *version *3\.[2-4]\.[0-9]'; then + qemu_cc=gcc +fi + while [[ "$1" = -* ]]; do opt="$1"; shift arg= |