Stefan Tauner (stefan.tauner@gmx.at) just uploaded a new patch set to gerrit, which you can find at http://review.coreboot.org/3534
-gerrit
commit 584024898f1815d3b9a80bef7a3037e101008d6f Author: Stefan Tauner stefan.tauner@gmx.at Date: Tue Jun 25 17:50:14 2013 +0200
libpayload: use xgcc if available
Use xgcc if the user did not set CC explicitly. Fall back to the host's gcc if finding xgcc fails (like before).
Change-Id: I5252dd3cfd0430aa65f093458ef07cfe253e1cbd Signed-off-by: Stefan Tauner stefan.tauner@gmx.at --- payloads/libpayload/bin/lpgcc | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-)
diff --git a/payloads/libpayload/bin/lpgcc b/payloads/libpayload/bin/lpgcc index f0b2417..49cde7f 100755 --- a/payloads/libpayload/bin/lpgcc +++ b/payloads/libpayload/bin/lpgcc @@ -47,14 +47,20 @@ CC="" fi fi
+BASE=`dirname "$0"` +BASE=`eval "cd "${BASE}" && pwd"` + +# this will find xgcc when we are executed in-tree +crossgcc="${BASE}/../../../util/crossgcc/xgcc/bin/i386-elf-gcc" + if [ "$CC" != "" ]; then DEFAULT_CC=$CC +elif [ -x ${crossgcc} ]; then +DEFAULT_CC=${crossgcc} else DEFAULT_CC=gcc fi
-BASE=`dirname $0` - # This will set the _LIBDIR and _INCDIR variables used below . $BASE/lp.functions