public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: "Andreas Bießmann" <andreas.devel@googlemail.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] config.mk: use different host compiler for OS X 10.6
Date: Fri, 21 May 2010 23:33:14 +0200	[thread overview]
Message-ID: <1274477594-63398-1-git-send-email-andreas.devel@googlemail.com> (raw)

Compiling tools subdirectory on Mac OS X 10.6 (Snow Leopard) complains about
wrong syntax in system includes.

In file included from /usr/include/stdio.h:444,
                 from /Users/andreas/Documents/source/u-boot/include/compiler.h:26,
                 from /Users/andreas/Documents/source/u-boot/lib/crc32.c:15:
/usr/include/secure/_stdio.h:46: error: syntax error in macro parameter list

This can be fixed by reverting the workaround for prior OS X releases in
config.mk conditionally for OS X 10.6 (and maybe above, but this is not covered
by this patch).

Signed-off-by: Andreas Bie?mann <andreas.devel@googlemail.com>
---
 config.mk |   10 ++++++++++
 1 files changed, 10 insertions(+), 0 deletions(-)

diff --git a/config.mk b/config.mk
index 73b5195..be8e895 100644
--- a/config.mk
+++ b/config.mk
@@ -64,9 +64,19 @@ HOSTSTRIP	= strip
 #
 
 ifeq ($(HOSTOS),darwin)
+# get major and minor product version (e.g. 10.6 for Snow Leopard)
+DARWIN_VERSION	= $(shell sw_vers -productVersion | cut -f 1,2 -d '.')
+
+# Snow Leopards build environmenthas no longer restrictions as described above
+# TODO find a solution to match versions greater than 10.6
+ifeq ($(DARWIN_VERSION),10.6)
+HOSTCC		= gcc
+else
 HOSTCC		= cc
 HOSTCFLAGS	+= -traditional-cpp
 HOSTLDFLAGS	+= -multiply_defined suppress
+endif
+
 else
 HOSTCC		= gcc
 endif
-- 
1.7.1

             reply	other threads:[~2010-05-21 21:33 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-05-21 21:33 Andreas Bießmann [this message]
2010-05-22  5:14 ` [U-Boot] [PATCH] config.mk: use different host compiler for OS X 10.6 Mike Frysinger
2010-05-22 11:19   ` Andreas Bießmann

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=1274477594-63398-1-git-send-email-andreas.devel@googlemail.com \
    --to=andreas.devel@googlemail.com \
    --cc=u-boot@lists.denx.de \
    /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