summaryrefslogtreecommitdiff
path: root/configure
diff options
context:
space:
mode:
authorUri Lublin <uril@qumranet.com>2007-01-17 12:58:30 +0000
committerUri Lublin <uril@qumranet.com>2007-01-17 12:58:30 +0000
commite9b92bd935ca729d6b7cfdb5676ec5b903b72112 (patch)
tree7157eed57a6d92758be89e75fe1235a4986fa23d /configure
parent79a0f951b60fa3949733e00eddd4697024c6b110 (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-xconfigure8
1 files changed, 8 insertions, 0 deletions
diff --git a/configure b/configure
index 80117c8d..e2bbb6ee 100755
--- a/configure
+++ b/configure
@@ -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=