tools/thermal: tmon: support cross-compiling
authorBrian Norris <computersforpeace@gmail.com>
Wed, 18 Feb 2015 02:18:34 +0000 (18:18 -0800)
committerZhang Rui <rui.zhang@intel.com>
Sat, 28 Feb 2015 05:52:48 +0000 (13:52 +0800)
We might want to prepare CFLAGS outside of this Makefile, so don't
overwrite its initial value.

Then, support $(CROSS_COMPILE), so we can use a cross-compile toolchain.

Signed-off-by: Brian Norris <computersforpeace@gmail.com>
Acked-by: Jacob Pan <jacob.jun.pan@linux.intel.com>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: Zhang Rui <rui.zhang@intel.com>
tools/thermal/tmon/Makefile

index e775adcbd29fdd3c0fccb66a09efc86e1fd95216..13d1876c7889916e9d11ef791cd571706c107880 100644 (file)
@@ -2,8 +2,8 @@ VERSION = 1.0
 
 BINDIR=usr/bin
 WARNFLAGS=-Wall -Wshadow -W -Wformat -Wimplicit-function-declaration -Wimplicit-int
-CFLAGS= -O1 ${WARNFLAGS} -fstack-protector
-CC=gcc
+CFLAGS+= -O1 ${WARNFLAGS} -fstack-protector
+CC=$(CROSS_COMPILE)gcc
 
 CFLAGS+=-D VERSION=\"$(VERSION)\"
 LDFLAGS+=