qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Joachim Henke <j-o@users.sourceforge.net>
To: qemu-devel@nongnu.org
Subject: [Qemu-devel] [PATCH] gcc detection fix for Mac OS X
Date: Sun, 29 Apr 2007 12:01:47 +0200	[thread overview]
Message-ID: <E5F77F57-BD1D-4C70-A7EE-5F9C66501434@users.sourceforge.net> (raw)

[-- Attachment #1: Type: text/plain, Size: 366 bytes --]

Hello,

on Mac OS X the command 'which' always returns true - regardless of  
the result. This is a problem, when the configure script tries to  
detect the right gcc version. An alternative to 'which' could be to  
try to invoke the compiler directly.

Please have a look at the attached patch.


Thanks,

Jo.


-- 
Joachim Henke
http://base91.sourceforge.net/j-o/

[-- Attachment #2: gccconf.diff --]
[-- Type: application/octet-stream, Size: 375 bytes --]

--- configure
+++ configure
@@ -396,7 +396,2 @@
 EOF
-    check_cc() {
-	which "$1" 2> /dev/null
-	return $?
-    }
-
     if "$cc" -o $TMPE $TMPC 2> /dev/null ; then
@@ -407,3 +402,3 @@
 	    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\""

[-- Attachment #3: Type: text/plain, Size: 2 bytes --]




                 reply	other threads:[~2007-04-29 10:08 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=E5F77F57-BD1D-4C70-A7EE-5F9C66501434@users.sourceforge.net \
    --to=j-o@users.sourceforge.net \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).