diff options
author | Soby Mathew <soby.mathew@arm.com> | 2018-10-10 14:00:14 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-10-10 14:00:14 +0100 |
commit | 52a9e53b8cf253cdcd73265df60d9e8b03e534df (patch) | |
tree | 830653c221f5be3bd58c3c170afb2b0297e85839 /tools/stm32image/Makefile | |
parent | 821d3547e1532b8f720fe0ad2c8ccb84f840906d (diff) | |
parent | 750e8d807dced6cd2a523aad7be74161dc705f6e (diff) | |
download | platform_external_arm-trusted-firmware-52a9e53b8cf253cdcd73265df60d9e8b03e534df.tar.gz platform_external_arm-trusted-firmware-52a9e53b8cf253cdcd73265df60d9e8b03e534df.tar.bz2 platform_external_arm-trusted-firmware-52a9e53b8cf253cdcd73265df60d9e8b03e534df.zip |
Merge pull request #1612 from antonio-nino-diaz-arm/an/tools
tools: Make invocation of host compiler correct
Diffstat (limited to 'tools/stm32image/Makefile')
-rw-r--r-- | tools/stm32image/Makefile | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/tools/stm32image/Makefile b/tools/stm32image/Makefile index a593d3163..9c9b7b5fb 100644 --- a/tools/stm32image/Makefile +++ b/tools/stm32image/Makefile @@ -12,11 +12,12 @@ PROJECT := stm32image${BIN_EXT} OBJECTS := stm32image.o V := 0 -CFLAGS := -Wall -Werror -pedantic -std=c99 -D_GNU_SOURCE +HOSTCCFLAGS := -Wall -Werror -pedantic -std=c99 -D_GNU_SOURCE + ifeq (${DEBUG},1) - CFLAGS += -g -O0 -DDEBUG + HOSTCCFLAGS += -g -O0 -DDEBUG else - CFLAGS += -O2 + HOSTCCFLAGS += -O2 endif ifeq (${V},0) @@ -25,22 +26,22 @@ else Q := endif -CC := gcc +HOSTCC := gcc .PHONY: all clean distclean all: ${PROJECT} ${PROJECT}: ${OBJECTS} Makefile - @echo " LD $@" - ${Q}${CC} ${OBJECTS} -o $@ + @echo " HOSTLD $@" + ${Q}${HOSTCC} ${OBJECTS} -o $@ @${ECHO_BLANK_LINE} @echo "Built $@ successfully" @${ECHO_BLANK_LINE} %.o: %.c Makefile - @echo " CC $<" - ${Q}${CC} -c ${CFLAGS} $< -o $@ + @echo " HOSTCC $<" + ${Q}${HOSTCC} -c ${HOSTCCFLAGS} $< -o $@ clean: $(call SHELL_DELETE_ALL, ${PROJECT} ${OBJECTS}) |