]> git.proxmox.com Git - mirror_qemu.git/commitdiff
Avoid use of which to detect gcc, as it is broken on darwin. Patch by
authorths <ths@c046a42c-6fe2-441c-8c8c-71466251a162>
Wed, 9 May 2007 14:06:06 +0000 (14:06 +0000)
committerths <ths@c046a42c-6fe2-441c-8c8c-71466251a162>
Wed, 9 May 2007 14:06:06 +0000 (14:06 +0000)
Joachim Henke.

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2796 c046a42c-6fe2-441c-8c8c-71466251a162

configure

index 245b2059d938f9ae095640210a1e1af9a904a45e..65fdeed9db4a29601a33e52542161b5e17eee2a9 100755 (executable)
--- a/configure
+++ b/configure
@@ -394,18 +394,13 @@ if test "$check_gcc" = "yes" ; then
 #endif
 int main(){return 0;}
 EOF
-    check_cc() {
-       which "$1" 2> /dev/null
-       return $?
-    }
-
     if "$cc" -o $TMPE $TMPC 2> /dev/null ; then
        echo "WARNING: \"$cc\" looks like gcc 4.x"
        found_compat_cc="no"
        if test "$gcc3_search" = "yes" ; then
            echo "Looking for gcc 3.x"
            for compat_cc in $gcc3_list ; do
-               if check_cc "$cross_prefix$compat_cc" ; then
+               if "$cross_prefix$compat_cc" --version > /dev/null 2>&1 ; then
                    echo "Found \"$compat_cc\""
                    cc="$cross_prefix$compat_cc"
                    found_compat_cc="yes"