[coreboot-gerrit] Patch set updated for coreboot: 8c8ca97 Makefile: Check $CC variable returned from xcompile is not empty.

Andrew Wu (arw@dmp.com.tw) gerrit at coreboot.org
Thu Sep 5 10:51:03 CEST 2013


Andrew Wu (arw at dmp.com.tw) just uploaded a new patch set to gerrit, which you can find at http://review.coreboot.org/3905

-gerrit

commit 8c8ca9753acb90e7c419adf8825b10209ab6508b
Author: Andrew Wu <arw at dmp.com.tw>
Date:   Thu Sep 5 00:21:11 2013 +0800

    Makefile: Check $CC variable returned from xcompile is not empty.
    
    If xcompile can't find out suitable GCC compiler for i386/armv7, it
    will not set $CC_i386/$CC_armv7 variable. Makefile sets $CC variable
    from xcompile, and will print strange error messages when executing
    $CC program if $CC is empty.
    
    Add checking to avoid this problem. If $CC is empty, also delete
    invalid .xcompile file, so make can recreate this file next time.
    
    Change-Id: Ia8d481d76ca52f3351cb99f05779d06947161c5d
    Signed-off-by: Andrew Wu <arw at dmp.com.tw>
---
 Makefile                     | 5 +++++
 payloads/libpayload/Makefile | 5 +++++
 2 files changed, 10 insertions(+)

diff --git a/Makefile b/Makefile
index dec32e5..3b4d931 100644
--- a/Makefile
+++ b/Makefile
@@ -137,6 +137,11 @@ AR := $(AR_$(ARCH-y))
 
 CFLAGS += $(CFLAGS_$(ARCH-y))
 
+ifeq ($(CC),)
+$(shell rm .xcompile)
+$(error no suitable GCC for $(ARCH-y))
+endif
+
 LIBGCC_FILE_NAME := $(shell test -r `$(CC) -print-libgcc-file-name` && \
 		      $(CC) -print-libgcc-file-name)
 
diff --git a/payloads/libpayload/Makefile b/payloads/libpayload/Makefile
index bfa1abf..b319840 100644
--- a/payloads/libpayload/Makefile
+++ b/payloads/libpayload/Makefile
@@ -115,6 +115,11 @@ AR := $(AR_$(ARCH-y))
 
 CFLAGS += $(CFLAGS_$(ARCH-y))
 
+ifeq ($(CC),)
+$(shell rm .xcompile)
+$(error no suitable GCC for $(ARCH-y))
+endif
+
 LIBGCC_FILE_NAME := $(shell test -r `$(CC) -print-libgcc-file-name` && \
 		      $(CC) -print-libgcc-file-name)
 



More information about the coreboot-gerrit mailing list