################################################################################ # Copyright (c) Hisilicon Technologies Co., Ltd. 2014-2020. All rights reserved. # Description: Makefile # Author: SmartMedia_BSP # Create: 2014-06-04 ################################################################################ # # $(call make_dep,dir,basename,ext) # define make_dep $(CC) $(CFLAGS) -M $1/$2.$3 | sed "s,$2.o:,$1/$2.o $1/$2.d:,g" > $1/$2.d endef # # $(call show_cmd,cmd,file) # define show_cmd @if [ ss"${V}" == ss"0" ]; then ( \ CMD=" "$1" "; \ echo "$${CMD:0:10}$2"; \ ) fi endef # # $(call export_make,xxx_config) # define export_make @(echo "DEFTARGET = $1"; \ echo "$1:"; \ echo " ""$$""(call show_cmd,CHECK,""$$""{DEFCONFIG})"; \ echo " ""$$""(Q)""$$""(SHELL) ""$$""{EXPORTCONFIG} check ""$$""{TGTCONFIG} ""$$""{DEFCONFIG} ""$$""{CONFIGINC} INPUTFLAGS"; \ echo " ""$$""(Q)""$$""(MAKE) ""$$""{QUIET} ""$$""(BOOT).bin";) > $(DEFMAKEFILE) endef