| # Copyright (C) 2018 Marvell International Ltd. |
| # SPDX-License-Identifier: BSD-3-Clause |
| # https://spdx.org/licenses |
| include ../../../make_helpers/toolchain.mk |
| HOSTCCFLAGS = -Wall -Werror |
| HOSTCCFLAGS += -g -O0 -DDEBUG |
| ifeq (${MARVELL_SECURE_BOOT},1) |
| DOIMAGE_CC_FLAGS := -DCONFIG_MVEBU_SECURE_BOOT |
| DOIMAGE_LD_FLAGS := -lconfig -lmbedtls -lmbedcrypto -lmbedx509 |
| HOSTCCFLAGS += ${DOIMAGE_CC_FLAGS} |
| # Make soft links and include from local directory otherwise wrong headers |
| # could get pulled in from firmware tree. |
| ${PROJECT}: ${OBJECTS} Makefile |
| ${Q}$(host-cc) ${OBJECTS} ${DOIMAGE_LD_FLAGS} -o $@ |
| @echo "Built $@ successfully" |
| ${Q}$(host-cc) -c ${HOSTCCFLAGS} ${INCLUDE_PATHS} $< -o $@ |