blob: f28c2974e30c8dbd174d6b6d183ae749e66e2c27 [file] [log] [blame]
# ---------------------------------------------------------------
# Variable declaration for asngen/asnregen/mcddll_update/umts_gen
# ---------------------------------------------------------------
RUN_ASNGEN := FALSE
RUN_ASNGEN_L4 := FALSE
RUN_ASNREGEN := FALSE
RUN_MCDDLL_UPDATE := FALSE
RUN_LTE_MCDDLL := FALSE
RUN_MCDDLL_UPDATE_L4 := FALSE
RUN_UMTS_GEN := FALSE
RUN_EAS_GEN := FALSE
RUN_NRAS_GEN := FALSE
ifeq ($(filter L1S BASIC,$(TEST_LOAD_TYPE)),)
ifeq ($(strip $(CUSTOM_RELEASE)),FALSE)
RUN_MCDDLL_UPDATE := TRUE
RUN_LTE_MCDDLL := TRUE
RUN_ASNGEN := TRUE
RUN_ASNGEN_L4 := TRUE
RUN_ASNREGEN := TRUE
ifneq ($(strip $(UTRAN_MODE_SUPPORT)),NONE)
RUN_UMTS_GEN := TRUE
endif
ifeq ($(strip $(EUTRAN_MODE_SUPPORT)),EUTRAN_MODE)
RUN_UMTS_GEN := TRUE
RUN_EAS_GEN := TRUE
endif
ifeq ($(strip $(FIVEG_MODE_SUPPORT)),FIVEG_MODE)
RUN_NRAS_GEN := TRUE
endif
endif
else
ifeq ($(strip $(TEST_LOAD_TYPE)),L1S)
RUN_EAS_GEN := TRUE
ifeq ($(strip $(FIVEG_MODE_SUPPORT)),FIVEG_MODE)
RUN_NRAS_GEN := TRUE
endif
endif
endif
# --------------------------------------
# Variable declaration for genmoduleinfo
# --------------------------------------
COM_DEF_PATH := $(ALL_MODULEDEF)
# -----------------------------
# Variable declaration for cgen
# -----------------------------
CGEN_CFG_MODEM := $(strip $(MODISBUILD_TST_DB))/cgenModem.cfg
CGEN_CFG_MODEM_SEC := $(strip $(MODISBUILD_TST_DB_SEC))/cgenModem_sec.cfg
CGEN_CFG_MODEM_4G := $(strip $(MODISBUILD_TST_DB_4G))/cgenModem_4g.cfg
POSTGEN_CFG_MODEM := $(strip $(MODISBUILD_TST_DB))/postgenModem.cfg
CODE_GEN_LST := $(strip $(MODISBUILD_TST_DB))/codegen.lis
CGEN_ENC_ENABLE := FALSE
# ------------------------------------------------------
# Variable declaration for MCDDLL
# filter-out unnecessary C2K XGEN_INC_DIR and COM_DEFS
# ------------------------------------------------------
Filter_Out = $(foreach input,$(2),$(if $(findstring $(1),$(input)),,$(input)))
#ex: GenCusUtmd = CuStOm_StArT_EL1D $(EL1D_UTMD_FILES) CuStOm_EnD_EL1D
GenCusUtmd = CuStOm_StArT_$(strip $(1)) $($(strip $(1))_UTMD_FILES) CuStOm_EnD_$(strip $(1))
#[LTE cgen need to check]
ifeq ($(strip $(CUSTOM_RELEASE)),FALSE)
ifneq ($(strip $(MTK_SW_DOMAIN)),TRUE)
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
UTMD_FILES := $(COMMON_UTMD_FILES) $(L1_UTMD_FILES)
else
ifeq ($(strip $(UE_SIMULATOR)),TRUE)
UTMD_FILES := $(COMMON_UTMD_FILES) $(L1_UTMD_FILES)
else
UTMD_FILES := $(COMMON_UTMD_FILES)
endif
endif
UTMD_FILES_SEC := $(L1_UTMD_FILES_LTE_SEC)
UTMD_FILES_4G := $(L1_UTMD_FILES_4G)
else
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
UTMD_FILES += $(foreach NEED_TMD_MODULE, $(filter $(CUS_REL_SRC_COMP),$(COMPLIST)), \
$(if $($(call Upper,$(strip $(NEED_TMD_MODULE)))_UTMD_FILES),$(call GenCusUtmd, $(call Upper,$(strip $(NEED_TMD_MODULE))))))
else
ifeq ($(strip $(UE_SIMULATOR)),TRUE)
UTMD_FILES += $(foreach NEED_TMD_MODULE, $(filter $(CUS_REL_SRC_COMP),$(COMPLIST)), \
$(if $($(call Upper,$(strip $(NEED_TMD_MODULE)))_UTMD_FILES),$(call GenCusUtmd, $(call Upper,$(strip $(NEED_TMD_MODULE))))))
else
UTMD_FILES += $(foreach NEED_TMD_MODULE, $(filter $(filter-out $(call Lower, $(MODIS_NO_NEED_MODULE)),$(CUS_REL_SRC_COMP)),$(COMPLIST)), \
$(if $($(call Upper,$(strip $(NEED_TMD_MODULE)))_UTMD_FILES),$(call GenCusUtmd, $(call Upper,$(strip $(NEED_TMD_MODULE))))))
endif
endif
endif
else
UTMD_FILES :=
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
UTMD_FILES += $(foreach NEED_TMD_MODULE, $(filter $(CUS_REL_SRC_COMP),$(COMPLIST)), \
$(if $($(call Upper,$(strip $(NEED_TMD_MODULE)))_UTMD_FILES),$(call GenCusUtmd, $(call Upper,$(strip $(NEED_TMD_MODULE))))))
endif
COMP_TRACE_DEFS_MODEM += $(NEW_CUS_REL_TRACE_DEFS_MODEM)
endif
#[LTE cgen need to check]
COMP_TRACE_DEFS_MODEM_TARGET := $(COMP_TRACE_DEFS_MODEM)
ifeq ($(strip $(MODIS_CONFIG)),TRUE)
ifneq ($(strip $(call Upper,$(UE_SIMULATOR))),TRUE)
COMP_TRACE_DEFS_MODEM := $(foreach trc,$(COMP_TRACE_DEFS_MODEM_TARGET),$(if $(filter L1%,$(call Upper,$(notdir $(trc)))),,$(trc)))
endif
endif
ifeq ($(strip $(CUSTOM_RELEASE)),TRUE)
ifeq ($(strip $(DHL_SUPPORT)),TRUE)
MDDBINFOCUSTOM = $(notdir $(wildcard $(CUS_MTK_REL)/dhl/database/$(strip $(MDDBINFOCUSTOMPREFIX))*))
else
MDDBINFOCUSTOM = $(notdir $(wildcard $(CUS_MTK_REL)/tst/database/$(strip $(MDDBINFOCUSTOMPREFIX))*))
endif
else
ifeq ($(MPD_SOURCE_FULL_BUILD),TRUE)
MDDBINFOCUSTOM = $(MDDBINFOCUSTOMPREFIX)_$(strip $(PURE_VERNO)).EDB
else
ifeq ($(strip $(NO_LTECGEN)),TRUE)
MDDBINFOCUSTOM = $(MDDBINFOCUSTOMPREFIX)_$(strip $(PURE_VERNO)).EDB
else
MDDBINFOCUSTOM = $(patsubst %_sec.EDB,%,$(notdir $(wildcard $(CUS_MTK_REL)/dhl/lte_sec/database/$(strip $(MDDBINFOCUSTOMPREFIX))*))).EDB
endif
endif
endif
ifeq ($(strip $(MODIS_CONFIG)),TRUE)
MDDBINFOCUSTOM = MDDB_pc.EDB
endif
ifeq ($(strip $(TEST_LOAD_TYPE)),L1S)
ifeq ($(strip $(CUSTOM_RELEASE)),FALSE)
CODEGEN_RESULT = $(strip $(MODISBUILD_TST_DB))/MDDB.EDB
endif
else
ifeq ($(strip $(SPLIT_SYSTEM)),TRUE)
CODEGEN_RESULT = $(strip $(MODISBUILD_TST_DB))/BPLGUSplitInfo
else
ifeq ($(strip $(CUSTOM_RELEASE)),TRUE)
CODEGEN_RESULT = $(strip $(MODISBUILD_TST_DB))/$(strip $(MDDBINFOCUSTOMSRCP))
else
CODEGEN_RESULT = $(strip $(MODISBUILD_TST_DB))/$(strip $(MDDBINFOCUSTOM))
endif
endif
endif
GV_FILES := $(wildcard $(strip $(TST_DB))/gv/*.gv)
GV_FILES_C2K := $(wildcard $(strip $(TST_DB))/gv/ext/*.gv)
GV_FILES_SEC := $(wildcard $(strip $(TST_DB_SEC))/gv/*.gv)
GV_FILES_4G := $(wildcard $(strip $(TST_DB))/gv/4g/*.gv)
ifndef RUN_CGEN_L1
RUN_CGEN_L1 := FALSE
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
RUN_CGEN_L1 := TRUE
else ifeq ($(strip $(call Upper,$(UE_SIMULATOR))),TRUE)
ifneq ($(filter $(MAKECMDGOALS),new),)
RUN_CGEN_L1 := TRUE
endif
else ifeq ($(strip $(DHL_SUPPORT)),TRUE)
RUN_CGEN_L1 := TRUE
endif
endif
CODEGEN_DEPENDENCY_MODEM :=
CODEGEN_PREPROCESS_MODEM :=
# CODEGEN_DATABASE_OUT is the output file name of cgen database
# TODO: CODEGEN_RESULT <=> CODEGEN_DATABASE_OUT
CODEGEN_DATABASE_MDDB_OUT = $(strip $(MODISBUILD_TST_DB))/MDDB*
ifeq ($(strip $(CUSTOM_RELEASE)),FALSE)
ifneq ($(strip $(TEST_LOAD_TYPE)),L1S)
CODEGEN_DATABASE_OUT = $(strip $(MODISBUILD_TST_DB))/$(strip $(MDDBINFOCUSTOM))
ifeq ($(strip $(DHL_SUPPORT)),TRUE)
CODEGEN_DATABASE_OUT_SEC = $(subst .EDB,_sec.EDB,$(strip $(MODISBUILD_TST_DB_SEC))/$(strip $(MDDBINFOCUSTOM)))
endif
else
CODEGEN_DATABASE_OUT = $(strip $(MODISBUILD_TST_DB))/MDDB.EDB
ifeq ($(strip $(DHL_SUPPORT)),TRUE)
CODEGEN_DATABASE_OUT_SEC = $(strip $(MODISBUILD_TST_DB_SEC))/MDDB_sec.EDB
endif
endif
else
ifneq ($(strip $(TEST_LOAD_TYPE)),L1S)
CODEGEN_DATABASE_OUT = $(strip $(MODISBUILD_TST_DB))/$(strip $(MDDBINFOCUSTOMSRCP))
ifeq ($(strip $(DHL_SUPPORT)),TRUE)
CODEGEN_DATABASE_OUT_SEC = $(subst .EDB,_sec.EDB,$(strip $(MODISBUILD_TST_DB_SEC))/$(strip $(MDDBINFOCUSTOMSRCP)))
endif
else
CODEGEN_DATABASE_OUT = $(strip $(MODISBUILD_TST_DB))/MDDB.EDB
ifeq ($(strip $(DHL_SUPPORT)),TRUE)
CODEGEN_DATABASE_OUT_SEC = $(strip $(MODISBUILD_TST_DB_SEC))/MDDB_sec.EDB
endif
endif
endif
ifeq ($(strip $(DHL_SUPPORT)),TRUE)
ifeq ($(MPD_SOURCE_FULL_BUILD),TRUE)
CODEGEN_DATABASE_IN_SEC = $(CODEGEN_DATABASE_OUT_SEC)
else
ifneq ($(strip $(TEST_LOAD_TYPE)),L1S)
ifeq ($(strip $(MODIS_CONFIG)),TRUE)
ifeq ($(strip $(call Upper,$(UE_SIMULATOR))),TRUE)
ifeq ($(strip $(OS_VERSION)),MSWin32)
CODEGEN_DATABASE_IN_SEC = $(wildcard $(CUS_MTK_REL)/dhl/lte_sec/database_uesim/$(subst .EDB,_sec.EDB,$(strip $(MDDBINFOCUSTOM))))
else
CODEGEN_DATABASE_IN_SEC = $(wildcard $(CUS_MTK_REL)/dhl/lte_sec/database_modis/$(subst .EDB,_sec.EDB,$(strip $(MDDBINFOCUSTOM))))
endif
else
CODEGEN_DATABASE_IN_SEC = $(wildcard $(CUS_MTK_REL)/dhl/lte_sec/database_modis/$(subst .EDB,_sec.EDB,$(strip $(MDDBINFOCUSTOM))))
endif
else
CODEGEN_DATABASE_IN_SEC = $(wildcard $(CUS_MTK_REL)/dhl/lte_sec/database/$(strip $(MDDBINFOCUSTOMPREFIX))*)
endif # MODIS_CONFIG
else
ifeq ($(strip $(MODIS_CONFIG)),TRUE)
CODEGEN_DATABASE_IN_SEC = $(wildcard $(CUS_MTK_REL)/dhl/lte_sec/database_modis/MDDB*)
else
CODEGEN_DATABASE_IN_SEC = $(wildcard $(CUS_MTK_REL)/dhl/lte_sec/database/MDDB*)
endif
endif # TEST_LOAD_TYPE
endif # MPD_SOURCE_FULL_BUILD
endif # DHL_SUPPORT
ifeq ($(MPD_SOURCE_4G_BUILD),TRUE)
ifeq ($(strip $(MODIS_CONFIG)),TRUE)
CODEGEN_DATABASE_OUT_4G = $(subst .EDB,_4G.EDB,$(strip $(MODISBUILD_TST_DB_4G))/$(strip $(MDDBINFOCUSTOM)))
CODEGEN_DATABASE_IN_4G = $(CODEGEN_DATABASE_OUT_4G)
else
ifneq ($(strip $(TEST_LOAD_TYPE)),L1S)
CODEGEN_DATABASE_OUT_4G = $(subst .EDB,_4G.EDB,$(strip $(MODISBUILD_TST_DB_4G))/$(strip $(MDDBINFOCUSTOM)))
CODEGEN_DATABASE_IN_4G = $(CODEGEN_DATABASE_OUT_4G)
else
CODEGEN_DATABASE_OUT_4G = $(strip $(MODISBUILD_TST_DB_4G))/MDDB_4G.EDB
CODEGEN_DATABASE_IN_4G = $(CODEGEN_DATABASE_OUT_4G)
endif
endif
INPUT_4G_DB = $(CODEGEN_DATABASE_IN_4G)
else
ifeq ($(strip $(MODIS_CONFIG)),TRUE)
INPUT_4G_DB = $(wildcard $(CUS_MTK_REL)/dhl/4g/database_modis/MDDB*)
else
INPUT_4G_DB = $(wildcard $(CUS_MTK_REL)/dhl/4g/database/MDDB*)
endif
endif
# CODEGEN_DATABASE_IN is the input file name of cgen database
ifneq ($(strip $(TEST_LOAD_TYPE)),L1S)
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
ifeq ($(strip $(DHL_SUPPORT)),TRUE)
CODEGEN_DATABASE_IN = $(CUS_MTK_REL)/dhl/database/$(strip $(MDDBINFOCUSTOM))
else
CODEGEN_DATABASE_IN = $(CUS_MTK_REL)/tst/database/$(strip $(MDDBINFOCUSTOM))
endif
else
ifeq ($(strip $(DHL_SUPPORT)),TRUE)
CODEGEN_DATABASE_IN = $(CUS_MTK_REL)/dhl/database_modis/$(strip $(MDDBINFOCUSTOM))
else
CODEGEN_DATABASE_IN = $(CUS_MTK_REL)/tst/database_modis/$(strip $(MDDBINFOCUSTOM))
endif
endif
else ifeq ($(wildcard $(CODEGEN_DATABASE_OUT)),)
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
ifeq ($(strip $(DHL_SUPPORT)),TRUE)
CODEGEN_DATABASE_IN = $(CUS_MTK_REL)/dhl/database/$(strip $(MDDBINFOCUSTOM))
else
CODEGEN_DATABASE_IN = $(CUS_MTK_REL)/tst/database/$(strip $(MDDBINFOCUSTOM))
endif
else
ifeq ($(strip $(DHL_SUPPORT)),TRUE)
CODEGEN_DATABASE_IN = $(CUS_MTK_REL)/dhl/database_modis/$(strip $(MDDBINFOCUSTOM))
else
CODEGEN_DATABASE_IN = $(CUS_MTK_REL)/tst/database_modis/$(strip $(MDDBINFOCUSTOM))
endif
endif
else
# remake with cgen should use generated database first after custom release, so as not to restore unchanged data to the default in full database
CODEGEN_DATABASE_IN = $(CODEGEN_DATABASE_OUT)
endif
else
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
CODEGEN_DATABASE_IN = $(wildcard $(CUS_MTK_REL)/dhl/database/MDDB*)
else
CODEGEN_DATABASE_IN = $(wildcard $(CUS_MTK_REL)/dhl/database_modis/MDDB*)
endif
else ifeq ($(wildcard $(CODEGEN_DATABASE_OUT)),)
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
CODEGEN_DATABASE_IN = $(wildcard $(CUS_MTK_REL)/dhl/database/MDDB*)
else
CODEGEN_DATABASE_IN = $(wildcard $(CUS_MTK_REL)/dhl/database_modis/MDDB*)
endif
else
CODEGEN_DATABASE_IN = $(CODEGEN_DATABASE_OUT)
endif
endif
ifeq ($(strip $(CUSTOM_RELEASE)),FALSE)
CODEGEN_DATABASE_IN = $(CODEGEN_DATABASE_OUT)
endif
ifeq ($(strip $(MTK_SW_DOMAIN)),TRUE)
ifeq ($(strip $(MODIS_CONFIG)),TRUE)
CODEGEN_DATABASE_IN = $(wildcard $(CUS_MTK_REL)/dhl/database_modis/MDDB_pc.EDB)
CODEGEN_DATABASE_OUT = $(strip $(MODISBUILD_TST_DB))/MDDB_pc.EDB
else #linux
ifneq ($(strip $(TEST_LOAD_TYPE)),L1S)
CODEGEN_DATABASE_IN = $(wildcard $(CUS_MTK_REL)/dhl/database/MDDB_*)
CODEGEN_DATABASE_OUT = $(strip $(MODISBUILD_TST_DB))/$(notdir $(wildcard $(CODEGEN_DATABASE_IN)))
else
CODEGEN_DATABASE_IN = $(wildcard $(CUS_MTK_REL)/dhl/database/MDDB.EDB)
CODEGEN_DATABASE_OUT = $(strip $(MODISBUILD_TST_DB))/MDDB.EDB
endif
endif
endif
CODEGEN_MDKEY = $(strip $(MODISBUILD_TST_DB))/$(strip $(patsubst %.EDB,%.KEY,$(patsubst MDDB_%,MDKEY_%,$(notdir $(CODEGEN_DATABASE_OUT)))))
ifneq ($(strip $(TEST_LOAD_TYPE)),BASIC)
ifeq ($(MPD_SOURCE_FULL_BUILD),TRUE) #MPD 5G cgen flow config
CODEGEN_PREPROCESS_MODEM += $(MODIS_RULESDIR)/codegen_dep/libParseDbModem_sec.det
CODEGEN_PREPROCESS_MODEM += $(MODIS_RULESDIR)/codegen_dep/gv_db_sec.det
CODEGEN_DEPENDENCY_MODEM_SEC += $(MODIS_RULESDIR)/codegen_dep/cgen_c_sec.det
CODEGEN_DEPENDENCY_MODEM_SEC += $(MODIS_RULESDIR)/codegen_dep/cgen_l1_sec.det
CODEGEN_DEPENDENCY_MODEM_SEC += $(MODIS_RULESDIR)/codegen_dep/cgen_gv_sec.det
ifeq ($(strip $(TEST_LOAD_TYPE)),L1S)
CODEGEN_PREPROCESS_MODEM += $(MODIS_RULESDIR)/codegen_dep/l1v_db_sec.det
CODEGEN_DEPENDENCY_MODEM_SEC += $(MODIS_RULESDIR)/codegen_dep/cgen_l1v_sec.det
endif
CODEGEN_PREPROCESS_MODEM += $(MODIS_RULESDIR)/codegen_dep/codegen_single_Modem_sec.det
CODEGEN_DEPENDENCY_MODEM_SEC += $(MODIS_RULESDIR)/codegen_dep/cgen_ps_Modem_sec.det
ifeq ($(RUN_UMTS_GEN),TRUE)
CODEGEN_PREPROCESS_MODEM += $(MODIS_RULESDIR)/codegen_dep/unionTag_parse_sec.det
CODEGEN_DEPENDENCY_MODEM_SEC += $(MODIS_RULESDIR)/codegen_dep/cgen_un_sec.det
endif
endif
ifeq ($(MPD_SOURCE_4G_BUILD),TRUE) #MPD 4G cgen flow config
CODEGEN_PREPROCESS_MODEM += $(MODIS_RULESDIR)/codegen_dep/libParseDbModem_4g.det
#CODEGEN_PREPROCESS_MODEM += $(MODIS_RULESDIR)/codegen_dep/gv_db_4g.det
CODEGEN_DEPENDENCY_MODEM_4G += $(MODIS_RULESDIR)/codegen_dep/cgen_ap_libParseDbModem_4g.det
CODEGEN_DEPENDENCY_MODEM_4G += $(MODIS_RULESDIR)/codegen_dep/cgen_l1_4g.det
#CODEGEN_DEPENDENCY_MODEM_4G += $(MODIS_RULESDIR)/codegen_dep/cgen_gv_4g.det
ifeq ($(strip $(TEST_LOAD_TYPE)),L1S)
CODEGEN_PREPROCESS_MODEM += $(MODIS_RULESDIR)/codegen_dep/l1v_db_4g.det
CODEGEN_DEPENDENCY_MODEM_4G += $(MODIS_RULESDIR)/codegen_dep/cgen_l1v_4g.det
endif
CODEGEN_PREPROCESS_MODEM += $(MODIS_RULESDIR)/codegen_dep/codegen_single_Modem_4g.det
CODEGEN_DEPENDENCY_MODEM_4G += $(MODIS_RULESDIR)/codegen_dep/cgen_ps_Modem_4g.det
ifeq ($(RUN_UMTS_GEN),TRUE)
CODEGEN_PREPROCESS_MODEM += $(MODIS_RULESDIR)/codegen_dep/unionTag_parse_4g.det
CODEGEN_DEPENDENCY_MODEM_4G += $(MODIS_RULESDIR)/codegen_dep/cgen_un_4g.det
endif
endif
ifneq ($(strip $(MTK_SW_DOMAIN)),TRUE)
ifeq ($(strip $(CUSTOM_RELEASE)),FALSE) #mpd cgen flow config
CODEGEN_PREPROCESS_MODEM += $(MODIS_RULESDIR)/codegen_dep/libParseDbModem.det $(MODIS_RULESDIR)/codegen_dep/libParseDbModem_tdd_fdd.det
CODEGEN_PREPROCESS_MODEM += $(MODIS_RULESDIR)/codegen_dep/gv_db.det
CODEGEN_PREPROCESS_MODEM += $(MODIS_RULESDIR)/codegen_dep/swParseDbModem.det
CODEGEN_PREPROCESS_MODEM += $(MODIS_RULESDIR)/codegen_dep/custom_parse_db.det $(MODIS_RULESDIR)/codegen_dep/custom_parse_db_tdd_fdd.det
CODEGEN_PREPROCESS_MODEM += $(MODIS_RULESDIR)/codegen_dep/srcParseDbModem.det $(MODIS_RULESDIR)/codegen_dep/srcParseDbModem_tdd_fdd.det
CODEGEN_DEPENDENCY_MODEM += $(MODIS_RULESDIR)/codegen_dep/cgen_ap_libParseDbModem.det
CODEGEN_DEPENDENCY_MODEM += $(MODIS_RULESDIR)/codegen_dep/cgen_gv.det
ifeq ($(strip $(TEST_LOAD_TYPE)),L1S)
CODEGEN_PREPROCESS_MODEM += $(MODIS_RULESDIR)/codegen_dep/l1v_db.det
CODEGEN_DEPENDENCY_MODEM += $(MODIS_RULESDIR)/codegen_dep/cgen_l1v.det
endif
CODEGEN_DEPENDENCY_MODEM += $(MODIS_RULESDIR)/codegen_dep/cgen_ap_swParseDbModem.det
CODEGEN_DEPENDENCY_MODEM += $(MODIS_RULESDIR)/codegen_dep/cgen_cm.det
CODEGEN_DEPENDENCY_MODEM += $(MODIS_RULESDIR)/codegen_dep/cgen_ap_srcParseDbModem.det
ifeq ($(RUN_UMTS_GEN),TRUE)
CODEGEN_PREPROCESS_MODEM += $(MODIS_RULESDIR)/codegen_dep/unionTag_parse.det $(MODIS_RULESDIR)/codegen_dep/unionTag_parse_tdd_fdd.det
CODEGEN_PREPROCESS_MODEM += $(MODIS_RULESDIR)/codegen_dep/unionTag_parse_ext.det $(MODIS_RULESDIR)/codegen_dep/unionTag_parse_tdd_fdd_ext.det
CODEGEN_DEPENDENCY_MODEM += $(MODIS_RULESDIR)/codegen_dep/cgen_un.det
endif
CODEGEN_DEPENDENCY_MODEM += $(MODIS_RULESDIR)/codegen_dep/cgen_l1.det
CODEGEN_DEPENDENCY_MODEM += $(MODIS_RULESDIR)/codegen_dep/cgen_ps_Modem.det
CODEGEN_DEPENDENCY_MODEM += $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det
ifeq ($(strip $(C2K_RELEASE)),TRUE)
CODEGEN_PREPROCESS_MODEM += $(MODIS_RULESDIR)/codegen_dep/gv_db_ext.det
CODEGEN_DEPENDENCY_MODEM += $(MODIS_RULESDIR)/codegen_dep/cgen_gv.det
ifneq ($(strip $(TEST_LOAD_TYPE)),L1S)
CODEGEN_PREPROCESS_MODEM += $(MODIS_RULESDIR)/codegen_dep/unionTag_parse_ext.det $(MODIS_RULESDIR)/codegen_dep/unionTag_parse_tdd_fdd_ext.det
CODEGEN_DEPENDENCY_MODEM += $(MODIS_RULESDIR)/codegen_dep/cgen_un.det
endif
endif
else
#cus cgen flow config
CODEGEN_PREPROCESS_MODEM += $(MODIS_RULESDIR)/codegen_dep/custom_parse_db.det $(MODIS_RULESDIR)/codegen_dep/custom_parse_db_tdd_fdd.det
CODEGEN_PREPROCESS_MODEM += $(MODIS_RULESDIR)/codegen_dep/codegen_single_Modem.det
CODEGEN_DEPENDENCY_MODEM += $(MODIS_RULESDIR)/codegen_dep/cgen_cm.det
CODEGEN_DEPENDENCY_MODEM += $(MODIS_RULESDIR)/codegen_dep/cgen_ps_Modem.det
CODEGEN_DEPENDENCY_MODEM += $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det
endif
else #swrd cgen flow config
CODEGEN_PREPROCESS_MODEM += $(MODIS_RULESDIR)/codegen_dep/swParseDbModem.det
CODEGEN_PREPROCESS_MODEM += $(MODIS_RULESDIR)/codegen_dep/codegen_single_Modem.det
CODEGEN_DEPENDENCY_MODEM += $(MODIS_RULESDIR)/codegen_dep/cgen_ap_swParseDbModem.det
CODEGEN_DEPENDENCY_MODEM += $(MODIS_RULESDIR)/codegen_dep/cgen_l1.det
CODEGEN_DEPENDENCY_MODEM += $(MODIS_RULESDIR)/codegen_dep/cgen_ps_Modem.det
CODEGEN_DEPENDENCY_MODEM += $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det
endif
#for all domains
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
CODEGEN_DEPENDENCY_MODEM += $(MODIS_RULESDIR)/codegen_dep/cgen_filter_gen_Modem.det
else
ifeq ($(wildcard $(BUILD_TSTDIR)/src/tst_file_default_Catcher_filter.c),)
CODEGEN_DEPENDENCY_MODEM += $(MODIS_RULESDIR)/codegen_dep/cgen_filter_gen_Modem.det
endif
endif
endif
CLEAN_CODEGEN_DEPENDENCY = $(filter-out $(MODIS_RULESDIR)/codegen_dep/nvram_% $(MODIS_RULESDIR)/codegen_dep/codegen.det,$(wildcard $(MODIS_RULESDIR)/codegen_dep/*.det))
# mcf_gen depends on cgen database
CLEAN_CODEGEN_DEPENDENCY += $(POSTGEN_DEP)/mcf_gen.det
ifeq ($(strip $(SMART_CHECK)),TRUE)
AUTO_CHECK_CGEN = TRUE
endif
ifeq ($(strip $(FPGA_L1_ROUTER_SUPPORT)),TRUE)
ifneq ($(call Upper,$(strip $(FIVEG_MODE_SUPPORT))),NONE)
EXTRA_COM_DEFS += -DL1_SIM
endif
endif
# CgenPreprocess
# function: generate the makfile command for cgen preprocess
# arguement 1: input source file to be preprocessed
# arguement 2: output preprocessed result
# arguement 3: output dependency file name, file path for cgen should be always r/codegen_dep
define CgenPreprocess
ifneq ($$(strip $$(AUTO_CHECK_CGEN)),TRUE)
$$(strip $$(MODIS_RULESDIR))/codegen_dep/$(3): FORCE
else
-include $$(strip $$(MODIS_RULESDIR))/codegen_dep/./$(3)
endif
$$(strip $$(MODIS_RULESDIR))/codegen_dep/$(3): $(1) $$(NEED_CHECK_DEPEND_LIST)
ifeq ($$(filter $$(MAKECMDGOALS),cgen_preprocess),)
# mbis time probe
ifeq ($$(strip $$(MBIS_EN)),TRUE)
@$$(ECHO) -n -t "T_S,$$@,T," >> $$(MBIS_BUILD_TIME_TMP)
endif
endif
@$(ECHO) -n Preprocessing $(1) ...
@$$(IF_NOT_EXIST) $$(patsubst %/,%,$$(dir $(2))) $$(THEN) $$(MKDIR) $$(patsubst %/,%,$$(dir $(2))) $$(CMD_END)
@$$(IF_NOT_EXIST) $$(strip $$(TMPDIR))/~inc_def.tmp $$(THEN) $$(MAKE) -fmake/common/build.mak -r -R --no-print-directory $$(strip $$(TMPDIR))/~inc_def.tmp $$(CMD_END)
ifneq ($$(strip $$(MODIS_CONFIG)),TRUE)
ifeq ($$(strip $$(COMPILER)),GCC)
ifeq ($$(strip $(4)),TRUE)
@(($$(CC) -E -W -DGEN_FOR_CPARSER -DGEN_FOR_PC $$(strip $$(EXTRA_COM_DEFS)) $$(VIA)$$(strip $$(TMPDIR))/~inc_fdd_def.tmp -USTDC_HEADERS -o $$(patsubst %.txt,%_fdd.txt,$$(patsubst %.db,%_fdd.db,$(2))) $(1) $$(DEPEND) $$(basename $$@).fdd.d 2>$$(basename $$@).log) $$(WITH) \
($$(IF_ERR_TRUE) $$(THEN) (($$(CAT) $$(basename $$@).log >>$$(CODE_GEN_LOG)) $$(WITH) (exit 1)) $$(CMD_END)))
ifeq ($$(strip $$(UMTS_TDD_SUPPORT)),UMTS_TDD128_MODE_SUPPORT)
@(($$(CC) -E -W -DGEN_FOR_CPARSER -DGEN_FOR_PC $$(strip $$(EXTRA_COM_DEFS)) $$(VIA)$$(strip $$(TMPDIR))/~inc_tdd_def.tmp -USTDC_HEADERS -o $$(patsubst %.txt,%_tdd.txt,$$(patsubst %.db,%_tdd.db,$(2))) $(1) $$(DEPEND) $$(basename $$@).tdd.d 2>$$(basename $$@).log) $$(WITH) \
($$(IF_ERR_TRUE) $$(THEN) (($$(CAT) $$(basename $$@).log >>$$(CODE_GEN_LOG)) $$(WITH) (exit 1)) $$(CMD_END)))
endif
else
@(($$(CC) -E -W -DGEN_FOR_CPARSER -DGEN_FOR_PC $$(strip $$(EXTRA_COM_DEFS)) $$(VIA)$$(strip $$(TMPDIR))/~inc_def.tmp -USTDC_HEADERS -o $(2) $(1) $$(DEPEND) $$(basename $$@).d 2>$$(basename $$@).log) $$(WITH) \
($$(IF_ERR_TRUE) $$(THEN) (($$(CAT) $$(basename $$@).log >>$$(CODE_GEN_LOG)) $$(WITH) (exit 1)) $$(CMD_END)))
endif
endif
else
ifeq ($$(strip $$(MODIS_COMPILER)),VC2017) # vc2017
ifeq ($$(strip $(4)),TRUE) #tdd/fdd
@(($$(strip $$(WinLLVMDir))\clang-cl.exe /X /E /w /DGEN_FOR_CPARSER /DGEN_FOR_PC /USTDC_HEADERS /nologo @$$(strip $$(TMPDIR))/~inc_fdd_def.tmp $(1) >$$(patsubst %.txt,%_fdd.txt,$$(patsubst %.db,%_fdd.db,$(2))) 2>$$(basename $$@).log) $$(WITH) \
($$(IF_ERR_TRUE) $$(THEN) ($$(CAT) $$(basename $$@).log >>$$(CODE_GEN_LOG)) $$(WITH) (exit 1) $$(CMD_END)))
@$$(strip $$(WinLLVMDir))\clang.exe -MM -w -DGEN_FOR_CPARSER -DGEN_FOR_PC -USTDC_HEADERS @$$(strip $$(TMPDIR))/~inc_fdd_def.tmp $(1) -MT $$@ -MF $$(basename $$@).fdd.d
ifeq ($$(strip $$(UMTS_TDD_SUPPORT)),UMTS_TDD128_MODE_SUPPORT)
@(($$(strip $$(WinLLVMDir))\clang-cl.exe /X /E /w /DGEN_FOR_CPARSER /DGEN_FOR_PC /USTDC_HEADERS /nologo @$$(strip $$(TMPDIR))/~inc_tdd_def.tmp $(1) >$$(patsubst %.txt,%_tdd.txt,$$(patsubst %.db,%_tdd.db,$(2))) 2>$$(basename $$@).log) $$(WITH) \
($$(IF_ERR_TRUE) $$(THEN) ($$(CAT) $$(basename $$@).log >>$$(CODE_GEN_LOG)) $$(WITH) (exit 1) $$(CMD_END)))
@$$(strip $$(WinLLVMDir))\clang.exe -MM -w -DGEN_FOR_CPARSER -DGEN_FOR_PC -USTDC_HEADERS @$$(strip $$(TMPDIR))/~inc_tdd_def.tmp $(1) -MT $$@ -MF $$(basename $$@).tdd.d
endif
else #not tdd/fdd
@(($$(strip $$(WinLLVMDir))\clang-cl.exe /X /E /w /DGEN_FOR_CPARSER /DGEN_FOR_PC /USTDC_HEADERS /nologo @$$(strip $$(TMPDIR))/~inc_def.tmp $(1) >$(2) 2>$$(basename $$@).log) $$(WITH) \
($$(IF_ERR_TRUE) $$(THEN) ($$(CAT) $$(basename $$@).log >>$$(CODE_GEN_LOG)) $$(WITH) (exit 1) $$(CMD_END)))
@$$(strip $$(WinLLVMDir))\clang.exe -MM -w -DGEN_FOR_CPARSER -DGEN_FOR_PC -USTDC_HEADERS @$$(strip $$(TMPDIR))/~inc_def.tmp $(1) -MT $$@ -MF $$(basename $$@).d
endif
else ifeq ($$(strip $$(MODIS_COMPILER)),CLANG) # clang
ifeq ($$(strip $(4)),TRUE)
@$$(strip $$(ClangDir))/bin/clang -MM -w -DGEN_FOR_CPARSER -DGEN_FOR_PC -USTDC_HEADERS @$$(strip $$(TMPDIR))/~inc_fdd_def.tmp $(1) -MT $$@ -MF $$(basename $$@).fdd.d
@(($$(CC_MODIS) /E /w /DGEN_FOR_CPARSER /DGEN_FOR_PC /USTDC_HEADERS /nologo @$$(strip $$(TMPDIR))/~inc_fdd_def.tmp $(1) >$$(patsubst %.txt,%_fdd.txt,$$(patsubst %.db,%_fdd.db,$(2)))) $$(WITH) \
($$(IF_ERR_TRUE) $$(THEN) ($$(CAT) $$(basename $$@).log >>$$(CODE_GEN_LOG)) $$(WITH) (exit 1) $$(CMD_END)))
ifeq ($$(strip $$(UMTS_TDD_SUPPORT)),UMTS_TDD128_MODE_SUPPORT)
@$$(strip $$(ClangDir))/bin/clang -MM -w -DGEN_FOR_CPARSER -DGEN_FOR_PC -USTDC_HEADERS @$$(strip $$(TMPDIR))/~inc_tdd_def.tmp $(1) -MT $$@ -MF $$(basename $$@).tdd.d
@(($$(CC_MODIS) /E /w /DGEN_FOR_CPARSER /DGEN_FOR_PC /USTDC_HEADERS /nologo @$$(strip $$(TMPDIR))/~inc_tdd_def.tmp $(1) >$$(patsubst %.txt,%_tdd.txt,$$(patsubst %.db,%_tdd.db,$(2)))) $$(WITH) \
($$(IF_ERR_TRUE) $$(THEN) ($$(CAT) $$(basename $$@).log >>$$(CODE_GEN_LOG)) $$(WITH) (exit 1) $$(CMD_END)))
endif
else
@$$(strip $$(ClangDir))/bin/clang -MM -w -DGEN_FOR_CPARSER -DGEN_FOR_PC -USTDC_HEADERS @$$(strip $$(TMPDIR))/~inc_def.tmp $(1) -MT $$@ -MF $$(basename $$@).d
@(($$(CC_MODIS) /E /w /DGEN_FOR_CPARSER /DGEN_FOR_PC /USTDC_HEADERS /nologo @$$(strip $$(TMPDIR))/~inc_def.tmp $(1) >$(2)) $$(WITH) \
($$(IF_ERR_TRUE) $$(THEN) ($$(CAT) $$(basename $$@).log >>$$(CODE_GEN_LOG)) $$(WITH) (exit 1) $$(CMD_END)))
endif
endif
endif
ifeq ($$(strip $(4)),TRUE)
@perl ./tools/pack_dep_gen.pl $$@ $$@ $$(patsubst %/,%,$$(dir $$@)) "\b$$(basename $$(notdir $$@)).*\.d"
else
@perl ./tools/pack_dep_gen.pl $$@ $$@ $$(patsubst %/,%,$$(dir $$@)) "\b$$(basename $$(notdir $$@))\.d"
endif
@$$(IF_EXIST) $$(basename $$@).fdd.d $$(THEN) $$(DEL_FILE) $$(basename $$@).fdd.d $$(CMD_END)
@$$(IF_EXIST) $$(basename $$@).tdd.d $$(THEN) $$(DEL_FILE) $$(basename $$@).tdd.d $$(CMD_END)
@$$(IF_EXIST) $$(basename $$@).d $$(THEN) $$(DEL_FILE) $$(basename $$@).d $$(CMD_END)
@$$(IF_EXIST) $$(basename $$@).log $$(THEN) $$(DEL_FILE) $$(basename $$@).log $$(CMD_END)
ifeq ($$(filter $$(MAKECMDGOALS),cgen_preprocess),)
@$(ECHO) -n $$@ >>$$(CODE_GEN_LST)
@$(ECHO) -n $(2) >>$$(CODE_GEN_LST)
# mbis time probe
ifeq ($$(strip $$(MBIS_EN)),TRUE)
@$$(ECHO) -n -t "T_E,$$@,T," >> $$(MBIS_BUILD_TIME_TMP)
endif
endif
endef
# *************************************************************************
# Tools code preprocess and generation
# *************************************************************************
ifeq ($(strip $(ACTION)),slim_codegen)
ifneq ($(strip $(UTRAN_MODE_SUPPORT)),NONE)
slim_codegen: cleanbin cleancodegen asngen umts_gen codegen asnregen
else
slim_codegen: cleanbin cleancodegen asngen codegen asnregen
endif
@$(ECHO) -n Done.
else
## codegen
ifneq ($(strip $(GERAN_MODE_SUPPORT)),NONE)
# [TATAKA Migrate] multi-mode
code_generate: sysgen cleanbin cleancodegen mspm_gen mipc_gen icd_ac_gen eas_gen nras_gen rcdb_gen asngen umts_gen codegen asnregen mcddll_update
else
# [TATAKA Migrate] single-mode
code_generate: sysgen cleanbin cleancodegen mspm_gen mipc_gen icd_ac_gen eas_gen nras_gen rcdb_gen asngen codegen
endif
@$(ECHO) -n Done.
endif
ifneq ($(strip $(GERAN_MODE_SUPPORT)),NONE)
# [TATAKA Migrate] multi-mode
ifneq ($(strip $(MTK_SW_DOMAIN)),TRUE)
codegen: ss_lcs_gen
endif
codegen: gencustominfo nvram_edit_h_gen nvram_auto_gen genmoduleinfo cgen
else
# [TATAKA Migrate] single-mode
codegen: nvram_edit_h_gen nvram_auto_gen genmoduleinfo cgen
endif
#update dsp cgen flow
update_cgen_dsp: $(MODIS_RULESDIR)/codegen_dep/cgen_filter_gen_Modem.det $(MODIS_RULESDIR)/codegen_dep/cgen_cfg_Modem.det
# *************************************************************************
# Target: rcdb_gen
# request by CS2/Kuo-Wei
# *************************************************************************
rcdb_gen: $(PREGEN_DEP)/rcdb_gen.det
ifeq ($(strip $(SMART_CHECK)),TRUE)
include $(wildcard $(PREGEN_DEP)/./rcdb_gen.det)
else
$(PREGEN_DEP)/rcdb_gen.det: FORCE
endif
$(PREGEN_DEP)/rcdb_gen.det:
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(ECHO) "$@ START TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
@$(IF_NOT_EXIST) $(strip $(PREGEN_DEP)) $(THEN) ($(MKDIR) $(strip $(PREGEN_DEP))) $(CMD_END)
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_precgen.log
endif
@$(IF_NOT_EXIST) $(strip $(PREGEN_DEP)) $(THEN) ($(MKDIR) $(strip $(PREGEN_DEP))) $(CMD_END)
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
@$(IF_NOT_EXIST) $(strip $(PROJ_INTERNAL_DIR)) $(THEN) ($(MKDIR) $(strip $(PROJ_INTERNAL_DIR))) $(CMD_END)
@$(IF_EXIST) ${UNIVERSAL_COMMON}/tools/rcdb_gen/nr_fwk_rcdb_code_gen.pl $(THEN) \
((perl ${UNIVERSAL_COMMON}/tools/rcdb_gen/nr_fwk_rcdb_code_gen.pl $(strip $(PROJ_INTERNAL_DIR)) $@ > $(strip $(COMPLOGDIR))/rcdb_gen.log 2>&1) $(WITH) \
$(IF_ERR_TRUE) $(THEN) (echo Error: rcdb_gen failed. Please check $(strip $(COMPLOGDIR))/rcdb_gen.log $(WITH) exit 1) $(CMD_END)) \
$(CMD_END)
ifneq ($(strip $(OS_VERSION)),MSWin32)
#delete target file for cleaning legacy code
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
@$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common >> $(strip $(COMPLOGDIR))/genJson.log 2>&1 $(WITH) \
($(IF_ERR_TRUE) $(THEN) \
((echo Error: the command is \"$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common\") $(AND) \
echo Error: Failed in tools/genTargetFile.py at $@. Please check $(strip $(COMPLOGDIR))/genJson.log !$(WITH) exit 1) \
$(CMD_END))
endif
@$(ECHO) "$@ END TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: umts_gen
# 3G Codegen Gen Files: ASN and DBME
# *************************************************************************
umts_gen: $(PREGEN_DEP)/umts_gen.det
ifeq ($(strip $(SMART_CHECK)),TRUE)
include $(wildcard $(PREGEN_DEP)/./umts_gen.det)
else
$(PREGEN_DEP)/umts_gen.det: FORCE
endif
$(PREGEN_DEP)/umts_gen.det:
ifeq ($(RUN_UMTS_GEN),TRUE)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_NOT_EXIST) $(strip $(PREGEN_DEP)) $(THEN) ($(MKDIR) $(strip $(PREGEN_DEP))) $(CMD_END)
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_precgen.log
endif
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
# FDD umts_gen
@$(CHDIR) protocol/3g/urr/urr_fdd $(AND) \
(perl urr_generate.pl --CC="$(strip $(CC))" --COMPILER=$(COMPILER) --feature=" $(UMTS_RELEASE_SUPPORT) UMTS_FDD_MODE_SUPPORT ULCS_ASN_SUPPORT_R99 $(REMOVE_DEBUG_INFO) " --deffile="../../../../$(INFOLOG)" --tst_src_path="$(MODIS_TST_DB)" --tst_dst_path="$(MODISBUILD_TST_DB)" --targetdir="$(PROJDIR)" --log_dir="$(strip $(COMPLOGDIR))" $@)
@$(CHDIR) protocol/3g/urr/urr_fdd $(AND) \
(perl lurr_generate.pl --CC="$(strip $(CC))" --COMPILER=$(COMPILER) --feature=" $(UMTS_RELEASE_SUPPORT) UMTS_FDD_MODE_SUPPORT ULCS_ASN_SUPPORT_R99 $(REMOVE_DEBUG_INFO) " --deffile="../../../../$(INFOLOG)" --tst_src_path="$(MODIS_TST_DB)" --tst_dst_path="$(MODISBUILD_TST_DB)" --targetdir="$(PROJDIR)" --log_dir="$(strip $(COMPLOGDIR))" $@)
# TDD umts_gen
ifeq ($(strip $(UMTS_TDD_SUPPORT)),UMTS_TDD128_MODE_SUPPORT)
@$(CHDIR) protocol/3g/urr/urr_tdd $(AND) \
(perl urr_generate.pl --CC="$(strip $(CC))" --COMPILER=$(COMPILER) --feature=" $(UMTS_RELEASE_SUPPORT) UMTS_TDD128_MODE_SUPPORT ULCS_ASN_SUPPORT_R99 $(REMOVE_DEBUG_INFO) " --deffile="../../../../$(INFOLOG)" --tst_src_path="$(MODIS_TST_DB)" --tst_dst_path="$(MODISBUILD_TST_DB)" --targetdir="$(PROJDIR)" --log_dir="$(strip $(COMPLOGDIR))" $@)
@$(CHDIR) protocol/3g/urr/urr_tdd $(AND) \
(perl lurr_generate.pl --CC="$(strip $(CC))" --COMPILER=$(COMPILER) --feature=" $(UMTS_RELEASE_SUPPORT) UMTS_TDD128_MODE_SUPPORT ULCS_ASN_SUPPORT_R99 $(REMOVE_DEBUG_INFO) " --deffile="../../../../$(INFOLOG)" --tst_src_path="$(MODIS_TST_DB)" --tst_dst_path="$(MODISBUILD_TST_DB)" --targetdir="$(PROJDIR)" --log_dir="$(strip $(COMPLOGDIR))" $@)
endif
else
# FDD umts_gen
@$(CHDIR) protocol/3g/urr/urr_fdd $(AND) \
(perl urr_generate.pl --CC="$(CC_MODIS)" --COMPILER=$(MODIS_COMPILER) --feature=" $(UMTS_RELEASE_SUPPORT) UMTS_FDD_MODE_SUPPORT ULCS_ASN_SUPPORT_R99 MoDIS " --deffile="../../../../$(INFOLOG_MODIS)" --tst_src_path="$(MODIS_TST_DB)" --tst_dst_path="$(MODISBUILD_TST_DB)" --targetdir="$(PROJDIR)" --log_dir="$(strip $(MODISLOGDIR))" $@)
# TDD umts_gen
ifeq ($(strip $(UMTS_TDD_SUPPORT)),UMTS_TDD128_MODE_SUPPORT)
@$(CHDIR) protocol/3g/urr/urr_tdd $(AND) \
(perl urr_generate.pl --CC="$(CC_MODIS)" --COMPILER=$(MODIS_COMPILER) --feature=" $(UMTS_RELEASE_SUPPORT) UMTS_TDD128_MODE_SUPPORT ULCS_ASN_SUPPORT_R99 MoDIS " --deffile="../../../../$(INFOLOG_MODIS)" --tst_src_path="$(MODIS_TST_DB)" --tst_dst_path="$(MODISBUILD_TST_DB)" --targetdir="$(PROJDIR)" --log_dir="$(strip $(MODISLOGDIR))" $@)
endif
endif
ifneq ($(strip $(OS_VERSION)),MSWin32)
@$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common >> $(strip $(COMPLOGDIR))/genJson.log 2>&1 $(WITH) \
($(IF_ERR_TRUE) $(THEN) \
((echo Error: the command is \"$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common\") $(AND) \
echo Error: Failed in tools/genTargetFile.py at $@. Please check $(strip $(COMPLOGDIR))/genJson.log $(WITH) exit 1) \
$(CMD_END))
endif
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
endif
# *************************************************************************
# Target: mspm_gen
# gen mspm common header/source by csv table setting
# *************************************************************************
mspm_gen: $(PREGEN_DEP)/mspm_gen.det
ifeq ($(strip $(SMART_CHECK)),TRUE)
include $(wildcard $(PREGEN_DEP)/./mspm_gen.det)
else
$(PREGEN_DEP)/mspm_gen.det: FORCE
endif
$(PREGEN_DEP)/mspm_gen.det:
ifneq ($(wildcard protocol/as_multimode/asinterfaces/mspm_proc_gen_tbl/mspm_procedure_table.csv),)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(ECHO) "$@ START TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
@$(IF_NOT_EXIST) $(strip $(PREGEN_DEP)) $(THEN) ($(MKDIR) $(strip $(PREGEN_DEP))) $(CMD_END)
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_precgen.log
endif
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
@$(IF_EXIST) tools/mspm_gen_proc_tbl.pl $(THEN) \
((perl tools/mspm_gen_proc_tbl.pl "$(strip $(PROJECT_MAKEFILE))" TARGET $(PROJDIR) $(strip $(COMPLOGDIR)) $@> $(strip $(COMPLOGDIR))/mspm_gen_tbl.log) $(WITH) \
$(IF_ERR_TRUE) $(THEN) (echo Error: generate mspm files Failed. Please check $(strip $(COMPLOGDIR))/mspm_gen_tbl.log $(WITH) exit 1) $(CMD_END)) \
$(CMD_END)
else
@$(IF_EXIST) tools/mspm_gen_proc_tbl.pl $(THEN) \
((perl tools/mspm_gen_proc_tbl.pl "$(strip $(PROJECT_MAKEFILE))" MODIS $(MODISPROJDIR)/_BUILD_XGEN $(strip $(MODISPROJDIR))/_BUILD_LOG $@ > $(strip $(MODISPROJDIR))/_BUILD_LOG/mspm_gen_tbl.log) $(WITH) \
$(IF_ERR_TRUE) $(THEN) (echo Error: generate mspm files Failed. Please check $(strip $(MODISPROJDIR))/_BUILD_LOG/mspm_gen_tbl.log $(WITH) exit 1) $(CMD_END)) \
$(CMD_END)
endif
ifneq ($(strip $(OS_VERSION)),MSWin32)
@$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common >> $(strip $(COMPLOGDIR))/genJson.log 2>&1 $(WITH) \
($(IF_ERR_TRUE) $(THEN) \
((echo Error: the command is \"$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common\") $(AND) \
echo Error: Failed in tools/genTargetFile.py at $@. Please check $(strip $(COMPLOGDIR))/genJson.log $(WITH) exit 1) \
$(CMD_END))
endif
@$(ECHO) "$@ END TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
endif# wildcard csv file
# *************************************************************************
# Target: mipc_gen
#
# *************************************************************************
mipc_gen: $(PREGEN_DEP)/mipc_gen.det
ifeq ($(strip $(SMART_CHECK)),TRUE)
include $(wildcard $(PREGEN_DEP)/./mipc_gen.det)
else
$(PREGEN_DEP)/mipc_gen.det: FORCE
endif
$(PREGEN_DEP)/mipc_gen.det:
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
ifeq ($(strip $(CUSTOM_RELEASE)),FALSE)
@$(ECHO) "$@ START TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
@$(IF_NOT_EXIST) $(strip $(PREGEN_DEP)) $(THEN) ($(MKDIR) $(strip $(PREGEN_DEP))) $(CMD_END)
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_precgen.log
endif
ifneq ($(strip $(OS_VERSION)),MSWin32)
@$(IF_EXIST) mtk_tools/MIPC/host_release.pl $(THEN) \
((perl mtk_tools/MIPC/host_release.pl $(PROJDIR) $(strip $(INFOMAKELOG)) $@> $(strip $(COMPLOGDIR))/mipc_gen.log) $(WITH) \
$(IF_ERR_TRUE) $(THEN) (echo Error: generate mipc files Failed. Please check $(strip $(COMPLOGDIR))/mipc_gen.log $(WITH) exit 1) $(CMD_END)) \
$(CMD_END)
@$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common >> $(strip $(COMPLOGDIR))/genJson.log 2>&1 $(WITH) \
($(IF_ERR_TRUE) $(THEN) \
((echo Error: the command is \"$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common\") $(AND) \
echo Error: Failed in tools/genTargetFile.py at $@. Please check $(strip $(COMPLOGDIR))/genJson.log $(WITH) exit 1) \
$(CMD_END))
else #Windows
@$(IF_EXIST) mtk_tools/MIPC/host_release_modis.pl $(THEN) \
((perl mtk_tools/MIPC/host_release_modis.pl $(PROJDIR) $(strip $(INFOMAKELOG)) $@> $(strip $(COMPLOGDIR))/mipc_gen.log) $(WITH) \
$(IF_ERR_TRUE) $(THEN) (echo Error: generate mipc files Failed. Please check $(strip $(COMPLOGDIR))/mipc_gen.log $(WITH) exit 1) $(CMD_END)) \
$(CMD_END)
endif
@$(ECHO) "$@ END TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
else #CUSTOM_RELEASE is TRUE
@$(IF_NOT_EXIST) $(strip $(PROJDIR))/modem/mipc $(THEN) ($(MKDIR) $(strip $(PROJDIR))/modem/mipc) $(CMD_END)
$(COPY_FILE) $(strip $(CUS_MTK_REL))/modem/mipc/mipc.release.tar.gz $(strip $(PROJDIR))/modem/mipc
endif
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# Target: icd_ac_gen
# *************************************************************************
icd_ac_gen: $(PREGEN_DEP)/icd_ac_gen.det
ifeq ($(strip $(SMART_CHECK)),TRUE)
include $(wildcard $(PREGEN_DEP)/./icd_ac_gen.det)
else
$(PREGEN_DEP)/icd_ac_gen.det: FORCE
endif
$(PREGEN_DEP)/icd_ac_gen.det:
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(ECHO) "$@ START TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
@$(IF_NOT_EXIST) $(strip $(PREGEN_DEP)) $(THEN) ($(MKDIR) $(strip $(PREGEN_DEP))) $(CMD_END)
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_precgen.log
endif
@$(IF_NOT_EXIST) $(strip $(PROJDIR))/modem/icd_ac_gen $(THEN) ($(MKDIR) $(strip $(PROJDIR))/modem/icd_ac_gen) $(CMD_END)
@python ./tools/icd_ac_gen/icd_ac_gen.py -i interface/service/icd -o $(strip $(PROJDIR))/modem/icd_ac_gen > $(strip $(COMPLOGDIR))/icd_ac_gen.log 2>&1 $(WITH) \
$(IF_ERR_TRUE) $(THEN) (echo Error: mspm_gen icd_ac_gen failed. Please check $(strip $(COMPLOGDIR))/icd_ac_gen.log $(WITH) exit 1) $(CMD_END)
ifneq ($(strip $(OS_VERSION)),MSWin32)
@$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common >> $(strip $(COMPLOGDIR))/genJson.log 2>&1 $(WITH) \
($(IF_ERR_TRUE) $(THEN) \
((echo Error: the command is \"$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common\") $(AND) \
echo Error: Failed in tools/genTargetFile.py at $@. Please check $(strip $(COMPLOGDIR))/genJson.log $(WITH) exit 1) \
$(CMD_END))
endif
@$(ECHO) "$@ END TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: eas_gen
# To generate LTE asn.1 codec library by LTE asn.1 compiler
# *************************************************************************
eas_gen: $(PREGEN_DEP)/eas_gen.det
ifeq ($(strip $(SMART_CHECK)),TRUE)
include $(wildcard $(PREGEN_DEP)/./eas_gen.det)
else
$(PREGEN_DEP)/eas_gen.det: FORCE
endif
$(PREGEN_DEP)/eas_gen.det:
ifneq ($(wildcard protocol/eas/eas_generate.pl),)
ifeq ($(RUN_EAS_GEN),TRUE)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_NOT_EXIST) $(strip $(PREGEN_DEP)) $(THEN) ($(MKDIR) $(strip $(PREGEN_DEP))) $(CMD_END)
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_precgen.log
endif
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
@$(CHDIR) $(strip $(EAS_FOLDER)) $(AND) \
((perl eas_generate.pl --feature="$(strip $(LTE_RELEASE_SUPPORT))" --targetdir="$(PROJDIR)" --log_dir="$(strip $(COMPLOGDIR))" --depTarget="$@") $(WITH) \
$(IF_ERR_TRUE) $(THEN) (echo Error: eas_gen Failed. Please check $(strip $(COMPLOGDIR))/eas_gen.log $(WITH) exit 1) $(CMD_END))
else
@$(CHDIR) $(strip $(EAS_FOLDER)) $(AND) \
((perl eas_generate.pl --feature="$(strip $(LTE_RELEASE_SUPPORT))" --targetdir="$(PROJDIR)" --log_dir="$(strip $(MODISLOGDIR))" --depTarget="$@") $(WITH)\
$(IF_ERR_TRUE) $(THEN) (echo Error: eas_gen Failed. Please check $(strip $(MODISLOGDIR))/eas_gen.log $(WITH) exit 1) $(CMD_END))
endif
ifneq ($(strip $(OS_VERSION)),MSWin32)
#delete target file for cleaning legacy code
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
@$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common >> $(strip $(COMPLOGDIR))/genJson.log 2>&1 $(WITH) \
($(IF_ERR_TRUE) $(THEN) \
((echo Error: the command is \"$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common\") $(AND) \
echo Error: Failed in tools/genTargetFile.py at $@. Please check $(strip $(COMPLOGDIR))/genJson.log $(WITH) exit 1) \
$(CMD_END))
endif
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
endif # ENDIF RUS_EAS_GEN
endif
# *************************************************************************
# TARGET: nras_gen
# To generate NR ASN.1 codec library by NR ASN.1 compiler
# *************************************************************************
nras_gen: $(PREGEN_DEP)/nras_gen.det
ifeq ($(strip $(SMART_CHECK)),TRUE)
include $(wildcard $(PREGEN_DEP)/./nras_gen.det)
else
$(PREGEN_DEP)/nras_gen.det: FORCE
endif
$(PREGEN_DEP)/nras_gen.det:
ifneq ($(wildcard protocol/nras/nrrc_asn1_generate.pl),)
ifeq ($(RUN_NRAS_GEN),TRUE)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_NOT_EXIST) $(strip $(PREGEN_DEP)) $(THEN) ($(MKDIR) $(strip $(PREGEN_DEP))) $(CMD_END)
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_precgen.log
endif
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
@$(CHDIR) $(strip $(NRAS_FOLDER)) $(AND) \
((perl nrrc_asn1_generate.pl --feature="$(strip $(NR_RELEASE_SUPPORT))" --targetdir="$(PROJDIR)" --log_dir="$(strip $(COMPLOGDIR))" --depTarget="$@" --spec_ver="$(strip $(MTK_3GPP_SPEC_VER))") $(WITH) \
$(IF_ERR_TRUE) $(THEN) (echo Error: nras_gen Failed. Please check $(strip $(COMPLOGDIR))/nras_gen.log $(WITH) exit 1) $(CMD_END))
else
@$(CHDIR) $(strip $(NRAS_FOLDER)) $(AND) \
((perl nrrc_asn1_generate.pl --feature="$(strip $(NR_RELEASE_SUPPORT))" --targetdir="$(PROJDIR)" --log_dir="$(strip $(MODISLOGDIR))" --depTarget="$@" --spec_ver="$(strip $(MTK_3GPP_SPEC_VER))") $(WITH)\
$(IF_ERR_TRUE) $(THEN) (echo Error: nras_gen Failed. Please check $(strip $(MODISLOGDIR))/nras_gen.log $(WITH) exit 1) $(CMD_END))
endif
ifneq ($(strip $(OS_VERSION)),MSWin32)
#delete target file for cleaning legacy code
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
@$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common >> $(strip $(COMPLOGDIR))/genJson.log 2>&1 $(WITH) \
($(IF_ERR_TRUE) $(THEN) \
((echo Error: the command is \"$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common\") $(AND) \
echo Error: Failed in tools/genTargetFile.py at $@. Please check $(strip $(COMPLOGDIR))/genJson.log $(WITH) exit 1) \
$(CMD_END))
endif
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
endif # ENDIF RUN_NRAS_GEN
endif
# ---------------------------------------
# SS LCS Codegen Gen Files: ASN
# ---------------------------------------
ss_lcs_gen: $(PREGEN_DEP)/ss_lcs_gen.det
ifeq ($(strip $(SMART_CHECK)),TRUE)
include $(wildcard $(PREGEN_DEP)/./ss_lcs_gen.det)
else
$(PREGEN_DEP)/ss_lcs_gen.det: FORCE
endif
$(PREGEN_DEP)/ss_lcs_gen.det:
ifeq ($(strip $(CUSTOM_RELEASE)),FALSE)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_NOT_EXIST) $(strip $(PREGEN_DEP)) $(THEN) ($(MKDIR) $(strip $(PREGEN_DEP))) $(CMD_END)
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_precgen.log
endif
@$(IF_NOT_EXIST) $(strip $(GEN_SSDIR)) $(THEN) ($(MKDIR) $(strip $(GEN_SSDIR))) $(CMD_END)
@$(CHDIR) protocol/layer4/l4/csm/ss/tools $(AND) \
(perl ss_lcs_generate.pl $(strip $(GEN_SSDIR)) $@ > ../../../../../../$(strip $(COMPLOGDIR))/ss_lcs_generate.log 2>&1) $(WITH) \
($(IF_ERR_TRUE) $(THEN) (echo Error: ss_lcs_gen Failed. Please check $(strip $(COMPLOGDIR))/ss_lcs_generate.log $(WITH) exit 1) $(CMD_END))
ifneq ($(strip $(OS_VERSION)),MSWin32)
#delete target file for cleaning legacy code
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
@$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common >> $(strip $(COMPLOGDIR))/genJson.log 2>&1 $(WITH) \
($(IF_ERR_TRUE) $(THEN) \
((echo Error: the command is \"$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common\") $(AND) \
echo Error: Failed in tools/genTargetFile.py at $@. Please check $(strip $(COMPLOGDIR))/genJson.log $(WITH) exit 1) \
$(CMD_END))
endif
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
endif
# *************************************************************************
# TARGET: temp add
# *************************************************************************
$(strip $(TMPDIR))/~mcddll_inc.tmp $(strip $(TMPDIR))/~lte_mcddll_inc.tmp: $(strip $(MAKE_COMMON))/xgeninc.mak $(NEED_CHECK_DEPEND_LIST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(STRCMPEX) inc inc e $@ $(foreach inc,$(XGEN_INC_DIR),$(inc))
@perl ./tools/lnitem.pl $@
@$(ECHO) -n "$@" >> $(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: mcddll_update
# *************************************************************************
mcddll_update: $(POSTGEN_DEP)/mcddll_update.det
ifeq ($(strip $(SMART_CHECK)),TRUE)
include $(wildcard $(POSTGEN_DEP)/./mcddll_update.det)
else
$(POSTGEN_DEP)/mcddll_update.det: FORCE
endif
$(POSTGEN_DEP)/mcddll_update.det:
ifneq ($(strip $(GERAN_MODE_SUPPORT)),NONE)
ifneq ($(filter TRUE,$(RUN_MCDDLL_UPDATE) $(RUN_MCDDLL_UPDATE_L4)),)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(ECHO) "$@ START TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
@$(IF_NOT_EXIST) $(strip $(POSTGEN_DEP)) $(THEN) ($(MKDIR) $(strip $(POSTGEN_DEP))) $(CMD_END)
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_postcgen.log
endif
@$(IF_NOT_EXIST) $(COMPLOGDIR) $(THEN) ($(MKDIR) $(COMPLOGDIR)) $(CMD_END)
@$(STRCMPEX) def def e $(strip $(TMPDIR))/~def.tmp $(foreach def,$(sort $(COM_DEFS)),$(def))
@perl ./tools/lnitem.pl $(strip $(TMPDIR))/~def.tmp
@$(MAKE) -fmake/common/build.mak -r -R --no-print-directory GAS_FOLDER=protocol/2g/gas UAS_FOLDER=protocol/3g/urr/urr_fdd XGEN_SWITCH_FDD_TDD=FDD $(strip $(TMPDIR))/~mcddll_inc.tmp
@($(ECHO) -n "[ COMMON OPTION ]" > $(MCDDLL_INFOLOG)) $(AND) \
($(CAT) $(strip $(TMPDIR))/~def.tmp >> $(MCDDLL_INFOLOG))
@($(ECHO) -n "[ COMMON INCLUDE PATH ]" >> $(MCDDLL_INFOLOG)) $(AND) \
($(CAT) $(strip $(TMPDIR))/~mcddll_inc.tmp >> $(MCDDLL_INFOLOG))
@$(IF_EXIST) $(MCDDLL_INFOLOG) $(THEN)\
($(IF_NOT_EXIST) $(strip $(PROJDIR))/modem/mcddll $(THEN) \
($(MKDIR) $(strip $(PROJDIR))/modem/mcddll) $(AND) \
($(COPY_FILE) $(MCDDLL_INFOLOG) $(strip $(PROJDIR))/modem/mcddll > $(DEV_NUL)) \
$(CMD_END))\
$(CMD_END)
ifeq ($(strip $(RUN_MCDDLL_UPDATE)),TRUE)
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
@perl protocol/as_utility/mcddll/updatemcddll_mingw.pl --PROJECT="$(strip $(PROJECT_MAKEFILE))" --L4=0 --MODE="TARGET" --VERNO=$(strip $(VERNO)) --HW_VERSION=$(strip $(PLATFORM))_$(strip $(CHIP_VER)) --PROJDIR=$(PROJDIR) --BUILD_L4_DIR=$(BUILD_L4DIR) --MINGW_DIR=$(MinGWDir) --COMPLOGDIR=$(COMPLOGDIR) --SMARTNEW=$@ 2> $(MCDDLL_UPDATE_LOG) \
$(WITH) \
$(IF_ERR_TRUE) $(THEN) (echo Error: $@ Failed! Please check $(strip $(MCDDLL_UPDATE_LOG)) $(WITH) exit 1) $(CMD_END)
else
@perl protocol/as_utility/mcddll/updatemcddll_mingw.pl --PROJECT="$(strip $(PROJECT_MAKEFILE))" --L4=0 --MODE=MoDIS --VERNO=$(strip $(VERNO)) --HW_VERSION=$(MODIS_UESIM) --PROJDIR=$(PROJDIR) --BUILD_L4_DIR=$(BUILD_L4DIR) --MINGW_DIR=$(MinGWDir) --COMPLOGDIR=$(MODISLOGDIR) --SMARTNEW=$@ 2> $(MCDDLL_UPDATE_LOG) \
$(WITH) \
$(IF_ERR_TRUE) $(THEN) (echo Error: $@ Failed! Please check $(strip $(MCDDLL_UPDATE_LOG)) $(WITH) exit 1) $(CMD_END)
endif
@$(COPY_FILE) $(strip $(PROJDIR))/modem/mcddll/mcddll.dll $(strip $(MODISBUILD_TST_DB))/mcddll.dll >$(DEV_NUL)
else ifeq ($(strip $(RUN_MCDDLL_UPDATE_L4)),TRUE)
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
@perl protocol/as_utility/mcddll/updatemcddll_mingw.pl --PROJECT="$(strip $(PROJECT_MAKEFILE))" --L4=1 --MODE="TARGET" --VERNO=$(strip $(VERNO)) --HW_VERSION=$(strip $(PLATFORM))_$(strip $(CHIP_VER)) --PROJDIR=$(PROJDIR) --BUILD_L4_DIR=$(BUILD_L4DIR) --REL_DIR=$(CUS_MTK_REL) --MINGW_DIR=$(MinGWDir) --COMPLOGDIR=$(COMPLOGDIR) --SMARTNEW=$@ 2> $(MCDDLL_UPDATE_LOG) \
$(WITH) \
$(IF_ERR_TRUE) $(THEN) (echo Error: $@ Failed! Please check $(strip $(MCDDLL_UPDATE_LOG)) $(WITH) exit 1) $(CMD_END)
else
@perl protocol/as_utility/mcddll/updatemcddll_mingw.pl --PROJECT="$(strip $(PROJECT_MAKEFILE))" --L4=1 --MODE=MoDIS --VERNO=$(strip $(VERNO)) --HW_VERSION=$(MODIS_UESIM) --PROJDIR=$(PROJDIR) --BUILD_L4_DIR=$(BUILD_L4DIR) --REL_DIR=$(CUS_MTK_REL) --MINGW_DIR=$(MinGWDir) --COMPLOGDIR=$(MODISLOGDIR) --SMARTNEW=/$@ 2> $(MCDDLL_UPDATE_LOG) \
$(WITH) \
$(IF_ERR_TRUE) $(THEN) (echo Error: $@ Failed! Please check $(strip $(MCDDLL_UPDATE_LOG)) $(WITH) exit 1) $(CMD_END)
endif
@$(COPY_FILE) $(strip $(PROJDIR))/modem/mcddll/mcddll.dll $(strip $(MODISBUILD_TST_DB))/mcddll.dll >$(DEV_NUL)
else
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
@$(COPY_FILE) $(strip $(CUS_MTK_REL))/tst/database/mcddll.dll $(strip $(MODISBUILD_TST_DB))/mcddll.dll >$(DEV_NUL)
else
@$(COPY_FILE) $(strip $(CUS_MTK_REL))/tst/database_modis/mcddll.dll $(strip $(MODISBUILD_TST_DB))/mcddll.dll >$(DEV_NUL)
endif
endif
ifneq ($(strip $(OS_VERSION)),MSWin32)
#delete target file for cleaning legacy code
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(UMTS_TDD_SUPPORT)),UMTS_TDD128_MODE_SUPPORT)
@$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common,tdd >> $(strip $(COMPLOGDIR))/genJson.log 2>&1 $(WITH) \
($(IF_ERR_TRUE) $(THEN) \
((echo Error: the command is \"$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common,tdd\") $(AND) \
echo Error: Failed in tools/genTargetFile.py at $@. Please check $(strip $(COMPLOGDIR))/genJson.log $(WITH) exit 1) \
$(CMD_END))
else
@$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common >> $(strip $(COMPLOGDIR))/genJson.log 2>&1 $(WITH) \
($(IF_ERR_TRUE) $(THEN) \
((echo Error: the command is \"$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common\") $(AND) \
echo Error: Failed in tools/genTargetFile.py at $@. Please check $(strip $(COMPLOGDIR))/genJson.log $(WITH) exit 1) \
$(CMD_END))
endif
endif
@$(ECHO) "$@ END TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
endif
endif # GERAN_MODE_SUPPORT
# *************************************************************************
# TARGET: asngen_l4
# Generate the ASN L4 codec template files for project
# *************************************************************************
asngen_l4: gen_infolog $(PREGEN_DEP)/asngen_l4.det
ifeq ($(strip $(SMART_CHECK)),TRUE)
include $(wildcard $(PREGEN_DEP)/./asngen_l4.det)
else
$(PREGEN_DEP)/asngen_l4.det: FORCE
endif
$(PREGEN_DEP)/asngen_l4.det:
ifeq ($(filter BASIC,$(TEST_LOAD_TYPE)),)
ifeq ($(strip $(CUSTOM_RELEASE)),FALSE)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_NOT_EXIST) $(strip $(PREGEN_DEP)) $(THEN) ($(MKDIR) $(strip $(PREGEN_DEP))) $(CMD_END)
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_precgen.log
endif
# To generate protocol/interface/asn/l4/gen_mcd_l4_common.asn
@perl protocol/tools/pre_mcdparser.pl --CC="$(CC)" --COMPILER=$(COMPILER) $(foreach def, $(MCD_DEFS),--SYMBOL=-D$(def) --PROJDIR="$(PROJDIR)" --DEPTARGET="$@")
@$(ECHO) -n "Generate L4 ASN Gen Files 1st Phase ..."
@$(CHDIR) protocol/tools $(AND) \
(perl ./mcdparser.pl mcd_l4.ini --only="$(strip $(PROJECT_MAKEFILE))" --deffile="../../$(INFOLOG)" --tstpath="$(MODISBUILD_TST_DB)" --PROJDIR="$(PROJDIR)" --DEPTARGET="$@")
ifneq ($(strip $(OS_VERSION)),MSWin32)
#delete target file for cleaning legacy code
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
@$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common >> $(strip $(COMPLOGDIR))/genJson.log 2>&1 $(WITH) \
($(IF_ERR_TRUE) $(THEN) \
((echo Error: the command is \"$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common\") $(AND) \
echo Error: Failed in tools/genTargetFile.py at $@. Please check $(strip $(COMPLOGDIR))/genJson.log $(WITH) exit 1) \
$(CMD_END))
endif
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
endif #CUSTOM_RELEASE
endif #not BASIC
# *************************************************************************
# TARGET: asngen
# Generate the ASN codec template files for project
# *************************************************************************
asngen: gen_infolog asngen_l4 $(PREGEN_DEP)/asngen.det
ifeq ($(strip $(SMART_CHECK)),TRUE)
include $(wildcard $(PREGEN_DEP)/./asngen.det)
else
$(PREGEN_DEP)/asngen.det: FORCE
endif
$(PREGEN_DEP)/asngen.det:
ifeq ($(filter BASIC,$(TEST_LOAD_TYPE)),)
ifeq ($(strip $(CUSTOM_RELEASE)),FALSE)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(ECHO) "$@ START TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
@$(IF_NOT_EXIST) $(strip $(PREGEN_DEP)) $(THEN) ($(MKDIR) $(strip $(PREGEN_DEP))) $(CMD_END)
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_precgen.log
endif
@$(ECHO) -n "Generate ASN Gen Files 1st Phase ..."
@$(CHDIR) protocol/tools $(AND) \
(perl ./mcdparser.pl mcd.ini --only="$(strip $(PROJECT_MAKEFILE))" --deffile="../../$(INFOLOG)" --tstpath="$(MODISBUILD_TST_DB)" --PROJDIR="$(PROJDIR)" --DEPTARGET="$@")
@($(ECHO) -n "Compiling Csi ASN files...") $(AND) \
$(CHDIR) protocol/as_utility/scsi/gen $(AND) \
(perl ./scsi_generate.pl --CC=$(CC) --COMPILER=$(COMPILER) --feature=" $(UMTS_RELEASE_SUPPORT) " --PROJDIR=$(PROJDIR) --DEPTARGET="$@")
@$(ECHO) -n "Compilation Csi ASN files done ..."
ifneq ($(strip $(OS_VERSION)),MSWin32)
#delete target file for cleaning legacy code
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
@$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common >> $(strip $(COMPLOGDIR))/genJson.log 2>&1 $(WITH) \
($(IF_ERR_TRUE) $(THEN) \
((echo Error: the command is \"$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common\") $(AND) \
echo Error: Failed in tools/genTargetFile.py at $@. Please check $(strip $(COMPLOGDIR))/genJson.log $(WITH) exit 1) \
$(CMD_END))
endif
@$(ECHO) "$@ END TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
endif #CUSTOM_RELEASE
endif #not BASIC
# *************************************************************************
# TARGET: asnregens
# *************************************************************************
asnregen: gen_infolog $(POSTGEN_DEP)/asnregen.det
ifeq ($(strip $(SMART_CHECK)),TRUE)
include $(wildcard $(POSTGEN_DEP)/./asnregen.det)
else
$(POSTGEN_DEP)/asnregen.det: FORCE
endif
$(POSTGEN_DEP)/asnregen.det:
ifneq ($(strip $(GERAN_MODE_SUPPORT)),NONE)
ifeq ($(RUN_ASNREGEN),TRUE)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(ECHO) "$@ START TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
@$(ECHO) -n "Generate ASN Gen Files 2nd Phase ..."
@$(IF_NOT_EXIST) $(strip $(POSTGEN_DEP)) $(THEN) ($(MKDIR) $(strip $(POSTGEN_DEP))) $(CMD_END)
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
# @$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" > $@
endif
ifneq ($(strip $(OS_VERSION)),MSWin32)
@$(IF_NOT_EXIST) $(strip $(PROJDIR))/modem/mcd_bak $(THEN) \
($(MKDIR) $(strip $(PROJDIR))/modem/mcd_bak) \
$(ELSE) \
($(LIST_DIR) "$(strip $(PROJDIR))/modem/mcd_bak/*.*" 1>$(DEV_NUL) 2>&1 $(WITH)\
$(IF_ERR_FALSE) $(THEN) $(DEL_FILE) $(strip $(PROJDIR))/modem/mcd_bak/*.* $(CMD_END))\
$(CMD_END)
@$(IF_EXIST) $(strip $(PROJDIR))/modem/mcd/mcd_table.c $(THEN) \
mv $(strip $(PROJDIR))/modem/mcd/mcd_table.c $(strip $(PROJDIR))/modem/mcd_bak/mcd_table.c >$(DEV_NUL) \
$(CMD_END)
@$(IF_EXIST) $(strip $(PROJDIR))/modem/mcd/mcd_msr.h $(THEN) \
mv $(strip $(PROJDIR))/modem/mcd/mcd_msr.h $(strip $(PROJDIR))/modem/mcd_bak/mcd_msr.h >$(DEV_NUL) \
$(CMD_END)
endif
ifeq ($(strip $(MODIS_CONFIG)),TRUE)
ifeq ($(strip $(CUSTOM_RELEASE)),FALSE)
@$(IF_NOT_EXIST) $(BUILD_TST_DB)/enumFile $(THEN) ($(IF_EXIST) $(MODISBUILD_TST_DB)/enumFile $(THEN) ($(COPY_FILE) $(MODISBUILD_TST_DB)/enumFile $(BUILD_TST_DB)/enumFile >$(DEV_NUL)) $(CMD_END)) $(CMD_END)
else
@$(IF_NOT_EXIST) $(BUILD_TST_DB)/enumFileCustomAppSrc $(THEN) ($(IF_EXIST) $(MODISBUILD_TST_DB)/enumFileCustomAppSrc $(THEN) ($(COPY_FILE) $(MODISBUILD_TST_DB)/enumFileCustomAppSrc $(BUILD_TST_DB)/enumFileCustomAppSrc >$(DEV_NUL)) $(CMD_END)) $(CMD_END)
endif
endif
ifeq ($(strip $(CUSTOM_RELEASE)),FALSE)
-@$(CHDIR) protocol/tools $(AND) \
(perl mcdparser.pl mcd.ini --only="$(strip $(PROJECT_MAKEFILE))" --only=for_catcher --deffile="../../$(INFOLOG)" --tstpath="$(MODISBUILD_TST_DB)" --PROJDIR="$(PROJDIR)" --DEPTARGET="$@")
else
-@$(CHDIR) protocol/tools $(AND) \
(perl mcdparser.pl mcd.ini --only="$(strip $(PROJECT_MAKEFILE))" --only=for_catcher --deffile="../../$(INFOLOG)" --custom --tstpath="$(MODISBUILD_TST_DB)" --PROJDIR="$(PROJDIR)" --DEPTARGET="$@")
endif
ifneq ($(strip $(OS_VERSION)),MSWin32)
@$(IF_EXIST) $(strip $(PROJDIR))/modem/mcd_bak/mcd_table.c $(THEN) \
(($(COMPARE) $(strip $(PROJDIR))/modem/mcd/mcd_table.c $(strip $(PROJDIR))/modem/mcd_bak/mcd_table.c >$(DEV_NUL) 2>&1) $(WITH) \
($(IF_ERR_FALSE) $(THEN) \
(touch -r $(strip $(PROJDIR))/modem/mcd_bak/mcd_table.c $(strip $(PROJDIR))/modem/mcd/mcd_table.c >$(DEV_NUL)) $(AND) \
(echo $(strip $(PROJDIR))/modem/mcd_bak/mcd_table.c timestamp is changed from $(strip $(PROJDIR))/modem/mcd_bak/mcd_table.c!) \
$(CMD_END))) \
$(CMD_END)
@$(IF_EXIST) $(strip $(PROJDIR))/modem/mcd_bak/mcd_msr.h $(THEN) \
(($(COMPARE) $(strip $(PROJDIR))/modem/mcd/mcd_msr.h $(strip $(PROJDIR))/modem/mcd_bak/mcd_msr.h >$(DEV_NUL) 2>&1) $(WITH) \
($(IF_ERR_FALSE) $(THEN) \
(touch -r $(strip $(PROJDIR))/modem/mcd_bak/mcd_msr.h $(strip $(PROJDIR))/modem/mcd/mcd_msr.h >$(DEV_NUL)) $(AND) \
(echo $(strip $(PROJDIR))/modem/mcd_bak/mcd_msr.h timestamp is changed from $(strip $(PROJDIR))/modem/mcd_bak/mcd_msr.h!) \
$(CMD_END))) \
$(CMD_END)
@$(IF_EXIST) $(strip $(PROJDIR))/modem/mcd_bak $(THEN) ($(DEL_DIR) $(strip $(PROJDIR))/modem/mcd_bak) $(CMD_END)
endif
@$(ECHO) "$@ END TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
endif
endif # GERAN_MODE_SUPPORT
# *************************************************************************
# TARGET: nvram_edit_h_gen
# *************************************************************************
nvram_edit_h_gen: $(strip $(PROJDIR))/nvram_auto_gen/nvram_editor.h
include $(wildcard $(strip $(RULESDIR_TARGET))/codegen_dep/nvram_editor.det)
$(strip $(PROJDIR))/nvram_auto_gen/nvram_editor.h:
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_NOT_EXIST) $(strip $(RULESDIR_TARGET))/codegen_dep $(THEN) $(MKDIR) $(strip $(RULESDIR_TARGET))/codegen_dep $(CMD_END)
@$(IF_EXIST) $(strip $(RULESDIR_TARGET))/codegen_dep/nvram_editor.det $(THEN) ($(DEL_FILE) $(strip $(RULESDIR_TARGET))/codegen_dep/nvram_editor.det) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_precgen.log
endif
@$(IF_NOT_EXIST) $(strip $(PROJDIR))/nvram_auto_gen $(THEN) $(MKDIR) $(strip $(PROJDIR))/nvram_auto_gen $(CMD_END)
@$(IF_EXIST) ./tools/NVRAMStatistic/nvram_edit_gen.mak $(THEN)\
($(MAKE) -f ./tools/NVRAMStatistic/nvram_edit_gen.mak -r -R NVRAM_EDITOR_H_TO_DB NVRAM_AUTO_GEN_PATH=$(strip $(PROJDIR)) > $(strip $(COMPLOGDIR))/nvram_edit_h_gen.log 2>&1) \
$(CMD_END)
ifneq ($(strip $(OS_VERSION)),MSWin32)
@$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $(strip $(RULESDIR_TARGET))/codegen_dep/nvram_editor.det $(strip $(RULESDIR_TARGET))/codegen_dep/nvram_editor.det common >> $(strip $(COMPLOGDIR))/genJson.log 2>&1 $(WITH) \
($(IF_ERR_TRUE) $(THEN) \
((echo Error: the command is \"$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $(strip $(RULESDIR_TARGET))/codegen_dep/nvram_editor.det $(strip $(RULESDIR_TARGET))/codegen_dep/nvram_editor.det common\") $(AND) \
echo Error: Failed in tools/genTargetFile.py at $(strip $(RULESDIR_TARGET))/codegen_dep/nvram_editor.det. Please check $(strip $(COMPLOGDIR))/genJson.log $(WITH) exit 1)\
$(CMD_END))
endif
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: genmoduleinfo
# Generate module.lis/inc/def in $MODULELIS
# *************************************************************************
genmoduleinfo: genlog gencompbld gencategorymapping
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_NOT_EXIST) $(MODULEINFODIR) $(THEN) ($(MKDIR) $(MODULEINFODIR)) $(CMD_END)
ifeq ($(strip $(MODIS_CONFIG)),TRUE)
@$(IF_NOT_EXIST) $(MODISLOGDIR)/modis_setup $(THEN) $(MKDIR) $(MODISLOGDIR)/modis_setup $(CMD_END)
@$(MAKE) -fmake/common/build.mak -r -R $(CMD_ARGU) --no-print-directory AUTO_CHECK_DEPEND=$(AUTO_CHECK_DEPEND) AUTO_CHECK_CGEN=$(AUTO_CHECK_CGEN) MODIS_CONFIG=$(strip $(MODIS_CONFIG)) MODIS_UESIM=$(strip $(MODIS_UESIM)) genmoduleinfo_start
@$(ECHO) -n setup $(strip $(MODIS_UESIM)) env is done
else
@$(IF_NOT_EXIST) $(strip $(COMPLOGDIR))/module_info $(THEN) $(MKDIR) $(strip $(COMPLOGDIR))/module_info $(CMD_END)
@$(CHK_TIME)
@$(MAKE) -fmake/common/build.mak -r -R $(CMD_ARGU) --no-print-directory AUTO_CHECK_DEPEND=$(AUTO_CHECK_DEPEND) AUTO_CHECK_CGEN=$(AUTO_CHECK_CGEN) genmoduleinfo_start
@$(ECHO) -n "Generating .lis and .def files are done"
@$(CHK_TIME)
endif
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: gencategorymapping
# *************************************************************************
gencategorymapping:
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@perl ./tools/gencategorymapping.pl $(strip $(TMPDIR))/~categorymapping.mak
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: genmoduleinfo_start
# *************************************************************************
genmoduleinfo_start: $(ALL_MODULELIS)
@$(ECHO) -n genmoduleinfo is done.
# *************************************************************************
# TARGET: %.lis
# *************************************************************************
%.lis:
ifeq ($(strip $(MODIS_CONFIG)),TRUE)
@$(ECHO) -n setup $(strip $(MODIS_UESIM)) env of $*
@($(MAKE) -fmake/common/comp.mak -k -r -R TMPDIR=$(strip $(TMPDIR)) $(strip $(CMD_ARGU)) --no-print-directory COMPONENT=$* GEN_MODULE_INFO=TRUE setup_env >$(MODISLOGDIR)/modis_setup/$*_setEnv.log 2>&1) $(WITH) \
$(IF_ERR_TRUE) $(THEN) (echo Error: $@ Failed! Please check $(MODISLOGDIR)/modis_setup/$*_setEnv.log $(WITH) exit 1) $(CMD_END)
else
@($(MAKE) -fmake/common/comp.mak -k -r -R TMPDIR=$(strip $(TMPDIR)) $(strip $(CMD_ARGU)) --no-print-directory COMPONENT=$* GEN_MODULE_INFO=TRUE setup_env > $(strip $(COMPLOGDIR))/module_info/$*_module_info.log 2>&1) $(WITH) \
$(IF_ERR_TRUE) $(THEN) (echo Error: $@ Failed! Please check $(strip $(COMPLOGDIR))/module_info/$*_module_info.log $(WITH) exit 1) $(CMD_END)
@$(ECHO) -n Generate $* information
endif
ifneq ($(strip $(OS_VERSION)),MSWin32)
# backup .def for incremental build
@$(IF_EXIST) $(strip $(MODULEINFODIR))/$*/$*.def.bak $(THEN) \
(($(COMPARE) $(strip $(MODULEINFODIR))/$*/$*.def.bak $(strip $(MODULEINFODIR))/$*/$*.def >$(DEV_NUL) 2>&1) $(WITH) \
($(IF_ERR_FALSE) $(THEN) \
(touch -r $(strip $(MODULEINFODIR))/$*/$*.def.bak $(strip $(MODULEINFODIR))/$*/$*.def >$(DEV_NUL)) \
$(CMD_END))) $(AND) \
($(DEL_FILE) $(strip $(MODULEINFODIR))/$*/$*.def.bak) \
$(CMD_END)
endif
# *************************************************************************
# Target: nvram_auto_gen
# *************************************************************************
nvram_auto_gen:
ifneq ($(filter __MOD_NVRAM__,$(strip $(COM_DEFS))),)
nvram_auto_gen: $(strip $(RULESDIR_TARGET))/codegen_dep/nvram_auto_gen.det
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
cgen: $(strip $(RULESDIR_TARGET))/codegen_dep/nvram_auto_gen.det
endif
# *************************************************************************
# Target: (strip $(RULESDIR_TARGET))/codegen_dep/nvram_auto_gen.det:
# *************************************************************************
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(strip $(RULESDIR_TARGET))/codegen_dep/nvram_auto_gen.det: FORCE
else
-include $(strip $(RULESDIR_TARGET))/codegen_dep/./nvram_auto_gen.det
endif
$(strip $(RULESDIR_TARGET))/codegen_dep/nvram_auto_gen.det: $(strip $(PROJDIR))/nvram_auto_gen/nvram_editor.h
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_precgen.log
endif
@$(ECHO) "$@ START TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
ifeq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
-@$(ECHO) -n $@: $?
endif
@$(IF_NOT_EXIST) $(strip $(RULESDIR_TARGET)) $(THEN) \
($(MKDIR) $(strip $(RULESDIR_TARGET))) \
$(ELSE) \
($(IF_EXIST) $(strip $(RULESDIR_TARGET))/nvram_auto_gen.dep $(THEN) \
$(DEL_FILE) $(strip $(RULESDIR_TARGET))/nvram_auto_gen.dep \
$(CMD_END)) \
$(CMD_END)
@$(IF_NOT_EXIST) $(patsubst %/,%,$(dir $@)) $(THEN) \
($(MKDIR) $(patsubst %/,%,$(dir $@))) \
$(ELSE) \
($(IF_EXIST) $@ $(THEN) $(DEL_FILE) $@ \
$(CMD_END)) \
$(CMD_END)
ifeq ($(strip $(OS_VERSION)),MSWin32)
@$(STRCMPEX) TRUE TRUE e $(strip $(TMPDIR))/~cus_opt.tmp $(foreach def,$(sort $(COM_DEFS_TARGET)),$(def) )
else
@$(STRCMPEX) TRUE TRUE e $(strip $(TMPDIR))/~cus_opt.tmp $(foreach def,$(sort $(COM_DEFS_TARGET)),-D \"$(def)\")
endif
@$(STRCMPEX) TRUE TRUE e $(strip $(TMPDIR))/~inc.tmp $(foreach inc,$(XGEN_INC_DIR_TARGET),$(inc))
ifneq ($(filter __MOD_NVRAM__,$(strip $(COM_DEFS))),)
@$(IF_NOT_EXIST) $(strip $(BUILD_TST_DB))/pstrace_db $(THEN) ($(MKDIR) $(strip $(BUILD_TST_DB))/pstrace_db) $(CMD_END)
@$(IF_NOT_EXIST) $(MODISBUILD_TST_DB)/pstrace_db $(THEN) ($(MKDIR) $(MODISBUILD_TST_DB)/pstrace_db) $(CMD_END)
@$(IF_EXIST) $(MODISBUILD_TST_DB)/CompTrcDefs.lst $(THEN) ($(DEL_FILE) $(MODISBUILD_TST_DB)/CompTrcDefs.lst) $(CMD_END)
@$(IF_NOT_EXIST) $(strip $(PROJDIR))/nvram_auto_gen $(THEN) ($(MKDIR) $(strip $(PROJDIR))/nvram_auto_gen) $(CMD_END)
@$(IF_NOT_EXIST) $(strip $(PROJDIR))/cksysdrv $(THEN) ($(MKDIR) $(strip $(PROJDIR))/cksysdrv) $(CMD_END)
@$(IF_NOT_EXIST) $(strip $(PROJDIR))/nvram_auto_gen/include $(THEN) ($(MKDIR) $(strip $(PROJDIR))/nvram_auto_gen/include) $(CMD_END)
@$(IF_NOT_EXIST) $(strip $(PROJDIR))/nvram_auto_gen/debug $(THEN) ($(MKDIR) $(strip $(PROJDIR))/nvram_auto_gen/debug) $(CMD_END)
@$(IF_NOT_EXIST) $(strip $(PROJDIR))/nvram_auto_gen/debug_target $(THEN) ($(MKDIR) $(strip $(PROJDIR))/nvram_auto_gen/debug_target) $(CMD_END)
ifeq ($(strip $(OS_VERSION)),MSWin32)
@perl ./tools/lnitem.pl $(strip $(TMPDIR))/~cus_opt.tmp
@$(IF_EXIST) $(strip $(PROJDIR))/nvram_auto_gen/include/custom_option.txt $(THEN) ($(DEL_FILE) $(strip $(PROJDIR))/nvram_auto_gen/include/custom_option.txt) $(CMD_END)
@$(FOR) $(F_OPT) $(DECLARE_VAR)i $(IN) `$(CAT) $(strip $(TMPDIR))/~cus_opt.tmp` \
$(DO) \
$(ECHO) -n "#define $(PRE_VAR)i" >> $(strip $(PROJDIR))/nvram_auto_gen/include/~custom_option.tmp \
$(DONE)
@perl ./tools/replace_string.pl $(strip $(PROJDIR))/nvram_auto_gen/include/~custom_option.tmp = " " $(strip $(PROJDIR))/nvram_auto_gen/include/custom_option.txt
@$(ECHO) -n OS_VERSION = $(strip $(OS_VERSION)) > $(strip $(PROJDIR))/nvram_auto_gen/include/custom_include.txt
@$(ECHO) CUSTOM_INC = >> $(strip $(PROJDIR))/nvram_auto_gen/include/custom_include.txt
else
@$(ECHO) -n OS_VERSION = $(strip $(OS_VERSION)) > $(strip $(PROJDIR))/nvram_auto_gen/include/custom_option.txt
@$(ECHO) CUSTOM_OPTION = >> $(strip $(PROJDIR))/nvram_auto_gen/include/custom_option.txt
@$(CAT) $(strip $(TMPDIR))/~cus_opt.tmp >> $(strip $(PROJDIR))/nvram_auto_gen/include/custom_option.txt
@$(ECHO) CUSTOM_INC = > $(strip $(PROJDIR))/nvram_auto_gen/include/custom_include.txt
endif
@$(COPY_FILE) $(strip $(TMPDIR))/~inc.tmp $(strip $(TMPDIR))/~inc.tmp.tmp
@perl ./tools/lnitem.pl $(strip $(TMPDIR))/~inc.tmp.tmp
@$(FOR) $(F_OPT) $(DECLARE_VAR)i $(IN) `$(CAT) $(strip $(TMPDIR))/~inc.tmp.tmp` \
$(DO) \
$(ECHO) " " -I "$(subst \,/,$(PRE_VAR)i)" >> $(strip $(PROJDIR))/nvram_auto_gen/include/custom_include.txt \
$(DONE)
#Output NVRAM info
@$(IF_EXIST) $(strip $(COMPLOGDIR))/nvram_gen.log $(THEN) ($(DEL_FILE) $(strip $(COMPLOGDIR))/nvram_gen.log) $(CMD_END)
@$(IF_EXIST) $(strip $(COMPLOGDIR))/nvram_gen_full_log.log $(THEN) ($(DEL_FILE) $(strip $(COMPLOGDIR))/nvram_gen_full_log.log) $(CMD_END)
@$(LIST_DIR) "$(strip $(PROJDIR))/nvram_auto_gen/debug/*.*" 1>$(DEV_NUL) 2>&1 $(WITH)\
$(IF_ERR_FALSE) $(THEN) $(DEL_FILE) $(strip $(PROJDIR))/nvram_auto_gen/debug/*.* $(CMD_END)
ifeq ($(strip $(OS_VERSION)),MSWin32)
@$(IF_EXIST) ./tools/NVRAMStatistic/nvram_auto_gen.mak $(THEN)\
("tools\MSYS\bin\make.exe" -e -f ./tools/NVRAMStatistic/nvram_auto_gen.mak -r -R -j 1 nvram_auto_gen_build PROJECT_MAKEFILE="$(strip $(PROJECT_MAKEFILE))" NVRAM_AUTO_GEN_PATH=$(strip $(PROJDIR))/nvram_auto_gen 1> $(strip $(COMPLOGDIR))/nvram_gen_full_log.log 2>$(strip $(COMPLOGDIR))/nvram_gen.log) \
$(CMD_END)
ifneq ($(strip $(NVRAM_AUTOGEN_V2)), TRUE)
@$(IF_EXIST) $(PROJDIR)/nvram_auto_gen/nvram_auto_gen.exe $(THEN)\
("$(strip $(PROJDIR))/nvram_auto_gen/nvram_auto_gen.exe" $(strip $(PROJDIR)) $(strip $(OS_VERSION)) 1 >> $(strip $(COMPLOGDIR))/nvram_gen_full_log.log 2>>$(strip $(COMPLOGDIR))/nvram_gen.log)\
$(CMD_END)
else
# nvram autogen v2
@python ./tools/NVRAMStatistic/autogen_v2/run.py -p $(strip $(PROJDIR)) 1 >> $(strip $(COMPLOGDIR))/nvram_gen_full_log.log 2>>$(strip $(COMPLOGDIR))/nvram_gen.log $(WITH) \
$(IF_ERR_TRUE) $(THEN) (echo Error: nvram_auto_gen failed. Please check $(strip $(COMPLOGDIR))/nvram_gen.log $(WITH) exit 1) $(CMD_END)
endif
else
@$(IF_EXIST) ./tools/NVRAMStatistic/nvram_auto_gen.mak $(THEN)\
($(MAKE) -f ./tools/NVRAMStatistic/nvram_auto_gen.mak -r -R -j 1 nvram_auto_gen_build PROJECT_MAKEFILE="$(strip $(PROJECT_MAKEFILE))" NVRAM_AUTO_GEN_PATH=$(strip $(PROJDIR))/nvram_auto_gen > $(strip $(COMPLOGDIR))/nvram_gen_full_log.log 2>$(strip $(COMPLOGDIR))/nvram_gen.log) $(WITH)\
$(IF_ERR_TRUE) $(THEN) (echo Error: nvram_auto_gen failed. Please check $(strip $(COMPLOGDIR))/nvram_gen.log $(WITH) exit 1) $(CMD_END) \
$(CMD_END)
ifneq ($(strip $(NVRAM_AUTOGEN_V2)), TRUE)
@$(IF_EXIST) $(PROJDIR)/nvram_auto_gen/nvram_auto_gen $(THEN)\
("$(strip $(PROJDIR))/nvram_auto_gen/nvram_auto_gen" $(strip $(PROJDIR)) $(strip $(OS_VERSION)) 1 >> $(strip $(COMPLOGDIR))/nvram_gen_full_log.log 2>>$(strip $(COMPLOGDIR))/nvram_gen.log $(WITH) \
$(IF_ERR_TRUE) $(THEN) (echo Error: nvram_auto_gen failed. Please check $(strip $(COMPLOGDIR))/nvram_gen.log $(WITH) exit 1) $(CMD_END))\
$(CMD_END)
else
# nvram autogen v2
@python ./tools/NVRAMStatistic/autogen_v2/run.py -p $(strip $(PROJDIR)) 1 >> $(strip $(COMPLOGDIR))/nvram_gen_full_log.log 2>>$(strip $(COMPLOGDIR))/nvram_gen.log $(WITH) \
$(IF_ERR_TRUE) $(THEN) (echo Error: nvram_auto_gen failed. Please check $(strip $(COMPLOGDIR))/nvram_gen.log $(WITH) exit 1) $(CMD_END)
endif
endif
@perl ./tools/NVRAMStatistic/nvram_usage_check.pl $(strip $(COMPLOGDIR))/nvram_usage_check.log $@ >> $(strip $(COMPLOGDIR))/nvram_gen_full_log.log 2>>$(strip $(COMPLOGDIR))/nvram_gen.log $(WITH) \
$(IF_ERR_TRUE) $(THEN) (echo Error: nvram_usage_check failed. Please check $(strip $(COMPLOGDIR))/nvram_gen.log $(WITH) exit 1) $(CMD_END)
ifneq ($(strip $(NVRAM_AUTOGEN_V2)),TRUE)
@perl ./tools/pack_dep_gcc.pl $(RULESDIR_TARGET)/nvram_auto_gen.dep $(PROJDIR)/nvram_auto_gen/debug $(HTOGETHER) $(strip $(HEADER_TEMP))
else
@perl ./tools/pack_dep_gcc.pl $(RULESDIR_TARGET)/nvram_auto_gen.dep $(PROJDIR)/nvram_auto_gen/debug_target $(HTOGETHER) $(strip $(HEADER_TEMP))
endif
@$(IF_EXIST) $(PROJDIR)/nvram_auto_gen/nvram_lid_statistics_bak.h $(THEN) \
($(COPY_FILE) $(PROJDIR)/nvram_auto_gen/nvram_lid_statistics_bak.h $(PROJDIR)/nvram_auto_gen/nvram_lid_statistics.h >$(DEV_NUL)) $(CMD_END)
endif
ifneq ($(strip $(NVRAM_AUTOGEN_V2)),TRUE)
@perl ./tools/pack_dep_gen.pl $@ $@ $(PROJDIR)/nvram_auto_gen/debug "\.d"
else
@perl ./tools/pack_dep_gen.pl $@ $@ $(PROJDIR)/nvram_auto_gen/debug_target "\.d"
endif
@$(ECHO) -n "$@: $(strip $(PROJDIR))/nvram_auto_gen/nvram_editor.h" >> $@
@$(ECHO) -n "$@: tools/NVRAMStatistic/nvram_lid_check.pl" >> $@
@$(ECHO) -n "$@: tools/NVRAMStatistic/nvram_usage_check.pl" >> $@
ifneq ($(PCIBT_ACTION_LIST),)
$(PCIBT_SCRIPT_CMD) $(CHK_LTE_COMP) "tools/NVRAMStatistic/src/nvram_auto_gen.c" $@ $(PCIBT_ACTION_LIST) 2>>$(strip $(COMPLOGDIR))/nvram_gen.log
endif
@$(IF_EXIST) $(MODISBUILD_TST_DB)/MDDB_InfoCustomAppSrc.EDB $(THEN) ($(DEL_FILE) $(MODISBUILD_TST_DB)/MDDB_InfoCustomAppSrc.EDB) $(CMD_END)
@$(ECHO) "$@ END TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
endif
# *************************************************************************
# TARGET: cgen
# *************************************************************************
cgen: $(MODIS_RULESDIR)/codegen_dep/cgen_preflow.det
cgen_preprocess: $(CODEGEN_PREPROCESS_MODEM)
ifeq ($(strip $(DHL_SUPPORT)),TRUE)
ifeq ($(MPD_SOURCE_FULL_BUILD),TRUE)
cgen_cfg: $(CODEGEN_DEPENDENCY_MODEM_SEC)
endif
ifeq ($(MPD_SOURCE_4G_BUILD),TRUE)
cgen_cfg: $(CODEGEN_DEPENDENCY_MODEM_4G)
endif
endif
cgen_cfg: $(CODEGEN_DEPENDENCY_MODEM) $(MODIS_RULESDIR)/codegen_dep/cgen_cfg_Modem.det
CODEGEN_PREPROCESS_TEST := PARALLEL
ifneq ($(strip $(CODEGEN_PREPROCESS_TEST)),PARALLEL)
ifneq ($(strip $(CODEGEN_DEPENDENCY_MODEM)),)
cgen: cgen_cfg
endif
else
cgen: FORCE
ifneq ($(strip $(CODEGEN_DEPENDENCY_MODEM)),)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(MAKE) -fmake/common/build.mak -r -R $(CMD_ARGU) --no-print-directory SMART_CHECK=$(SMART_CHECK) AUTO_CHECK_DEPEND=$(AUTO_CHECK_DEPEND) AUTO_CHECK_CGEN=$(AUTO_CHECK_CGEN) MODIS_CONFIG=$(strip $(MODIS_CONFIG)) MODIS_UESIM=$(strip $(MODIS_UESIM)) RUN_CGEN_L1=$(RUN_CGEN_L1) cgen_preprocess
@$(MAKE) -fmake/common/build.mak -r -R --no-print-directory SMART_CHECK=$(SMART_CHECK) AUTO_CHECK_DEPEND=$(AUTO_CHECK_DEPEND) AUTO_CHECK_CGEN=TRUE MODIS_CONFIG=$(strip $(MODIS_CONFIG)) MODIS_UESIM=$(strip $(MODIS_UESIM)) RUN_CGEN_L1=$(RUN_CGEN_L1) cgen_cfg
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
endif
endif
# *************************************************************************
# TARGET: cgen
# Step 1: Preprocess
# *************************************************************************
TRCGEN_LIST = $(strip $(LOGGING_DATABASE))/TrcGen.lst
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_preflow.det: FORCE
else
-include $(MODIS_RULESDIR)/codegen_dep/./codegen.det
endif
$(MODIS_RULESDIR)/codegen_dep/cgen_preflow.det: $(strip $(TRCGEN_LIST)) $(NEED_CHECK_DEPEND_LIST) $(VERNOFILE)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(ECHO) "$@ START TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
ifneq ($(strip $(CLEAN_CODEGEN_DEPENDENCY)),)
@$(FOR) $(DECLARE_VAR)i $(IN) $(CLEAN_CODEGEN_DEPENDENCY) $(DO) \
($(IF_EXIST) $(PRE_VAR)i $(THEN) $(DEL_FILE) $(PRE_VAR)i $(CMD_END)) \
$(DONE)
endif
@$(IF_EXIST) $(strip $(CGEN_CFG_MODEM)) $(THEN) $(DEL_FILE) $(strip $(CGEN_CFG_MODEM)) $(CMD_END)
@$(IF_EXIST) $(strip $(CGEN_CFG_MODEM_SEC)) $(THEN) $(DEL_FILE) $(strip $(CGEN_CFG_MODEM_SEC)) $(CMD_END)
@$(IF_EXIST) $(strip $(POSTGEN_CFG_MODEM)) $(THEN) $(DEL_FILE) $(strip $(POSTGEN_CFG_MODEM)) $(CMD_END)
ifneq ($(wildcard $(MODISBUILD_TST_DB)/*MDDB*),)
@$(DEL_FILE) $(strip $(MODISBUILD_TST_DB)/*MDDB*)
endif
@$(IF_EXIST) $(strip $(CODE_GEN_LOG)) $(THEN) $(DEL_FILE) $(strip $(CODE_GEN_LOG)) $(CMD_END)
@$(ECHO) -n "Check Directories ..."
@$(IF_NOT_EXIST) $(MODISBUILD_TST_DB) $(THEN) $(MKDIR) $(MODISBUILD_TST_DB) $(CMD_END)
@$(IF_NOT_EXIST) $(MODISBUILD_TST_DB)/msglog_db $(THEN) $(MKDIR) $(MODISBUILD_TST_DB)/msglog_db $(CMD_END)
@$(IF_NOT_EXIST) $(MODISBUILD_TST_DB)/pstrace_db $(THEN) $(MKDIR) $(MODISBUILD_TST_DB)/pstrace_db $(CMD_END)
@$(IF_NOT_EXIST) $(MODISBUILD_TST_DB)/unionTag $(THEN) $(MKDIR) $(MODISBUILD_TST_DB)/unionTag $(CMD_END)
@$(IF_NOT_EXIST) $(MODISBUILD_TST_DB)/unionTag/ext $(THEN) $(MKDIR) $(MODISBUILD_TST_DB)/unionTag/ext $(CMD_END)
@$(IF_NOT_EXIST) $(patsubst %/,%,$(dir $@)) $(THEN) $(MKDIR) $(patsubst %/,%,$(dir $@)) $(CMD_END)
ifeq ($(strip $(DHL_SUPPORT)),TRUE)
ifeq ($(MPD_SOURCE_FULL_BUILD),TRUE)
@$(IF_NOT_EXIST) $(MODISBUILD_TST_DB_SEC) $(THEN) $(MKDIR) $(MODISBUILD_TST_DB_SEC) $(CMD_END)
@$(IF_NOT_EXIST) $(MODISBUILD_TST_DB_SEC)/msglog_db $(THEN) $(MKDIR) $(MODISBUILD_TST_DB_SEC)/msglog_db $(CMD_END)
@$(IF_NOT_EXIST) $(MODISBUILD_TST_DB_SEC)/pstrace_db $(THEN) $(MKDIR) $(MODISBUILD_TST_DB_SEC)/pstrace_db $(CMD_END)
endif
endif
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
@$(MAKE) -fmake/common/build.mak -r -R --no-print-directory gen_sfini
else
@$(IF_NOT_EXIST) $(MODISLOGDIR) $(THEN) $(MKDIR) $(MODISLOGDIR) $(CMD_END)
endif
@$(IF_EXIST) $(MODISBUILD_TST_DB)/CompTrcDefs.lst $(THEN) $(DEL_FILE) $(MODISBUILD_TST_DB)/CompTrcDefs.lst $(CMD_END)
ifeq ($(strip $(CUSTOM_RELEASE)),FALSE)
@$(IF_NOT_EXIST) $(CODEGEN_DATABASE_OUT) $(THEN) ($(IF_EXIST) $(MODIS_RULESDIR)/codegen_dep/cgen_c.det $(THEN) ($(DEL_FILE) $(MODIS_RULESDIR)/codegen_dep/cgen_c.det)$(CMD_END)) $(CMD_END)
endif
@$(MAKE) -fmake/common/build.mak -r -R --no-print-directory GAS_FOLDER=protocol/2g/gas UAS_FOLDER=protocol/3g/urr/urr_fdd XGEN_SWITCH_FDD_TDD=FDD $(strip $(TMPDIR))/~inc_fdd_def.tmp
ifeq ($(strip $(UMTS_TDD_SUPPORT)),UMTS_TDD128_MODE_SUPPORT)
@$(MAKE) -fmake/common/build.mak -r -R --no-print-directory GAS_FOLDER=protocol/2g/gas_tdd UAS_FOLDER=protocol/3g/urr/urr_tdd XGEN_SWITCH_FDD_TDD=TDD $(strip $(TMPDIR))/~inc_tdd_def.tmp
endif
@$(MAKE) -fmake/common/build.mak -r -R --no-print-directory $(strip $(TMPDIR))/~inc_def.tmp
@$(ECHO) -n "$@: $(NEED_CHECK_DEPEND_LIST)" >>$@
@$(ECHO) -n "$@" >>$(CODE_GEN_LST)
ifeq ($(strip $(MODIS_CONFIG)),TRUE)
ifneq ($(strip $(UE_SIMULATOR)),TRUE)
@python ./tools/icd_header_converter.py -p "./interface/service/icd" -proj "$(PROJECT_NAME)" -flavor "$(FLAVOR)"
endif
endif
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: $(strip $(TMPDIR))/~inc_def.tmp
# *************************************************************************
$(strip $(TMPDIR))/~inc_def.tmp: FORCE
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
@$(STRCMPEX) def def e $(strip $(TMPDIR))/~inc_def.tmp $(foreach def,$(COM_DEFS) __NULL_DEF__,-D$(def))
@$(STRCMPEX) inc inc e $(strip $(TMPDIR))/~inc.tmp $(foreach inc,$(subst \,/,$(XGEN_INC_DIR)),-I$(inc))
else
@$(STRCMPEX) def def e $(strip $(TMPDIR))/~inc_def.tmp -D__NULL_DEF__
@$(STRCMPEX) inc inc e $(strip $(TMPDIR))/~inc.tmp $(foreach inc,$(XGEN_INC_DIR),-I$(inc))
endif
@perl ./tools/echoLongString2.pl $(strip $(TMPDIR))/~inc_def.tmp -D $(COM_DEF_PATH)
@$(CAT) "$(strip $(TMPDIR))/~inc.tmp" >>$(strip $(TMPDIR))/~inc_def.tmp
@$(IF_EXIST) $(strip $(TMPDIR))/~inc.tmp $(THEN) $(DEL_FILE) $(strip $(TMPDIR))/~inc.tmp $(CMD_END)
@$(ECHO) -n "$(strip $(TMPDIR))/~inc_def.tmp" >> $(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: $(strip $(TMPDIR))/~inc_def_no_inc.tmp
# *************************************************************************
$(strip $(TMPDIR))/~inc_def_no_inc.tmp: FORCE
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(STRCMPEX) def def e $(strip $(TMPDIR))/~inc_def_no_inc.tmp -D__NULL_DEF__
@perl ./tools/echoLongString2.pl $(strip $(TMPDIR))/~inc_def_no_inc.tmp -D $(COM_DEF_PATH)
@$(ECHO) -n "$(strip $(TMPDIR))/~inc_def_no_inc.tmp" >> $(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: $(strip $(TMPDIR))/~inc_fdd_def.tmp
# *************************************************************************
$(strip $(TMPDIR))/~inc_fdd_def.tmp: FORCE
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(STRCMPEX) def def e $(strip $(TMPDIR))/~inc_fdd_def.tmp $(foreach def,$(filter-out __CGEN_UMTS_TDD128_MODE__,$(COM_DEFS)) __NULL_DEF__ __CGEN_UMTS_FDD_MODE__,-D$(def))
@$(STRCMPEX) inc inc e $(strip $(TMPDIR))/~inc_fdd.tmp $(foreach inc,$(XGEN_INC_DIR),-I$(inc))
@perl ./tools/echoLongString2.pl $(strip $(TMPDIR))/~inc_fdd_def.tmp -D $(filter-out %uas_tdd128.def %gas_tdd128.def, $(ALL_MODULEDEF))
@$(CAT) "$(strip $(TMPDIR))/~inc_fdd.tmp" >>$(strip $(TMPDIR))/~inc_fdd_def.tmp
@$(IF_EXIST) $(strip $(TMPDIR))/~inc_fdd.tmp $(THEN) $(DEL_FILE) $(strip $(TMPDIR))/~inc_fdd.tmp $(CMD_END)
@$(ECHO) -n "$(strip $(TMPDIR))/~inc_fdd_def.tmp" >> $(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: $(strip $(TMPDIR))/~inc_tdd_def.tmp
# *************************************************************************
$(strip $(TMPDIR))/~inc_tdd_def.tmp: FORCE
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(STRCMPEX) def def e $(strip $(TMPDIR))/~inc_tdd_def.tmp $(foreach def,$(filter-out __CGEN_UMTS_FDD_MODE__ ,$(COM_DEFS)) __NULL_DEF__ __CGEN_UMTS_TDD128_MODE__,-D$(def))
@$(STRCMPEX) inc inc e $(strip $(TMPDIR))/~inc_tdd.tmp $(foreach inc,$(XGEN_INC_DIR),-I$(inc))
@perl ./tools/echoLongString2.pl $(strip $(TMPDIR))/~inc_tdd_def.tmp -D $(filter-out %uas.def %gas.def, $(ALL_MODULEDEF))
@$(CAT) "$(strip $(TMPDIR))/~inc_tdd.tmp" >>$(strip $(TMPDIR))/~inc_tdd_def.tmp
@$(IF_EXIST) $(strip $(TMPDIR))/~inc_tdd.tmp $(THEN) $(DEL_FILE) $(strip $(TMPDIR))/~inc_tdd.tmp $(CMD_END)
@$(ECHO) -n "$(strip $(TMPDIR))/~inc_tdd_def.tmp" >> $(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
ifeq ($(MPD_SOURCE_4G_BUILD),TRUE)
$(eval $(call CgenPreprocess,$(strip $(TSTDIR))/database/msglog_db/libParseDbModem_4g.c,$(MODISBUILD_TST_DB_4G)/msglog_db/libParseDbModem_4g.db,libParseDbModem_4g.det,FALSE))
$(eval $(call CgenPreprocess,$(strip $(TSTDIR))/database/gv/4g/gv_db_4g.c,$(MODISBUILD_TST_DB_4G)/gv/gv_db/gv_db_4g.gv,gv_db_4g.det))
$(eval $(call CgenPreprocess,$(strip $(TSTDIR))/database/unionTag/4g/unionTag_db_4g.c,$(MODISBUILD_TST_DB_4G)/unionTag/unionTag_parse_4g.txt,unionTag_parse_4g.det))
$(eval $(call CgenPreprocess,$(strip $(TSTDIR))/database/l1validation_db/4g/l1v_db_4g.c,$(MODISBUILD_TST_DB_4G)/l1validation_db/l1v_db/l1v_db_4g.l1v,l1v_db_4g.det))
endif
$(eval $(call CgenPreprocess,$(strip $(TSTDIR))/database/msglog_db/libParseDbModem.c,$(MODISBUILD_TST_DB)/msglog_db/libParseDbModem.db,libParseDbModem.det,FALSE))
$(eval $(call CgenPreprocess,$(strip $(TSTDIR))/database/msglog_db/srcParseDbModem.c,$(MODISBUILD_TST_DB)/msglog_db/srcParseDbModem.db,srcParseDbModem.det,FALSE))
$(eval $(call CgenPreprocess,$(strip $(TSTDIR))/database/msglog_db/custom_parse_db.c,$(MODISBUILD_TST_DB)/msglog_db/custom_parse_db.db,custom_parse_db.det,FALSE))
$(eval $(call CgenPreprocess,$(strip $(TSTDIR))/database/msglog_db/libParseDbModem_tdd_fdd.c,$(MODISBUILD_TST_DB)/msglog_db/libParseDbModem.db,libParseDbModem_tdd_fdd.det,TRUE))
$(eval $(call CgenPreprocess,$(strip $(TSTDIR))/database/msglog_db/srcParseDbModem_tdd_fdd.c,$(MODISBUILD_TST_DB)/msglog_db/srcParseDbModem.db,srcParseDbModem_tdd_fdd.det,TRUE))
$(eval $(call CgenPreprocess,$(strip $(TSTDIR))/database/msglog_db/custom_parse_db_tdd_fdd.c,$(MODISBUILD_TST_DB)/msglog_db/custom_parse_db.db,custom_parse_db_tdd_fdd.det,TRUE))
$(eval $(call CgenPreprocess,$(strip $(LOGGING_DATABASE))/msglog_db/swParseDbModem.c,$(MODISBUILD_TST_DB)/msglog_db/swParseDbModem.db,swParseDbModem.det,FALSE))
ifneq ($(strip $(C2K_RELEASE)),TRUE)
$(eval $(call CgenPreprocess,$(strip $(TSTDIR))/database/gv/gv_db.c,$(MODISBUILD_TST_DB)/gv/gv_db/gv_db.gv,gv_db.det,FALSE))
$(eval $(call CgenPreprocess,$(strip $(TSTDIR))/database/unionTag/unionTag_db_tdd_fdd.c,$(MODISBUILD_TST_DB)/unionTag/unionTag_parse.txt,unionTag_parse_tdd_fdd.det,TRUE))
$(eval $(call CgenPreprocess,$(strip $(TSTDIR))/database/unionTag/unionTag_db.c,$(MODISBUILD_TST_DB)/unionTag/unionTag_parse.txt,unionTag_parse.det,FALSE))
$(eval $(call CgenPreprocess,$(strip $(TSTDIR))/database/unionTag/ext/unionTag_db_tdd_fdd_ext.c,$(MODISBUILD_TST_DB)/unionTag/ext/unionTag_parse.txt,unionTag_parse_tdd_fdd_ext.det,TRUE))
$(eval $(call CgenPreprocess,$(strip $(TSTDIR))/database/unionTag/ext/unionTag_db_ext.c,$(MODISBUILD_TST_DB)/unionTag/ext/unionTag_parse.txt,unionTag_parse_ext.det,FALSE))
else
$(eval $(call CgenPreprocess,$(strip $(TSTDIR))/database/gv/gv_db.c,$(MODISBUILD_TST_DB)/gv/gv_db/gv_db.gv,gv_db.det,FALSE))
$(eval $(call CgenPreprocess,$(strip $(TSTDIR))/database/gv/ext/gv_db_ext.c,$(MODISBUILD_TST_DB)/gv/gv_db_ext/gv_db_ext.gv,gv_db_ext.det,FALSE))
$(eval $(call CgenPreprocess,$(strip $(TSTDIR))/database/unionTag/unionTag_db_tdd_fdd.c,$(MODISBUILD_TST_DB)/unionTag/unionTag_parse.txt,unionTag_parse_tdd_fdd.det,TRUE))
$(eval $(call CgenPreprocess,$(strip $(TSTDIR))/database/unionTag/unionTag_db.c,$(MODISBUILD_TST_DB)/unionTag/unionTag_parse.txt,unionTag_parse.det,FALSE))
$(eval $(call CgenPreprocess,$(strip $(TSTDIR))/database/unionTag/ext/unionTag_db_ext.c,$(MODISBUILD_TST_DB)/unionTag/ext/unionTag_parse.txt,unionTag_parse_ext.det,FALSE))
$(eval $(call CgenPreprocess,$(strip $(TSTDIR))/database/unionTag/ext/unionTag_db_tdd_fdd_ext.c,$(MODISBUILD_TST_DB)/unionTag/ext/unionTag_parse.txt,unionTag_parse_tdd_fdd_ext.det,TRUE))
endif
$(eval $(call CgenPreprocess,$(strip $(TSTDIR))/database/l1validation_db/l1v_db.c,$(MODISBUILD_TST_DB)/l1validation_db/l1v_db/l1v_db.l1v,l1v_db.det,FALSE))
# LTE SEC Cgen preprocess
ifeq ($(strip $(DHL_SUPPORT)),TRUE)
ifeq ($(MPD_SOURCE_FULL_BUILD),TRUE)
$(eval $(call CgenPreprocess,$(strip $(TSTDIR_SEC))/database/msglog_db/libParseDbModem.c,$(MODISBUILD_TST_DB_SEC)/msglog_db/libParseDbModem_sec.db,libParseDbModem_sec.det))
$(eval $(call CgenPreprocess,$(strip $(TSTDIR_SEC))/database/gv/gv_db.c,$(MODISBUILD_TST_DB_SEC)/gv/gv_db/gv_db_sec.gv,gv_db_sec.det))
$(eval $(call CgenPreprocess,$(strip $(TSTDIR_SEC))/database/unionTag/unionTag_db.c,$(MODISBUILD_TST_DB_SEC)/unionTag/unionTag_parse_sec.txt,unionTag_parse_sec.det))
$(eval $(call CgenPreprocess,$(strip $(TSTDIR_SEC))/database/l1validation_db/l1v_db.c,$(MODISBUILD_TST_DB_SEC)/l1validation_db/l1v_db/l1v_db_sec.l1v,l1v_db_sec.det))
endif
endif
#MPD 4g
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/cgen_ap_libParseDbModem_4g.det
# *************************************************************************
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_ap_libParseDbModem_4g.det: FORCE
endif
$(MODIS_RULESDIR)/codegen_dep/cgen_ap_libParseDbModem_4g.det: $(MODIS_RULESDIR)/codegen_dep/libParseDbModem_4g.det
$(MODIS_RULESDIR)/codegen_dep/cgen_ap_libParseDbModem_4g.det: $(strip $(TSTDIR))/database/$(CGEN_DEF_FILE) $(strip $(TSTDIR))/database/Pc_Cnf $(strip $(VERNOFILE)) $(strip $(PROJECT_MAKEFILE)) $(CGEN) $(NEED_CHECK_DEPEND_LIST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
@$(IF_EXIST) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(THEN) $(DEL_FILE) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(CMD_END)
@$(FOR) $(DECLARE_VAR)i $(IN) $(CODEGEN_DEPENDENCY_MODEM_4G) $(CODEGEN_DEPENDENCY_MODEM) $(DO) \
($(IF_EXIST) $(PRE_VAR)i $(THEN) $(DEL_FILE) $(PRE_VAR)i $(CMD_END)) \
$(DONE)
@$(IF_NOT_EXIST) $(MODISBUILD_TST_DB)/chk_cgen_step.ini $(THEN) $(ECHO) -n "$@" > $(MODISBUILD_TST_DB)/chk_cgen_step.ini $(CMD_END)
@$(ECHO) -n "Generate 4G Base Information ..."
@$(IF_EXIST) $(MODISBUILD_TST_DB_4G)/$(MDDBINFOCUSTOMPREFIX)* $(THEN) $(DEL_FILE) "$(MODISBUILD_TST_DB_4G)/*$(MDDBINFOCUSTOMPREFIX)*" $(CMD_END)
@$(IF_NOT_EXIST) $(BUILD_TSTDIR)/src $(THEN) $(MKDIR) $(BUILD_TSTDIR)/src $(CMD_END)
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
@$(ECHO) -n "$(CGEN) -ap11 $(CODEGEN_DATABASE_OUT_4G) $(CODEGEN_DATABASE_IN_SEC) $(MODISBUILD_TST_DB_4G)/msglog_db/libParseDbModem_4g.db $(MODISBUILD_TST_DB)/enumFile4G" >$(CGEN_CFG_MODEM_4G)
else
@$(ECHO) -n $(CGEN) -ap11 $(CODEGEN_DATABASE_OUT_4G) $(CODEGEN_DATABASE_IN_SEC) $(MODISBUILD_TST_DB_4G)/msglog_db/libParseDbModem_4g.db $(MODISBUILD_TST_DB)/enumFile4G >$(CGEN_CFG_MODEM_4G)
endif
@$(ECHO) -n "$@: $(strip $(TSTDIR))/database/$(CGEN_DEF_FILE) $(strip $(TSTDIR))/database/Pc_Cnf $(strip $(VERNOFILE)) $(strip $(PROJECT_MAKEFILE)) $(strip $(VERNOFILE))" >>$@
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/cgen_l1_4g.det
# *************************************************************************
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_l1_4g.det: FORCE
else
-include $(MODIS_RULESDIR)/codegen_dep/./cgen_l1_4g.det
endif
$(MODIS_RULESDIR)/codegen_dep/cgen_l1_4g.det: $(NEED_CHECK_DEPEND_LIST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
@$(IF_NOT_EXIST) $(BUILD_TSTDIR)/include $(THEN) $(MKDIR) $(BUILD_TSTDIR)/include $(CMD_END)
@$(IF_NOT_EXIST) $(BUILD_TSTDIR)/src $(THEN) $(MKDIR) $(BUILD_TSTDIR)/src $(CMD_END)
@$(IF_NOT_EXIST) $(CGEN_L1_OUTDIR) $(THEN) $(MKDIR) $(CGEN_L1_OUTDIR) $(CMD_END)
#backup dhl/include/*.h
@$(IF_NOT_EXIST) $(BUILD_TSTDIR)/include_bak $(THEN) \
($(MKDIR) $(BUILD_TSTDIR)/include_bak) \
$(ELSE) \
($(LIST_DIR) "$(BUILD_TSTDIR)/include_bak/*.*" 1>$(DEV_NUL) 2>&1 $(WITH) \
$(IF_ERR_FALSE) $(THEN) $(DEL_FILE) $(BUILD_TSTDIR)/include_bak/*.* $(CMD_END)) \
$(CMD_END)
@($(LIST_DIR) "$(BUILD_TSTDIR)/include/*.h" 1>$(DEV_NUL) 2>&1 $(WITH) \
$(IF_ERR_FALSE) $(THEN) $(COPY_FILE) $(BUILD_TSTDIR)/include/*.h $(BUILD_TSTDIR)/include_bak/ >$(DEV_NUL) $(CMD_END))
#backup dhl/src
@$(IF_NOT_EXIST) $(BUILD_TSTDIR)/src_bak $(THEN) \
($(MKDIR) $(BUILD_TSTDIR)/src_bak) \
$(ELSE) \
($(LIST_DIR) "$(BUILD_TSTDIR)/src_bak/*.*" 1>$(DEV_NUL) 2>&1 $(WITH)\
$(IF_ERR_FALSE) $(THEN) $(DEL_FILE) $(BUILD_TSTDIR)/src_bak/*.* $(CMD_END)) \
$(CMD_END)
@($(LIST_DIR) "$(BUILD_TSTDIR)/src/*.*" 1>$(DEV_NUL) 2>&1 $(WITH)\
$(IF_ERR_FALSE) $(THEN) $(COPY_FILE) $(BUILD_TSTDIR)/src/*.* $(BUILD_TSTDIR)/src_bak/ >$(DEV_NUL) $(CMD_END))
#backup l1trace
@$(IF_NOT_EXIST) $(strip $(PROJ_INTERNAL_DIR))/l1trace_bak $(THEN) \
($(MKDIR) $(strip $(PROJ_INTERNAL_DIR))/l1trace_bak) \
$(ELSE) \
($(LIST_DIR) "$(strip $(PROJ_INTERNAL_DIR))/l1trace_bak/*.*" 1>$(DEV_NUL) 2>&1 $(WITH)\
$(IF_ERR_FALSE) $(THEN) $(DEL_FILE) $(strip $(PROJ_INTERNAL_DIR))/l1trace_bak/*.* $(CMD_END)) \
$(CMD_END)
@($(LIST_DIR) "$(strip $(PROJ_INTERNAL_DIR))/l1trace/*.*" 1>$(DEV_NUL) 2>&1 $(WITH)\
$(IF_ERR_FALSE) $(THEN) $(COPY_FILE) $(strip $(PROJ_INTERNAL_DIR))/l1trace/*.* $(strip $(PROJ_INTERNAL_DIR))/l1trace_bak/ >$(DEV_NUL) $(CMD_END))
@$(IF_EXIST) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(THEN) $(DEL_FILE) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(CMD_END)
ifeq ($(strip $(CUSTOM_RELEASE)),FALSE)
@$(ECHO) -n "Generate 4G L1 Trace Information ..."
ifeq ($(strip $(RUN_CGEN_L1)),TRUE)
ifneq ($(strip $(UTMD_FILES_4G)),)
@$(IF_EXIST) $(MODISBUILD_TST_DB)/chk_cgen_step.ini $(THEN) \
($(ECHO) -n "$(CGEN) -uL1 $(CODEGEN_DATABASE_OUT_4G) $(CODEGEN_DATABASE_IN_4G) L1_CATCHER $(BUILD_TSTDIR)/src/TrcMod.c $(BUILD_TSTDIR)/include/TrcMod.h $(UTMD_FILES_4G) -OutputCPath-$(CGEN_L1_OUTDIR)/" >>$(CGEN_CFG_MODEM_4G)) \
$(ELSE) \
($(ECHO) -n "$(CGEN) -rL1 $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) L1_CATCHER $(BUILD_TSTDIR)/src/TrcMod.c $(BUILD_TSTDIR)/include/TrcMod.h $(UTMD_FILES_4G) -OutputCPath-$(CGEN_L1_OUTDIR)/" >>$(CGEN_CFG_MODEM_4G)) \
$(CMD_END)
@$(STRCMPEX) abc abc e $@ $@: $(filter-out CuStOm_StArT_% CuStOm_EnD_%,$(strip $(UTMD_FILES_4G)))
@$(FOR) $(DECLARE_VAR)i $(IN) $(foreach utmd_file,$(filter-out CuStOm_StArT_% CuStOm_EnD_%,$(strip $(UTMD_FILES_4G))), $(CGEN_L1_OUTDIR)/$(notdir $(basename $(utmd_file))).c $(BUILD_TSTDIR)/include/$(notdir $(basename $(utmd_file))).h) $(DO) (echo $(PRE_VAR)i >>$(CODE_GEN_LST)) $(DONE)
endif
else
ifeq ($(strip $(OS_VERSION)),MSWin32)
@for %%i in ($(subst /,\,$(BUILD_TSTDIR)/include/TrcMod.h) $(foreach utmd_file,$(filter-out CuStOm_StArT_% CuStOm_EnD_%,$(strip $(UTMD_FILES_4G))),$(subst /,\,$(BUILD_TSTDIR)/include/$(notdir $(basename $(utmd_file)).h)))) do (if not exist %%i copy /y NUL %%i >NUL)
else
@touch -a $(BUILD_TSTDIR)/include/TrcMod.h $(foreach utmd_file,$(filter-out CuStOm_StArT_% CuStOm_EnD_%,$(strip $(UTMD_FILES_4G))),$(BUILD_TSTDIR)/include/$(notdir $(basename $(utmd_file)).h))
endif
endif
endif
@$(ECHO) -n "$@:" >> $@
@$(ECHO) -n "$@" >> $(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/cgen_gv_4g.det
# *************************************************************************
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_gv_4g.det: FORCE
endif
$(MODIS_RULESDIR)/codegen_dep/cgen_gv_4g.det: $(MODIS_RULESDIR)/codegen_dep/cgen_gv_4g.det $(GV_FILES_4G) $(NEED_CHECK_DEPEND_LIST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
@$(IF_EXIST) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(THEN) $(DEL_FILE) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(CMD_END)
@$(ECHO) -n "Generate 4G Global variable Information ..."
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
@$(ECHO) -n "$(CGEN) -gv $(CODEGEN_DATABASE_OUT_4G) $(CODEGEN_DATABASE_IN_4G) $(MODISBUILD_TST_DB_4G)/gv/gv_db/ $(BUILD_TSTDIR)/src/gvTbl.c" >>$(CGEN_CFG_MODEM_4G)
@$(ECHO) -n "$(BUILD_TSTDIR)/src/gvTbl.c" >>$(CODE_GEN_LST)
else
@$(ECHO) -n $(CGEN) -gv $(CODEGEN_DATABASE_OUT_4G) $(CODEGEN_DATABASE_IN_4G) $(MODISBUILD_TST_DB_SEC)/gv/gv_db/ $(BUILD_TSTDIR)/src/gvTbl_modis.c >>$(CGEN_CFG_MODEM_4G)
@$(ECHO) -n $(BUILD_TSTDIR)/src/gvTbl_modis.c >>$(CODE_GEN_LST)
endif
@$(STRCMPEX) abc abc e $(basename $@).d $@: $(GV_FILES_4G)
@perl ./tools/pack_dep_gen.pl $@ $@ $(patsubst %/,%,$(dir $@)) "$(basename $(notdir $@))\.d"
@$(IF_EXIST) $(basename $@).d $(THEN) $(DEL_FILE) $(basename $@).d $(CMD_END)
@$(ECHO) -n "$@" >> $(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/cgen_l1v_4g.det
# *************************************************************************
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_l1v_4g.det: FORCE
endif
$(MODIS_RULESDIR)/codegen_dep/cgen_l1v_4g.det: $(MODIS_RULESDIR)/codegen_dep/l1v_db_4g.det $(CGEN) $(NEED_CHECK_DEPEND_LIST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
@$(IF_EXIST) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(THEN) $(DEL_FILE) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(CMD_END)
@$(IF_NOT_EXIST) $(MODISBUILD_TST_DB_4G)/l1validation_db/l1v_db/4G $(THEN) $(MKDIR) $(MODISBUILD_TST_DB_4G)/l1validation_db/l1v_db/4G $(CMD_END)
@$(ECHO) -n "Generate 4G L1 Validation Information ..."
@$(ECHO) -n "$(CGEN) -L1V $(CODEGEN_DATABASE_OUT_4G) $(CODEGEN_DATABASE_IN_4G) $(MODISBUILD_TST_DB_4G)/l1validation_db/l1v_db/4G" >>$(CGEN_CFG_MODEM_4G)
# too much *.l1v files, command length will be over 32KB
@$(FOR) $(F_OPT) $(DECLARE_VAR)i $(IN) `$(RECURSIVE_DIR) $(strip $(TST_DB_SEC))/l1validation_db "\.l1v"` $(DO) (echo $@: $(PRE_VAR)i >> $(basename $@).d) $(DONE)
@perl ./tools/pack_dep_gen.pl $@ $@ $(patsubst %/,%,$(dir $@)) "$(basename $(notdir $@))\.d"
@$(IF_EXIST) $(basename $@).d $(THEN) $(DEL_FILE) $(basename $@).d $(CMD_END)
@$(ECHO) -n "$@" >>$(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/cgen_ps_Modem_4g.det
# *************************************************************************
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_ps_Modem_4g.det: FORCE
endif
$(MODIS_RULESDIR)/codegen_dep/cgen_ps_Modem_4g.det: $(MODIS_RULESDIR)/codegen_dep/codegen_single_Modem_4g.det
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
@$(IF_EXIST) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(THEN) $(DEL_FILE) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(CMD_END)
@$(ECHO) -n "Generate 4G PS Trace Information ..."
#backup xxx_trc_gen.h
@$(IF_NOT_EXIST) $(MODISBUILD_TST_DB_4G)/pstrace_db_bak $(THEN) \
($(MKDIR) $(MODISBUILD_TST_DB_4G)/pstrace_db_bak) \
$(ELSE) \
($(LIST_DIR) "$(MODISBUILD_TST_DB_4G)/pstrace_db_bak/*.*" 1>$(DEV_NUL) 2>&1 $(WITH)\
$(IF_ERR_FALSE) $(THEN) $(DEL_FILE) $(MODISBUILD_TST_DB_4G)/pstrace_db_bak/*.* $(CMD_END))\
$(CMD_END)
@($(LIST_DIR) "$(MODISBUILD_TST_DB_4G)/pstrace_db/*.h" 1>$(DEV_NUL) 2>&1 $(WITH) \
$(IF_ERR_FALSE) $(THEN) $(COPY_FILE) $(MODISBUILD_TST_DB_4G)/pstrace_db/*.h $(MODISBUILD_TST_DB_4G)/pstrace_db_bak/ >$(DEV_NUL) $(CMD_END))
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
@$(IF_EXIST) $(MODISBUILD_TST_DB_4G)/pstrace_db/codegen_single_Modem_4g.ini $(THEN) \
($(IF_EXIST) $(MODISBUILD_TST_DB)/chk_cgen_step.ini $(THEN) \
($(ECHO) -n "$(CGEN) -ps $(CODEGEN_DATABASE_OUT_4G) $(CODEGEN_DATABASE_IN_4G) $(MODISBUILD_TST_DB_4G)/pstrace_db/codegen_single_Modem_4g.ini $(MODISBUILD_TST_DB)/pstrace_db/ps_trace_1.h" >>$(CGEN_CFG_MODEM_4G)) \
$(ELSE) \
($(ECHO) -n "$(CGEN) -rps $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB_4G)/pstrace_db/codegen_single_Modem_4g.ini $(MODISBUILD_TST_DB)/pstrace_db/ps_trace_1.h" >>$(CGEN_CFG_MODEM_4G)) $(AND)\
($(ECHO) -n "$(CGEN) -rle $(MODISBUILD_TST_DB)/pstrace_db/ps_trace_2.h $(MODISBUILD_TST_DB)/pstrace_db/ps_trace_1.h" >>$(CGEN_CFG_MODEM_4G)) $(AND)\
($(ECHO) -n "$(CGEN) -sps $(MODISBUILD_TST_DB)/pstrace_db/ps_trace.h $(MODISBUILD_TST_DB)/pstrace_db/ps_trace_2.h -posfixName-" >>$(CGEN_CFG_MODEM_4G)) \
$(CMD_END)) \
$(CMD_END)
else
@$(IF_EXIST) $(MODISBUILD_TST_DB_4G)/pstrace_db/codegen_single_Modem_4g.ini $(THEN) \
($(ECHO) -n $(CGEN) -ps $(CODEGEN_DATABASE_OUT_4G) $(CODEGEN_DATABASE_IN_4G) $(MODISBUILD_TST_DB_4G)/pstrace_db/codegen_single_Modem_4g.ini $(MODISBUILD_TST_DB)/pstrace_db/ps_trace_1.h >>$(CGEN_CFG_MODEM_4G)) \
$(CMD_END)
endif
@$(ECHO) -n "$@:" >> $@
@$(ECHO) -n "$@" >> $(CODE_GEN_LST)
@$(ECHO) -n "$(MODISBUILD_TST_DB)/pstrace_db/ps_trace.h" >>$(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/codegen_single_Modem_4g.det: FORCE
# *************************************************************************
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/codegen_single_Modem_4g.det: FORCE
else
-include $(MODIS_RULESDIR)/codegen_dep/./codegen_single_Modem_4g.det
endif
$(MODIS_RULESDIR)/codegen_dep/codegen_single_Modem_4g.det: $(NEED_CHECK_DEPEND_LIST) $(COMP_TRACE_DEFS_MODEM_4G)
ifeq ($(filter $(MAKECMDGOALS),cgen_preprocess),)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
endif
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
@$(IF_NOT_EXIST) $(MODISBUILD_TST_DB_4G)/pstrace_db $(THEN) $(MKDIR) $(MODISBUILD_TST_DB_4G)/pstrace_db $(CMD_END)
@$(ECHO) -n "Write ps *.json to $(MODISBUILD_TST_DB_4G)/pstrace_db/codegen_single_Modem_4g.ini"
@$(STRCMPEX) def def e $(MODISBUILD_TST_DB_4G)/pstrace_db/codegen_single_Modem_4g.ini $(COMP_TRACE_DEFS_MODEM_4G)
@perl ./tools/lnitem.pl $(MODISBUILD_TST_DB_4G)/pstrace_db/codegen_single_Modem_4g.ini
ifeq ($(filter $(MAKECMDGOALS),cgen_preprocess),)
@$(ECHO) "$@: " >> $@
@$(FOR) $(DECLARE_VAR)i $(IN) $(filter-out $(NEED_CHECK_DEPEND_LIST) FORCE,$^) $(DO) \
($(ECHO) "$(PRE_VAR)i " >> $@) \
$(DONE)
@$(ECHO) -n "$@" >>$(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/cgen_un_4g.det
# *************************************************************************
ifeq ($(RUN_UMTS_GEN),TRUE)
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_un_4g.det: FORCE
endif
$(MODIS_RULESDIR)/codegen_dep/cgen_un_4g.det: $(MODIS_RULESDIR)/codegen_dep/unionTag_parse_4g.det $(NEED_CHECK_DEPEND_LIST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
@$(IF_EXIST) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(THEN) $(DEL_FILE) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(CMD_END)
@$(ECHO) -n "Generate 4G Union Information ..."
@$(ECHO) -n "$(CGEN) -un $(CODEGEN_DATABASE_OUT_4G) $(CODEGEN_DATABASE_IN_4G) $(MODISBUILD_TST_DB_4G)/unionTag/unionTag_parse_4g.txt" >>$(CGEN_CFG_MODEM_4G)
@$(ECHO) -n "$@:" >> $@
@$(ECHO) -n "$@" >> $(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/codegen_single_Modem.det: FORCE
# *************************************************************************
# MPD domain must able to access all trace files list in COMP_TRACE_DEFS_MODEM
# HQ SWRD / SUB domain can only access partial trace files list in COMP_TRACE_DEFS_MODEM
ifeq ($(strip $(CUSTOM_RELEASE)),FALSE)
ifneq ($(strip $(MTK_SW_DOMAIN)),TRUE)
COMP_TRACE_DEFS_MODEM_NEW := $(COMP_TRACE_DEFS_MODEM)
else
COMP_TRACE_DEFS_MODEM_NEW := $(wildcard $(COMP_TRACE_DEFS_MODEM))
endif
else
COMP_TRACE_DEFS_MODEM_NEW := $(wildcard $(COMP_TRACE_DEFS_MODEM))
endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/codegen_single_Modem.det: FORCE
# *************************************************************************
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/codegen_single_Modem.det: FORCE
else
-include $(MODIS_RULESDIR)/codegen_dep/./codegen_single_Modem.det
endif
$(MODIS_RULESDIR)/codegen_dep/codegen_single_Modem.det: $(NEED_CHECK_DEPEND_LIST) $(COMP_TRACE_DEFS_MODEM_NEW)
ifeq ($(filter $(MAKECMDGOALS),cgen_preprocess),)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
endif
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
@$(ECHO) -n "Write ps *.json to $(MODISBUILD_TST_DB)/pstrace_db/codegen_single_Modem.ini"
@$(STRCMPEX) def def e $(MODISBUILD_TST_DB)/pstrace_db/codegen_single_Modem.ini $(COMP_TRACE_DEFS_MODEM_NEW)
@perl ./tools/lnitem.pl $(MODISBUILD_TST_DB)/pstrace_db/codegen_single_Modem.ini
ifeq ($(filter $(MAKECMDGOALS),cgen_preprocess),)
@$(ECHO) "$@: " >> $@
@$(FOR) $(DECLARE_VAR)i $(IN) $(filter-out $(NEED_CHECK_DEPEND_LIST) FORCE,$^) $(DO) \
($(ECHO) "$(PRE_VAR)i " >> $@) \
$(DONE)
@$(ECHO) -n "$@" >> $(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/codegen_single_Modem_sec.det: FORCE
# *************************************************************************
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/codegen_single_Modem_sec.det: FORCE
else
-include $(MODIS_RULESDIR)/codegen_dep/./codegen_single_Modem_sec.det
endif
$(MODIS_RULESDIR)/codegen_dep/codegen_single_Modem_sec.det: $(NEED_CHECK_DEPEND_LIST) $(COMP_TRACE_DEFS_MODEM_LTE_SEC) $(COMP_TRACE_DEFS_MODEM_NR_SEC)
ifeq ($(filter $(MAKECMDGOALS),cgen_preprocess),)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
endif
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
@$(ECHO) -n "Write ps *.json to $(MODISBUILD_TST_DB_SEC)/pstrace_db/codegen_single_Modem_sec.ini"
@$(STRCMPEX) def def e $(MODISBUILD_TST_DB_SEC)/pstrace_db/codegen_single_Modem_sec.ini $(COMP_TRACE_DEFS_MODEM_LTE_SEC) $(COMP_TRACE_DEFS_MODEM_NR_SEC)
@perl ./tools/lnitem.pl $(MODISBUILD_TST_DB_SEC)/pstrace_db/codegen_single_Modem_sec.ini
ifeq ($(filter $(MAKECMDGOALS),cgen_preprocess),)
@$(ECHO) "$@: " >>$@
@$(FOR) $(DECLARE_VAR)i $(IN) $(filter-out $(NEED_CHECK_DEPEND_LIST) FORCE,$^) $(DO) \
($(ECHO) "$(PRE_VAR)i " >> $@) \
$(DONE)
@$(ECHO) -n "$@" >>$(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/cgen_c_sec.det: FORCE
# *************************************************************************
ifeq ($(strip $(CUSTOM_RELEASE)),FALSE)
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_c_sec.det: FORCE
endif
$(MODIS_RULESDIR)/codegen_dep/cgen_c_sec.det: $(MODIS_RULESDIR)/codegen_dep/libParseDbModem_sec.det
$(MODIS_RULESDIR)/codegen_dep/cgen_c_sec.det: $(strip $(TSTDIR))/database/$(CGEN_DEF_FILE) $(strip $(TSTDIR))/database/Pc_Cnf $(strip $(VERNOFILE)) $(strip $(PROJECT_MAKEFILE)) $(CGEN) $(NEED_CHECK_DEPEND_LIST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
@$(IF_EXIST) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(THEN) $(DEL_FILE) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(CMD_END)
@$(FOR) $(DECLARE_VAR)i $(IN) $(CODEGEN_DEPENDENCY_MODEM_SEC) $(CODEGEN_DEPENDENCY_MODEM_4G) $(CODEGEN_DEPENDENCY_MODEM) $(DO) \
($(IF_EXIST) $(PRE_VAR)i $(THEN) $(DEL_FILE) $(PRE_VAR)i $(CMD_END)) \
$(DONE)
@$(ECHO) -n "Generate sec Base Information ..."
@$(IF_EXIST) $(MODISBUILD_TST_DB_SEC)/$(MDDBINFOCUSTOMPREFIX)* $(THEN) $(DEL_FILE) "$(MODISBUILD_TST_DB_SEC)/*$(MDDBINFOCUSTOMPREFIX)*" $(CMD_END)
@$(IF_NOT_EXIST) $(BUILD_TSTDIR)/src $(THEN) $(MKDIR) $(BUILD_TSTDIR)/src $(CMD_END)
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
@$(ECHO) -n "$(CGEN) -c $(MODISBUILD_TST_DB_SEC)/msglog_db/libParseDbModem_sec.db $(strip $(TSTDIR))/database/$(CGEN_DEF_FILE) $(strip $(TSTDIR))/database/Pc_Cnf $(CODEGEN_DATABASE_OUT_SEC) $(MODISBUILD_TST_DB)/enumFile $(strip $(PLATFORM))_$(strip $(CHIP_VER)) $(strip $(MTK_INTERNAL_VERNO)) -qModSim-$(BUILD_TSTDIR)/src/tst_querysimid.c -sf-$(MODISBUILD_TST_DB)/sf.ini -prjName-$(strip $(FULL_PRJ_NAME)) -VERNO_HAL-$(strip $(VERNO_HAL))" >$(CGEN_CFG_MODEM_SEC)
@$(ECHO) -n "$(BUILD_TSTDIR)/src/tst_querysimid.c" >>$(CODE_GEN_LST)
else
@$(ECHO) -n $(CGEN) -c $(MODISBUILD_TST_DB_SEC)/msglog_db/libParseDbModem_sec.db $(strip $(TSTDIR))/database/$(CGEN_DEF_FILE) $(strip $(TSTDIR))/database/Pc_Cnf $(CODEGEN_DATABASE_OUT_SEC) $(MODISBUILD_TST_DB)/enumFile MoDIS $(strip $(VERNO)) -qModSim-$(BUILD_TSTDIR)/src/tst_querysimid_modis.c >>$(CGEN_CFG_MODEM_SEC)
@$(ECHO) -n $(BUILD_TSTDIR)/src/tst_querysimid_modis.c >>$(CODE_GEN_LST)
endif
@$(ECHO) -n "$@: $(strip $(TSTDIR))/database/$(CGEN_DEF_FILE) $(strip $(TSTDIR))/database/Pc_Cnf $(strip $(VERNOFILE)) $(strip $(PROJECT_MAKEFILE)) $(strip $(VERNOFILE))" >>$@
@$(ECHO) -n "$@" >>$(CODE_GEN_LST)
@$(ECHO) -n "$(MODISBUILD_TST_DB)/enumFile" >>$(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/cgen_ap_swParseDbModem.det: FORCE
# *************************************************************************
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_ap_swParseDbModem.det: FORCE
endif
$(MODIS_RULESDIR)/codegen_dep/cgen_ap_swParseDbModem.det: $(MODIS_RULESDIR)/codegen_dep/swParseDbModem.det
$(MODIS_RULESDIR)/codegen_dep/cgen_ap_swParseDbModem.det: $(strip $(VERNOFILE)) $(strip $(PROJECT_MAKEFILE)) $(CGEN) $(NEED_CHECK_DEPEND_LIST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_EXIST) $@ $(THEN) $(DEL_FILE) $@ $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
@$(IF_EXIST) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(THEN) $(DEL_FILE) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(CMD_END)
ifeq ($(strip $(MTK_SW_DOMAIN)),TRUE)
@$(FOR) $(DECLARE_VAR)i $(IN) $(CODEGEN_DEPENDENCY_MODEM) $(DO) \
($(IF_EXIST) $(PRE_VAR)i $(THEN) $(DEL_FILE) $(PRE_VAR)i $(CMD_END)) \
$(DONE)
@$(IF_NOT_EXIST) $(MODISBUILD_TST_DB)/chk_cgen_step.ini $(THEN) $(ECHO) -n "$@" > $(MODISBUILD_TST_DB)/chk_cgen_step.ini $(CMD_END)
endif
@$(ECHO) -n "Append sw Base Information ..."
@$(ECHO) -n "$(CGEN) -ap10 $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/swParseDbModem.db $(MODISBUILD_TST_DB)/enumFileSw" >>$(CGEN_CFG_MODEM)
@$(ECHO) -n "$@:" >> $@
@$(ECHO) -n "$@" >> $(CODE_GEN_LST)
@$(ECHO) -n "$(MODISBUILD_TST_DB)/enumFile" >>$(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/cgen_ap_libParseDbModem.det: FORCE
# *************************************************************************
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_ap_libParseDbModem.det: FORCE
endif
$(MODIS_RULESDIR)/codegen_dep/cgen_ap_libParseDbModem.det: $(MODIS_RULESDIR)/codegen_dep/libParseDbModem_tdd_fdd.det $(MODIS_RULESDIR)/codegen_dep/libParseDbModem.det
$(MODIS_RULESDIR)/codegen_dep/cgen_ap_libParseDbModem.det: $(strip $(TSTDIR))/database/$(CGEN_DEF_FILE) $(strip $(TSTDIR))/database/Pc_Cnf $(strip $(VERNOFILE)) $(strip $(PROJECT_MAKEFILE)) $(CGEN)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
@$(IF_EXIST) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(THEN) $(DEL_FILE) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(CMD_END)
@$(FOR) $(DECLARE_VAR)i $(IN) $(CODEGEN_DEPENDENCY_MODEM) $(DO) \
($(IF_EXIST) $(PRE_VAR)i $(THEN) $(DEL_FILE) $(PRE_VAR)i $(CMD_END)) \
$(DONE)
ifneq ($(MPD_SOURCE_4G_BUILD),TRUE)
@$(IF_NOT_EXIST) $(MODISBUILD_TST_DB)/chk_cgen_step.ini $(THEN) $(ECHO) -n "$@" > $(MODISBUILD_TST_DB)/chk_cgen_step.ini $(CMD_END)
endif
@$(ECHO) -n "Append common Base Information ..."
@$(ECHO) -n "$(CGEN) -ap8 $(CODEGEN_DATABASE_OUT) $(INPUT_4G_DB) $(MODISBUILD_TST_DB)/msglog_db/libParseDbModem.db $(MODISBUILD_TST_DB)/enumFile" >>$(CGEN_CFG_MODEM)
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
ifeq ($(strip $(UMTS_TDD_SUPPORT)),UMTS_TDD128_MODE_SUPPORT)
@$(ECHO) -n "$(CGEN) -ap5 $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/libParseDbModem_fdd.db $(MODISBUILD_TST_DB)/enumFile" >>$(CGEN_CFG_MODEM)
@$(ECHO) -n "$(CGEN) -ap6 $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/libParseDbModem_tdd.db $(MODISBUILD_TST_DB)/enumFile $(strip $(PLATFORM))_$(strip $(CHIP_VER)) $(strip $(VERNO)) -qModSim-$(BUILD_TSTDIR)/src/tst_querysimid.c" >>$(CGEN_CFG_MODEM)
else
@$(ECHO) -n "$(CGEN) -ap5 $(CODEGEN_DATABASE_OUT) $(INPUT_4G_DB) $(MODISBUILD_TST_DB)/msglog_db/libParseDbModem_fdd.db $(MODISBUILD_TST_DB)/enumFile $(strip $(PLATFORM))_$(strip $(CHIP_VER)) $(strip $(VERNO)) -qModSim-$(BUILD_TSTDIR)/src/tst_querysimid.c" >>$(CGEN_CFG_MODEM)
endif
else
ifeq ($(strip $(UMTS_TDD_SUPPORT)),UMTS_TDD128_MODE_SUPPORT)
@$(ECHO) -n $(CGEN) -ap5 $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/libParseDbModem_fdd.db $(MODISBUILD_TST_DB)/enumFile >>$(CGEN_CFG_MODEM)
@$(ECHO) -n $(CGEN) -ap6 $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/libParseDbModem_tdd.db $(MODISBUILD_TST_DB)/enumFile MoDIS $(strip $(VERNO)) -qModSim-$(BUILD_TSTDIR)/src/tst_querysimid_modis.c>>$(CGEN_CFG_MODEM)
else
@$(ECHO) -n $(CGEN) -ap5 $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/libParseDbModem_fdd.db $(MODISBUILD_TST_DB)/enumFile MoDIS $(strip $(VERNO)) -qModSim-$(BUILD_TSTDIR)/src/tst_querysimid_modis.c>>$(CGEN_CFG_MODEM)
endif
endif
@$(ECHO) -n "$@: $(strip $(TSTDIR))/database/$(CGEN_DEF_FILE) $(strip $(TSTDIR))/database/Pc_Cnf $(strip $(VERNOFILE)) $(strip $(PROJECT_MAKEFILE))" >$@
@$(ECHO) -n "$@" >>$(CODE_GEN_LST)
@$(ECHO) -n "$(MODISBUILD_TST_DB)/enumFile" >>$(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/cgen_ps_Modem.det: FORCE
# Step 3: Protocol trace information
# *************************************************************************
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_ps_Modem.det: FORCE
endif
$(MODIS_RULESDIR)/codegen_dep/cgen_ps_Modem.det: $(MODIS_RULESDIR)/codegen_dep/codegen_single_Modem.det
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
@$(IF_EXIST) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(THEN) $(DEL_FILE) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(CMD_END)
@$(ECHO) -n "Generate common PS Trace Information ..."
#backup xxx_trc_gen.h
@$(IF_NOT_EXIST) $(MODISBUILD_TST_DB)/pstrace_db_bak $(THEN) \
($(MKDIR) $(MODISBUILD_TST_DB)/pstrace_db_bak) \
$(ELSE) \
($(LIST_DIR) "$(MODISBUILD_TST_DB)/pstrace_db_bak/*.*" 1>$(DEV_NUL) 2>&1 $(WITH)\
$(IF_ERR_FALSE) $(THEN) $(DEL_FILE) $(MODISBUILD_TST_DB)/pstrace_db_bak/*.* $(CMD_END))\
$(CMD_END)
@($(LIST_DIR) "$(MODISBUILD_TST_DB)/pstrace_db/*.h" 1>$(DEV_NUL) 2>&1 $(WITH) \
$(IF_ERR_FALSE) $(THEN) $(COPY_FILE) $(MODISBUILD_TST_DB)/pstrace_db/*.h $(MODISBUILD_TST_DB)/pstrace_db_bak/ >$(DEV_NUL) $(CMD_END))
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
@$(IF_EXIST) $(MODISBUILD_TST_DB)/chk_cgen_step.ini $(THEN) \
($(ECHO) -n "$(CGEN) -ps $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_OUT) $(MODISBUILD_TST_DB)/pstrace_db/codegen_single_Modem.ini $(MODISBUILD_TST_DB)/pstrace_db/ps_trace_1.h" >>$(CGEN_CFG_MODEM)) \
$(ELSE) \
($(ECHO) -n "$(CGEN) -rps $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_OUT) $(MODISBUILD_TST_DB)/pstrace_db/codegen_single_Modem.ini $(MODISBUILD_TST_DB)/pstrace_db/ps_trace_1.h" >>$(CGEN_CFG_MODEM)) \
$(CMD_END)
@$(ECHO) -n "$(CGEN) -rle $(MODISBUILD_TST_DB)/pstrace_db/ps_trace_2.h $(MODISBUILD_TST_DB)/pstrace_db/ps_trace_1.h" >> $(CGEN_CFG_MODEM)
@$(ECHO) -n "$(CGEN) -sps $(MODISBUILD_TST_DB)/pstrace_db/ps_trace.h $(MODISBUILD_TST_DB)/pstrace_db/ps_trace_2.h -posfixName-" >> $(CGEN_CFG_MODEM)
else
@$(ECHO) -n $(CGEN) -ps $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/pstrace_db/codegen_single_Modem.ini $(MODISBUILD_TST_DB)/pstrace_db/ps_trace_1.h >> $(CGEN_CFG_MODEM)
@$(ECHO) -n $(CGEN) -sps $(MODISBUILD_TST_DB)/pstrace_db/ps_trace.h $(MODISBUILD_TST_DB)/pstrace_db/ps_trace_1.h -posfixName- >> $(CGEN_CFG_MODEM)
endif
@$(ECHO) -n "$@:" >> $@
@$(ECHO) -n "$@" >> $(CODE_GEN_LST)
@$(ECHO) -n "$(MODISBUILD_TST_DB)/pstrace_db/ps_trace.h" >>$(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/cgen_ps_Modem_sec.det: FORCE
# *************************************************************************
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_ps_Modem_sec.det: FORCE
endif
$(MODIS_RULESDIR)/codegen_dep/cgen_ps_Modem_sec.det: $(MODIS_RULESDIR)/codegen_dep/codegen_single_Modem_sec.det
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
@$(IF_EXIST) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(THEN) $(DEL_FILE) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(CMD_END)
@$(ECHO) -n "Generate sec PS Trace Information ..."
#backup xxx_trc_gen.h
@$(IF_NOT_EXIST) $(MODISBUILD_TST_DB)/pstrace_db_bak $(THEN) \
($(MKDIR) $(MODISBUILD_TST_DB)/pstrace_db_bak) \
$(ELSE) \
($(LIST_DIR) "$(MODISBUILD_TST_DB)/pstrace_db_bak/*.*" 1>$(DEV_NUL) 2>&1 $(WITH) \
$(IF_ERR_FALSE) $(THEN) $(DEL_FILE) $(MODISBUILD_TST_DB)/pstrace_db_bak/*.* $(CMD_END)) \
$(CMD_END)
@($(LIST_DIR) "$(MODISBUILD_TST_DB)/pstrace_db/*.h" 1>$(DEV_NUL) 2>&1 $(WITH) \
$(IF_ERR_FALSE) $(THEN) $(COPY_FILE) $(MODISBUILD_TST_DB)/pstrace_db/*.h $(MODISBUILD_TST_DB)/pstrace_db_bak/ >$(DEV_NUL) $(CMD_END))
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
@$(ECHO) -n "$(CGEN) -ps $(CODEGEN_DATABASE_OUT_SEC) $(CODEGEN_DATABASE_IN_SEC) $(MODISBUILD_TST_DB_SEC)/pstrace_db/codegen_single_Modem_sec.ini $(MODISBUILD_TST_DB)/pstrace_db/ps_trace_1.h" >> $(CGEN_CFG_MODEM_SEC)
else
@$(ECHO) -n $(CGEN) -ps $(CODEGEN_DATABASE_OUT_SEC) $(CODEGEN_DATABASE_IN_SEC) $(MODISBUILD_TST_DB_SEC)/pstrace_db/codegen_single_Modem_sec.ini $(MODISBUILD_TST_DB)/pstrace_db/ps_trace_1.h >> $(CGEN_CFG_MODEM_SEC)
endif
@$(ECHO) -n "$@:" >>$@
@$(ECHO) -n "$@" >>$(CODE_GEN_LST)
@$(ECHO) -n "$(MODISBUILD_TST_DB)/pstrace_db/ps_trace.h" >>$(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/cgen_l1.det: FORCE
# Step 4: Layer 1 trace information
# *************************************************************************
L1MODMSG_CHK = $(strip $(LOGGING_DATABASE))/l1validation_db/L1ModMsg.chk
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_l1.det: FORCE
else
-include $(MODIS_RULESDIR)/codegen_dep/./cgen_l1.det
endif
$(MODIS_RULESDIR)/codegen_dep/cgen_l1.det: $(NEED_CHECK_DEPEND_LIST)
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
@$(IF_NOT_EXIST) $(BUILD_TSTDIR)/include $(THEN) $(MKDIR) $(BUILD_TSTDIR)/include $(CMD_END)
@$(IF_NOT_EXIST) $(BUILD_TSTDIR)/src $(THEN) $(MKDIR) $(BUILD_TSTDIR)/src $(CMD_END)
@$(IF_NOT_EXIST) $(CGEN_L1_OUTDIR) $(THEN) $(MKDIR) $(CGEN_L1_OUTDIR) $(CMD_END)
#backup dhl/include/*.h
@$(IF_NOT_EXIST) $(BUILD_TSTDIR)/include_bak $(THEN) \
($(MKDIR) $(BUILD_TSTDIR)/include_bak) \
$(ELSE) \
($(LIST_DIR) "$(BUILD_TSTDIR)/include_bak/*.*" 1>$(DEV_NUL) 2>&1 $(WITH)\
$(IF_ERR_FALSE) $(THEN) $(DEL_FILE) $(BUILD_TSTDIR)/include_bak/*.* $(CMD_END)) \
$(CMD_END)
@($(LIST_DIR) "$(BUILD_TSTDIR)/include/*.h" 1>$(DEV_NUL) 2>&1 $(WITH)\
$(IF_ERR_FALSE) $(THEN) $(COPY_FILE) $(BUILD_TSTDIR)/include/*.h $(BUILD_TSTDIR)/include_bak/ >$(DEV_NUL) $(CMD_END))
#backup dhl/src
@$(IF_NOT_EXIST) $(BUILD_TSTDIR)/src_bak $(THEN) \
($(MKDIR) $(BUILD_TSTDIR)/src_bak) \
$(ELSE) \
($(LIST_DIR) "$(BUILD_TSTDIR)/src_bak/*.*" 1>$(DEV_NUL) 2>&1 $(WITH)\
$(IF_ERR_FALSE) $(THEN) $(DEL_FILE) $(BUILD_TSTDIR)/src_bak/*.* $(CMD_END)) \
$(CMD_END)
@($(LIST_DIR) "$(BUILD_TSTDIR)/src/*.*" 1>$(DEV_NUL) 2>&1 $(WITH)\
$(IF_ERR_FALSE) $(THEN) $(COPY_FILE) $(BUILD_TSTDIR)/src/*.* $(BUILD_TSTDIR)/src_bak/ >$(DEV_NUL) $(CMD_END))
#backup l1trace
@$(IF_NOT_EXIST) $(strip $(PROJ_INTERNAL_DIR))/l1trace_bak $(THEN) \
($(MKDIR) $(strip $(PROJ_INTERNAL_DIR))/l1trace_bak) \
$(ELSE) \
($(LIST_DIR) "$(strip $(PROJ_INTERNAL_DIR))/l1trace_bak/*.*" 1>$(DEV_NUL) 2>&1 $(WITH)\
$(IF_ERR_FALSE) $(THEN) $(DEL_FILE) $(strip $(PROJ_INTERNAL_DIR))/l1trace_bak/*.* $(CMD_END)) \
$(CMD_END)
@($(LIST_DIR) "$(strip $(PROJ_INTERNAL_DIR))/l1trace/*.*" 1>$(DEV_NUL) 2>&1 $(WITH)\
$(IF_ERR_FALSE) $(THEN) $(COPY_FILE) $(strip $(PROJ_INTERNAL_DIR))/l1trace/*.* $(strip $(PROJ_INTERNAL_DIR))/l1trace_bak/ >$(DEV_NUL) $(CMD_END))
@$(IF_EXIST) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(THEN) $(DEL_FILE) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(CMD_END)
ifeq ($(strip $(CUSTOM_RELEASE)),FALSE)
@$(ECHO) -n "Generate common L1 Trace Information ..."
ifeq ($(strip $(RUN_CGEN_L1)),TRUE)
ifeq ($(strip $(UTMD_FILES)),)
@$(IF_EXIST) $(MODISBUILD_TST_DB)/chk_cgen_step.ini $(THEN) \
($(ECHO) -n "$(CGEN) -uL1 $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) L1_CATCHER $(BUILD_TSTDIR)/src/TrcMod.c $(BUILD_TSTDIR)/include/TrcMod.h $(UTMD_FILES) -OutputCPath-$(CGEN_L1_OUTDIR)/" >>$(CGEN_CFG_MODEM)) \
$(ELSE) \
($(ECHO) -n "$(CGEN) -rL1 $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) L1_CATCHER $(BUILD_TSTDIR)/src/TrcMod.c $(BUILD_TSTDIR)/include/TrcMod.h $(UTMD_FILES) -OutputCPath-$(CGEN_L1_OUTDIR)/" >>$(CGEN_CFG_MODEM)) \
$(CMD_END)
@$(STRCMPEX) abc abc e $@ $@: $(filter-out CuStOm_StArT_% CuStOm_EnD_%,$(strip $(UTMD_FILES)))
else
@$(IF_EXIST) $(MODISBUILD_TST_DB)/chk_cgen_step.ini $(THEN) \
($(ECHO) "$(CGEN) -uL1 $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) L1_CATCHER $(BUILD_TSTDIR)/src/TrcMod.c $(BUILD_TSTDIR)/include/TrcMod.h $(strip $(L1MODMSG_CHK)) " >>$(CGEN_CFG_MODEM)) \
$(ELSE) \
($(ECHO) "$(CGEN) -rL1 $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) L1_CATCHER $(BUILD_TSTDIR)/src/TrcMod.c $(BUILD_TSTDIR)/include/TrcMod.h $(strip $(L1MODMSG_CHK)) " >>$(CGEN_CFG_MODEM)) \
$(CMD_END)
@$(FOR) $(DECLARE_VAR)i $(IN) $(UTMD_FILES) $(DO) \
($(ECHO) "$(PRE_VAR)i " >> $(CGEN_CFG_MODEM)) \
$(DONE)
@$(ECHO) -n "-OutputCPath-$(CGEN_L1_OUTDIR)/" >>$(CGEN_CFG_MODEM)
@$(STRCMPEX) abc abc e $@ $@: $(strip $(L1MODMSG_CHK)) $(filter-out CuStOm_StArT_% CuStOm_EnD_%,$(strip $(UTMD_FILES)))
@$(FOR) $(DECLARE_VAR)i $(IN) $(foreach utmd_file,$(filter-out CuStOm_StArT_% CuStOm_EnD_%,$(strip $(UTMD_FILES))), $(CGEN_L1_OUTDIR)/$(notdir $(basename $(utmd_file))).c) $(DO) (echo $(PRE_VAR)i >>$(CODE_GEN_LST)) $(DONE)
@$(FOR) $(DECLARE_VAR)i $(IN) $(foreach utmd_file,$(filter-out CuStOm_StArT_% CuStOm_EnD_%,$(strip $(UTMD_FILES))), $(BUILD_TSTDIR)/include/$(notdir $(basename $(utmd_file))).h) $(DO) (echo $(PRE_VAR)i >>$(CODE_GEN_LST)) $(DONE)
endif
@$(ECHO) -n "$(BUILD_TSTDIR)/src/TrcMod.c" >>$(CODE_GEN_LST)
@$(ECHO) -n "$(BUILD_TSTDIR)/include/TrcMod.h" >>$(CODE_GEN_LST)
else
# workaround for -puremodis, because some L1 headers are always included
ifeq ($(strip $(OS_VERSION)),MSWin32)
@for %%i in ($(subst /,\,$(BUILD_TSTDIR)/include/TrcMod.h) $(foreach utmd_file,$(filter-out CuStOm_StArT_% CuStOm_EnD_%,$(strip $(UTMD_FILES))),$(subst /,\,$(BUILD_TSTDIR)/include/$(notdir $(basename $(utmd_file)).h)))) do (if not exist %%i copy /y NUL %%i >NUL)
else
@touch -a $(BUILD_TSTDIR)/include/TrcMod.h $(foreach utmd_file,$(filter-out CuStOm_StArT_% CuStOm_EnD_%,$(strip $(UTMD_FILES))),$(BUILD_TSTDIR)/include/$(notdir $(basename $(utmd_file)).h))
endif
endif
else
ifneq ($(strip $(UTMD_FILES)),)
@$(IF_EXIST) $(MODISBUILD_TST_DB)/chk_cgen_step.ini $(THEN) \
($(ECHO) "$(CGEN) -uL1 $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) L1_CATCHER $(BUILD_TSTDIR)/src/TrcMod.c $(BUILD_TSTDIR)/include/TrcMod.h $(strip $(L1MODMSG_CHK)) " >>$(CGEN_CFG_MODEM)) \
$(ELSE) \
($(ECHO) "$(CGEN) -rL1 $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) L1_CATCHER $(BUILD_TSTDIR)/src/TrcMod.c $(BUILD_TSTDIR)/include/TrcMod.h $(strip $(L1MODMSG_CHK)) " >>$(CGEN_CFG_MODEM)) \
$(CMD_END)
@$(FOR) $(DECLARE_VAR)i $(IN) $(UTMD_FILES) $(DO) \
($(ECHO) "$(PRE_VAR)i " >> $(CGEN_CFG_MODEM)) \
$(DONE)
@$(ECHO) -n "-OutputCPath-$(CGEN_L1_OUTDIR)/" >>$(CGEN_CFG_MODEM)
endif
endif
@$(ECHO) -n "$@:" >>$@
@$(ECHO) -n "$@" >>$(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/cgen_l1_sec.det: FORCE
# *************************************************************************
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_l1_sec.det: FORCE
else
-include $(MODIS_RULESDIR)/codegen_dep/./cgen_l1_sec.det
endif
$(MODIS_RULESDIR)/codegen_dep/cgen_l1_sec.det: $(NEED_CHECK_DEPEND_LIST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
@$(IF_NOT_EXIST) $(BUILD_TSTDIR)/include $(THEN) $(MKDIR) $(BUILD_TSTDIR)/include $(CMD_END)
@$(IF_NOT_EXIST) $(BUILD_TSTDIR)/src $(THEN) $(MKDIR) $(BUILD_TSTDIR)/src $(CMD_END)
@$(IF_NOT_EXIST) $(CGEN_L1_OUTDIR) $(THEN) $(MKDIR) $(CGEN_L1_OUTDIR) $(CMD_END)
#backup dhl/include/*.h
@$(IF_NOT_EXIST) $(BUILD_TSTDIR)/include_bak $(THEN) \
($(MKDIR) $(BUILD_TSTDIR)/include_bak) \
$(ELSE) \
($(LIST_DIR) "$(BUILD_TSTDIR)/include_bak/*.*" 1>$(DEV_NUL) 2>&1 $(WITH)\
$(IF_ERR_FALSE) $(THEN) $(DEL_FILE) $(BUILD_TSTDIR)/include_bak/*.* $(CMD_END)) \
$(CMD_END)
@($(LIST_DIR) "$(BUILD_TSTDIR)/include/*.h" 1>$(DEV_NUL) 2>&1 $(WITH)\
$(IF_ERR_FALSE) $(THEN) $(COPY_FILE) $(BUILD_TSTDIR)/include/*.h $(BUILD_TSTDIR)/include_bak/ >$(DEV_NUL) $(CMD_END))
#backup dhl/src
@$(IF_NOT_EXIST) $(BUILD_TSTDIR)/src_bak $(THEN) \
($(MKDIR) $(BUILD_TSTDIR)/src_bak) \
$(ELSE) \
($(LIST_DIR) "$(BUILD_TSTDIR)/src_bak/*.*" 1>$(DEV_NUL) 2>&1 $(WITH)\
$(IF_ERR_FALSE) $(THEN) $(DEL_FILE) $(BUILD_TSTDIR)/src_bak/*.* $(CMD_END)) \
$(CMD_END)
@($(LIST_DIR) "$(BUILD_TSTDIR)/src/*.*" 1>$(DEV_NUL) 2>&1 $(WITH)\
$(IF_ERR_FALSE) $(THEN) $(COPY_FILE) $(BUILD_TSTDIR)/src/*.* $(BUILD_TSTDIR)/src_bak/ >$(DEV_NUL) $(CMD_END))
#backup l1trace
@$(IF_NOT_EXIST) $(strip $(PROJ_INTERNAL_DIR))/l1trace_bak $(THEN) \
($(MKDIR) $(strip $(PROJ_INTERNAL_DIR))/l1trace_bak) \
$(ELSE) \
($(LIST_DIR) "$(strip $(PROJ_INTERNAL_DIR))/l1trace_bak/*.*" 1>$(DEV_NUL) 2>&1 $(WITH)\
$(IF_ERR_FALSE) $(THEN) $(DEL_FILE) $(strip $(PROJ_INTERNAL_DIR))/l1trace_bak/*.* $(CMD_END)) \
$(CMD_END)
@($(LIST_DIR) "$(strip $(PROJ_INTERNAL_DIR))/l1trace/*.*" 1>$(DEV_NUL) 2>&1 $(WITH)\
$(IF_ERR_FALSE) $(THEN) $(COPY_FILE) $(strip $(PROJ_INTERNAL_DIR))/l1trace/*.* $(strip $(PROJ_INTERNAL_DIR))/l1trace_bak/ >$(DEV_NUL) $(CMD_END))
@$(IF_EXIST) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(THEN) $(DEL_FILE) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(CMD_END)
ifeq ($(strip $(CUSTOM_RELEASE)),FALSE)
@$(ECHO) -n "Generate sec L1 Trace Information ..."
ifeq ($(strip $(RUN_CGEN_L1)),TRUE)
ifeq ($(strip $(UTMD_FILES_SEC)),)
@$(ECHO) -n "$(CGEN) -uL1 $(CODEGEN_DATABASE_OUT_SEC) $(CODEGEN_DATABASE_IN_SEC) L1_CATCHER $(BUILD_TSTDIR)/src/TrcMod.c $(BUILD_TSTDIR)/include/TrcMod.h $(DHL_L1_UTMD_FILE) $(UTMD_FILES_SEC) -OutputCPath-$(CGEN_L1_OUTDIR)/" >>$(CGEN_CFG_MODEM_SEC)
@$(STRCMPEX) abc abc e $@ $@: $(filter-out CuStOm_StArT_% CuStOm_EnD_%,$(strip $(UTMD_FILES_SEC)))
else
@$(ECHO) -n "$(CGEN) -uL1 $(CODEGEN_DATABASE_OUT_SEC) $(CODEGEN_DATABASE_IN_SEC) L1_CATCHER $(BUILD_TSTDIR)/src/TrcMod.c $(BUILD_TSTDIR)/include/TrcMod.h $(strip $(TSTDIR_SEC))/database/l1validation_db/L1ModMsg.chk $(DHL_L1_UTMD_FILE) $(UTMD_FILES_SEC) -OutputCPath-$(CGEN_L1_OUTDIR)/" >>$(CGEN_CFG_MODEM_SEC)
@$(STRCMPEX) abc abc e $@ $@: $(strip $(TSTDIR_SEC))/database/l1validation_db/L1ModMsg.chk $(filter-out CuStOm_StArT_% CuStOm_EnD_%,$(strip $(UTMD_FILES_SEC)))
@$(FOR) $(DECLARE_VAR)i $(IN) $(foreach utmd_file,$(filter-out CuStOm_StArT_% CuStOm_EnD_%,$(strip $(UTMD_FILES_SEC))), $(CGEN_L1_OUTDIR)/$(notdir $(basename $(utmd_file))).c $(BUILD_TSTDIR)/include/$(notdir $(basename $(utmd_file))).h) $(DO) (echo $(PRE_VAR)i >>$(CODE_GEN_LST)) $(DONE)
endif
@$(ECHO) -n "$(BUILD_TSTDIR)/src/TrcMod.c" >>$(CODE_GEN_LST)
@$(ECHO) -n "$(BUILD_TSTDIR)/include/TrcMod.h" >>$(CODE_GEN_LST)
else
# workaround for -puremodis, because some L1 headers are always included
ifeq ($(strip $(OS_VERSION)),MSWin32)
@for %%i in ($(subst /,\,$(BUILD_TSTDIR)/include/TrcMod.h) $(foreach utmd_file,$(filter-out CuStOm_StArT_% CuStOm_EnD_%,$(strip $(UTMD_FILES_SEC))),$(subst /,\,$(BUILD_TSTDIR)/include/$(notdir $(basename $(utmd_file)).h)))) do (if not exist %%i copy /y NUL %%i >NUL)
else
@touch -a $(BUILD_TSTDIR)/include/TrcMod.h $(foreach utmd_file,$(filter-out CuStOm_StArT_% CuStOm_EnD_%,$(strip $(UTMD_FILES_SEC))),$(BUILD_TSTDIR)/include/$(notdir $(basename $(utmd_file)).h))
endif
endif
endif
@$(ECHO) -n "$@:" >>$@
@$(ECHO) -n "$@" >>$(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/cgen_gv.det: FORCE
# Step 5: Result temporary - Global variable information
# *************************************************************************
#ifeq ($(strip $(CUSTOM_RELEASE)),FALSE)
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_gv.det: FORCE
endif
ifneq ($(strip $(C2K_RELEASE)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_gv.det: $(MODIS_RULESDIR)/codegen_dep/gv_db.det $(GV_FILES)
else
$(MODIS_RULESDIR)/codegen_dep/cgen_gv.det: $(MODIS_RULESDIR)/codegen_dep/gv_db_ext.det $(GV_FILES_C2K)
endif
$(MODIS_RULESDIR)/codegen_dep/cgen_gv.det: $(NEED_CHECK_DEPEND_LIST)
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
@$(IF_EXIST) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(THEN) $(DEL_FILE) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(CMD_END)
@$(ECHO) -n "Generate common Global variable Information ..."
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
ifneq ($(strip $(C2K_RELEASE)),TRUE)
@$(ECHO) -n "$(CGEN) -gv $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/gv/gv_db/ $(BUILD_TSTDIR)/src/gvTbl.c" >> $(CGEN_CFG_MODEM)
else
@$(ECHO) -n "$(CGEN) -gv $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/gv/gv_db_ext/ $(BUILD_TSTDIR)/src/gvTbl.c" >> $(CGEN_CFG_MODEM)
endif
@$(ECHO) -n "$(BUILD_TSTDIR)/src/gvTbl.c" >>$(CODE_GEN_LST)
else
ifneq ($(strip $(C2K_RELEASE)),TRUE)
@$(ECHO) -n $(CGEN) -gv $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/gv/gv_db/ $(BUILD_TSTDIR)/src/gvTbl_modis.c >> $(CGEN_CFG_MODEM)
else
@$(ECHO) -n $(CGEN) -gv $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/gv/gv_db_ext/ $(BUILD_TSTDIR)/src/gvTbl_modis.c >> $(CGEN_CFG_MODEM)
endif
@$(ECHO) -n $(BUILD_TSTDIR)/src/gvTbl_modis.c >>$(CODE_GEN_LST)
endif
ifneq ($(strip $(C2K_RELEASE)),TRUE)
@$(STRCMPEX) abc abc e $(basename $@).d $@: $(GV_FILES)
else
@$(STRCMPEX) abc abc e $(basename $@).d $@: $(GV_FILES_C2K)
endif
@perl ./tools/pack_dep_gen.pl $@ $@ $(patsubst %/,%,$(dir $@)) "$(basename $(notdir $@))\.d"
@$(IF_EXIST) $(basename $@).d $(THEN) $(DEL_FILE) $(basename $@).d $(CMD_END)
@$(ECHO) -n "$@" >> $(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
#endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/cgen_gv_sec.det: FORCE
# *************************************************************************
ifeq ($(strip $(CUSTOM_RELEASE)),FALSE)
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_gv_sec.det: FORCE
endif
$(MODIS_RULESDIR)/codegen_dep/cgen_gv_sec.det: $(MODIS_RULESDIR)/codegen_dep/gv_db_sec.det $(GV_FILES_SEC) $(NEED_CHECK_DEPEND_LIST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
@$(IF_EXIST) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(THEN) $(DEL_FILE) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(CMD_END)
@$(ECHO) -n "Generate sec Global variable Information ..."
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
@$(ECHO) -n "$(CGEN) -gv $(CODEGEN_DATABASE_OUT_SEC) $(CODEGEN_DATABASE_IN_SEC) $(MODISBUILD_TST_DB_SEC)/gv/gv_db/ $(BUILD_TSTDIR)/src/gvTbl.c" >> $(CGEN_CFG_MODEM_SEC)
@$(ECHO) -n "$(BUILD_TSTDIR)/src/gvTbl.c" >>$(CODE_GEN_LST)
else
@$(ECHO) -n $(CGEN) -gv $(CODEGEN_DATABASE_OUT_SEC) $(CODEGEN_DATABASE_IN_SEC) $(MODISBUILD_TST_DB_SEC)/gv/gv_db/ $(BUILD_TSTDIR)/src/gvTbl_modis.c >> $(CGEN_CFG_MODEM_SEC)
@$(ECHO) -n $(BUILD_TSTDIR)/src/gvTbl_modis.c >>$(CODE_GEN_LST)
endif
@$(STRCMPEX) abc abc e $(basename $@).d $@: $(GV_FILES_SEC)
@perl ./tools/pack_dep_gen.pl $@ $@ $(patsubst %/,%,$(dir $@)) "$(basename $(notdir $@))\.d"
@$(IF_EXIST) $(basename $@).d $(THEN) $(DEL_FILE) $(basename $@).d $(CMD_END)
@$(ECHO) -n "$@" >> $(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/cgen_l1v.det: FORCE
# Step 6: Result - Layer 1 validation information (L1S)
# *************************************************************************
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
ifeq ($(strip $(TEST_LOAD_TYPE)),L1S)
ifneq ($(strip $(MTK_SW_DOMAIN)),TRUE)
ifeq ($(strip $(CUSTOM_RELEASE)),FALSE)
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_l1v.det: FORCE
endif
$(MODIS_RULESDIR)/codegen_dep/cgen_l1v.det: $(MODIS_RULESDIR)/codegen_dep/l1v_db.det
$(MODIS_RULESDIR)/codegen_dep/cgen_l1v.det: $(filter-out %/l1validation_db/l1v_db/l1v_db.l1v,$(shell $(RECURSIVE_DIR) $(strip $(TST_DB))/l1validation_db/ "\.l1v")) $(NEED_CHECK_DEPEND_LIST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
@$(IF_EXIST) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(THEN) $(DEL_FILE) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(CMD_END)
@$(ECHO) -n "Generate common L1 Validation Information ..."
@$(ECHO) -n "$(CGEN) -L1V $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/l1validation_db/l1v_db/" >> $(CGEN_CFG_MODEM)
@$(IF_EXIST) $(basename $@).d $(THEN) $(DEL_FILE) $(basename $@).d $(CMD_END)
# too much *.l1v files, command length will be over 32KB
@$(FOR) $(F_OPT) $(DECLARE_VAR)i $(IN) `$(RECURSIVE_DIR) $(strip $(TST_DB))/l1validation_db "\.l1v"` $(DO) (echo $@: $(PRE_VAR)i >> $(basename $@).d) $(DONE)
@perl ./tools/pack_dep_gen.pl $@ $@ $(patsubst %/,%,$(dir $@)) "$(basename $(notdir $@))\.d"
@$(IF_EXIST) $(basename $@).d $(THEN) $(DEL_FILE) $(basename $@).d $(CMD_END)
@$(ECHO) -n "$@" >>$(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
endif
endif
endif
endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/cgen_l1v_sec.det
# *************************************************************************
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_l1v_sec.det: FORCE
endif
$(MODIS_RULESDIR)/codegen_dep/cgen_l1v_sec.det: $(MODIS_RULESDIR)/codegen_dep/l1v_db_sec.det $(CGEN) $(NEED_CHECK_DEPEND_LIST)
ifeq ($(MPD_SOURCE_FULL_BUILD),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_l1v_sec.det: $(filter-out %/l1validation_db/l1v_db/l1v_db.l1v,$(shell $(RECURSIVE_DIR) $(strip $(TST_DB_SEC))/l1validation_db/ "\.l1v"))
endif
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
@$(IF_EXIST) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(THEN) $(DEL_FILE) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(CMD_END)
@$(ECHO) -n "Generate sec L1 Validation Information ..."
@$(ECHO) -n "$(CGEN) -L1V $(CODEGEN_DATABASE_OUT_SEC) $(CODEGEN_DATABASE_IN_SEC) $(MODISBUILD_TST_DB_SEC)/l1validation_db/l1v_db/" >> $(CGEN_CFG_MODEM_SEC)
@$(IF_EXIST) $(basename $@).d $(THEN) $(DEL_FILE) $(basename $@).d $(CMD_END)
# too much *.l1v files, command length will be over 32KB
@$(FOR) $(F_OPT) $(DECLARE_VAR)i $(IN) `$(RECURSIVE_DIR) $(strip $(TST_DB_SEC))/l1validation_db "\.l1v"` $(DO) (echo $@: $(PRE_VAR)i >> $(basename $@).d) $(DONE)
@perl ./tools/pack_dep_gen.pl $@ $@ $(patsubst %/,%,$(dir $@)) "$(basename $(notdir $@))\.d"
@$(IF_EXIST) $(basename $@).d $(THEN) $(DEL_FILE) $(basename $@).d $(CMD_END)
@$(ECHO) -n "$@" >>$(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/cgen_un.det: FORCE
# Step 7: Result - Union Information (GSM/GPRS)
# *************************************************************************
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_un.det: FORCE
endif
ifneq ($(strip $(C2K_RELEASE)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_un.det: $(MODIS_RULESDIR)/codegen_dep/unionTag_parse_tdd_fdd.det
endif
$(MODIS_RULESDIR)/codegen_dep/cgen_un.det: $(MODIS_RULESDIR)/codegen_dep/unionTag_parse_tdd_fdd_ext.det $(NEED_CHECK_DEPEND_LIST)
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
@$(IF_EXIST) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(THEN) $(DEL_FILE) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(CMD_END)
@$(ECHO) -n "Generate common Union Information ..."
ifneq ($(strip $(C2K_RELEASE)),TRUE)
@$(ECHO) -n "$(CGEN) -un $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/unionTag/unionTag_parse.txt" >>$(CGEN_CFG_MODEM)
@$(ECHO) -n "$(CGEN) -un $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/unionTag/unionTag_parse_fdd.txt" >>$(CGEN_CFG_MODEM)
ifeq ($(strip $(UMTS_TDD_SUPPORT)),UMTS_TDD128_MODE_SUPPORT)
@$(ECHO) -n "$(CGEN) -un $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/unionTag/unionTag_parse_tdd.txt" >>$(CGEN_CFG_MODEM)
endif
endif
@$(ECHO) -n "$(CGEN) -un $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/unionTag/ext/unionTag_parse.txt" >>$(CGEN_CFG_MODEM)
@$(ECHO) -n "$(CGEN) -un $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/unionTag/ext/unionTag_parse_fdd.txt" >>$(CGEN_CFG_MODEM)
ifeq ($(strip $(UMTS_TDD_SUPPORT)),UMTS_TDD128_MODE_SUPPORT)
@$(ECHO) -n "$(CGEN) -un $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/unionTag/ext/unionTag_parse_tdd.txt" >>$(CGEN_CFG_MODEM)
endif
@$(ECHO) -n "$@:" >>$@
@$(ECHO) -n "$@" >>$(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/cgen_un_sec.det:
# *************************************************************************
ifeq ($(strip $(CUSTOM_RELEASE)),FALSE)
ifeq ($(RUN_UMTS_GEN),TRUE)
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_un_sec.det: FORCE
endif
$(MODIS_RULESDIR)/codegen_dep/cgen_un_sec.det: $(MODIS_RULESDIR)/codegen_dep/unionTag_parse_sec.det $(NEED_CHECK_DEPEND_LIST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
@$(IF_EXIST) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(THEN) $(DEL_FILE) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(CMD_END)
@$(ECHO) -n "Generate sec Union Information ..."
@$(ECHO) -n "$(CGEN) -un $(CODEGEN_DATABASE_OUT_SEC) $(CODEGEN_DATABASE_IN_SEC) $(MODISBUILD_TST_DB_SEC)/unionTag/unionTag_parse_sec.txt" >> $(CGEN_CFG_MODEM_SEC)
@$(ECHO) -n "$@:" >> $@
@$(ECHO) -n "$@" >> $(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
endif
endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/cgen_cm.det: FORCE
# Step 8: Result - Merge customization code
# *************************************************************************
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_cm.det: FORCE
endif
$(MODIS_RULESDIR)/codegen_dep/cgen_cm.det: $(MODIS_RULESDIR)/codegen_dep/custom_parse_db_tdd_fdd.det $(MODIS_RULESDIR)/codegen_dep/custom_parse_db.det $(VERNOFILE) $(CGEN) $(NEED_CHECK_DEPEND_LIST) $(strip $(PROJECT_MAKEFILE))
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
@$(IF_EXIST) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(THEN) $(DEL_FILE) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(CMD_END)
ifeq ($(strip $(CUSTOM_RELEASE)),TRUE)
@$(FOR) $(DECLARE_VAR)i $(IN) $(CODEGEN_DEPENDENCY_MODEM) $(DO) \
($(IF_EXIST) $(PRE_VAR)i $(THEN) $(DEL_FILE) $(PRE_VAR)i $(CMD_END)) \
$(DONE)
@$(IF_NOT_EXIST) $(MODISBUILD_TST_DB)/chk_cgen_step.ini $(THEN) $(ECHO) -n "$@" > $(MODISBUILD_TST_DB)/chk_cgen_step.ini $(CMD_END)
endif
@$(ECHO) -n $(CGEN) -cm6 $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/custom_parse_db.db $(MODISBUILD_TST_DB)/enumFileCustom >>$(CGEN_CFG_MODEM)
ifeq ($(strip $(CUSTOM_RELEASE)),FALSE)
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
ifeq ($(strip $(UMTS_TDD_SUPPORT)),UMTS_TDD128_MODE_SUPPORT)
@$(ECHO) -n $(CGEN) -cm5 $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/custom_parse_db_fdd.db $(MODISBUILD_TST_DB)/enumFileCustom >>$(CGEN_CFG_MODEM)
@$(ECHO) -n $(CGEN) -cm $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/custom_parse_db_tdd.db $(MODISBUILD_TST_DB)/enumFileCustom $(strip $(PLATFORM))_$(strip $(CHIP_VER)) $(strip $(VERNO)) -sf-$(MODISBUILD_TST_DB)/sf.ini -prjName-"$(strip $(FULL_PRJ_NAME))" -VERNO_HAL-$(strip $(VERNO_HAL)) >>$(CGEN_CFG_MODEM)
else
@$(ECHO) -n $(CGEN) -cm $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/custom_parse_db_fdd.db $(MODISBUILD_TST_DB)/enumFileCustom $(strip $(PLATFORM))_$(strip $(CHIP_VER)) $(strip $(VERNO)) -sf-$(MODISBUILD_TST_DB)/sf.ini -prjName-"$(strip $(FULL_PRJ_NAME))" -VERNO_HAL-$(strip $(VERNO_HAL)) >>$(CGEN_CFG_MODEM)
endif
else
ifeq ($(strip $(UMTS_TDD_SUPPORT)),UMTS_TDD128_MODE_SUPPORT)
@$(ECHO) -n $(CGEN) -cm5 $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/custom_parse_db_fdd.db $(MODISBUILD_TST_DB)/enumFileCustom >>$(CGEN_CFG_MODEM)
@$(ECHO) -n $(CGEN) -cm $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/custom_parse_db_tdd.db $(MODISBUILD_TST_DB)/enumFileCustom MoDIS $(strip $(VERNO)) >>$(CGEN_CFG_MODEM)
else
@$(ECHO) -n $(CGEN) -cm6 $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/custom_parse_db.db $(MODISBUILD_TST_DB)/enumFileCustom >>$(CGEN_CFG_MODEM)
@$(ECHO) -n $(CGEN) -cm $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/custom_parse_db_fdd.db $(MODISBUILD_TST_DB)/enumFileCustom MoDIS $(strip $(VERNO)) >>$(CGEN_CFG_MODEM)
endif
endif
@$(ECHO) -n $(MODISBUILD_TST_DB)/enumFileCustom >>$(CODE_GEN_LST)
else
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
ifeq ($(strip $(UMTS_TDD_SUPPORT)),UMTS_TDD128_MODE_SUPPORT)
@$(ECHO) -n $(CGEN) -cm5 $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/custom_parse_db_fdd.db $(MODISBUILD_TST_DB)/enumFileCustomAppSrc >>$(CGEN_CFG_MODEM)
@$(ECHO) -n $(CGEN) -cm $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/custom_parse_db_tdd.db $(MODISBUILD_TST_DB)/enumFileCustomAppSrc $(strip $(PLATFORM))_$(strip $(CHIP_VER)) $(strip $(VERNO)) -sf-$(MODISBUILD_TST_DB)/sf.ini -prjName-"$(strip $(FULL_PRJ_NAME))" -VERNO_HAL-$(strip $(VERNO_HAL)) >>$(CGEN_CFG_MODEM)
else
@$(ECHO) -n $(CGEN) -cm $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/custom_parse_db_fdd.db $(MODISBUILD_TST_DB)/enumFileCustomAppSrc $(strip $(PLATFORM))_$(strip $(CHIP_VER)) $(strip $(VERNO)) -sf-$(MODISBUILD_TST_DB)/sf.ini -prjName-"$(strip $(FULL_PRJ_NAME))" -VERNO_HAL-$(strip $(VERNO_HAL)) >>$(CGEN_CFG_MODEM)
endif
else
ifeq ($(strip $(UMTS_TDD_SUPPORT)),UMTS_TDD128_MODE_SUPPORT)
@$(ECHO) -n $(CGEN) -cm5 $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/custom_parse_db_fdd.db $(MODISBUILD_TST_DB)/enumFileCustomAppSrc >>$(CGEN_CFG_MODEM)
@$(ECHO) -n $(CGEN) -cm $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/custom_parse_db_tdd.db $(MODISBUILD_TST_DB)/enumFileCustomAppSrc MoDIS $(strip $(VERNO)) $(MMIDIR) >>$(CGEN_CFG_MODEM)
else
@$(ECHO) -n $(CGEN) -cm $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/custom_parse_db_fdd.db $(MODISBUILD_TST_DB)/enumFileCustomAppSrc MoDIS $(strip $(VERNO)) $(MMIDIR) >>$(CGEN_CFG_MODEM)
endif
endif
@$(ECHO) -n $(MODISBUILD_TST_DB)/enumFileCustomAppSrc >>$(CODE_GEN_LST)
endif
@$(ECHO) -n $@: $(VERNOFILE) "$(PROJECT_MAKEFILE)" >> $@
@$(ECHO) -n $@ >> $(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/cgen_ap_srcParseDbModem.det: FORCE
# Step 8: Result - Merge customization code
# *************************************************************************
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_ap_srcParseDbModem.det: FORCE
endif
$(MODIS_RULESDIR)/codegen_dep/cgen_ap_srcParseDbModem.det: $(MODIS_RULESDIR)/codegen_dep/srcParseDbModem_tdd_fdd.det $(MODIS_RULESDIR)/codegen_dep/srcParseDbModem.det $(VERNOFILE) $(CGEN) $(NEED_CHECK_DEPEND_LIST) $(strip $(PROJECT_MAKEFILE))
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
@$(IF_EXIST) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(THEN) $(DEL_FILE) $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det $(CMD_END)
@$(ECHO) -n $(CGEN) -ap9 $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/srcParseDbModem.db $(MODISBUILD_TST_DB)/enumFileCustomApp >>$(CGEN_CFG_MODEM)
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
ifeq ($(strip $(CUSTOM_RELEASE)),FALSE)
ifeq ($(strip $(UMTS_TDD_SUPPORT)),UMTS_TDD128_MODE_SUPPORT)
@$(ECHO) -n $(CGEN) -ap7 $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/srcParseDbModem_fdd.db $(MODISBUILD_TST_DB)/enumFileCustomApp >>$(CGEN_CFG_MODEM)
@$(ECHO) -n $(CGEN) -ap $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/srcParseDbModem_tdd.db $(MODISBUILD_TST_DB)/enumFileCustomApp $(strip $(PLATFORM))_$(strip $(CHIP_VER)) $(strip $(VERNO)) >>$(CGEN_CFG_MODEM)
else
@$(ECHO) -n $(CGEN) -ap $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/srcParseDbModem_fdd.db $(MODISBUILD_TST_DB)/enumFileCustomApp $(strip $(PLATFORM))_$(strip $(CHIP_VER)) $(strip $(VERNO)) >>$(CGEN_CFG_MODEM)
endif
@$(ECHO) -n $(MODISBUILD_TST_DB)/enumFileCustomApp >>$(CODE_GEN_LST)
endif
else
ifeq ($(strip $(CUSTOM_RELEASE)),FALSE)
ifeq ($(strip $(UMTS_TDD_SUPPORT)),UMTS_TDD128_MODE_SUPPORT)
@$(ECHO) -n $(CGEN) -ap7 $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/srcParseDbModem_fdd.db $(MODISBUILD_TST_DB)/enumFileCustomApp >>$(CGEN_CFG_MODEM)
@$(ECHO) -n $(CGEN) -ap $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/srcParseDbModem_tdd.db $(MODISBUILD_TST_DB)/enumFileCustomApp MoDIS $(strip $(VERNO)) >>$(CGEN_CFG_MODEM)
else
@$(ECHO) -n $(CGEN) -ap $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_IN) $(MODISBUILD_TST_DB)/msglog_db/srcParseDbModem_fdd.db $(MODISBUILD_TST_DB)/enumFileCustomApp MoDIS $(strip $(VERNO)) >>$(CGEN_CFG_MODEM)
endif
@$(ECHO) -n $(MODISBUILD_TST_DB)/enumFileCustomApp >>$(CODE_GEN_LST)
endif
endif
@$(ECHO) -n $@: $(VERNOFILE) "$(PROJECT_MAKEFILE)" >> $@
@$(ECHO) -n $@ >> $(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/cgen_filter_gen_Modem.det:
# *************************************************************************
LOG2SD_CATCHER_FILTERS_LIST := $(subst log2SD_Catcher_filters_,,$(notdir $(basename $(strip $(LOG2SD_CATCHER_FILTERS_FILE_LIST)))))
DBF_INI_LIST := $(notdir $(wildcard $(DBFINI_DIR)/DSP_*))
CUS_OPT_INI := interface/service/logging_database/XDD/customer_option.ini
ifeq ($(strip $(RELEASE_PACKAGE)),REL_INTERNAL)
BUILTINFILTERINI := interface/service/logging_database/XDD/Customization/BuiltinFilterSetting.ini
else
BUILTINFILTERINI := interface/service/logging_database/XDD/Customization/BuiltinFilterSettingExternal.ini
endif
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_filter_gen_Modem.det: FORCE
endif
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_filter_gen_Modem.det:
else
ifneq ($(wildcard $(BUILD_TST_DB)/log2SD_Catcher_filters.ini),)
# exist tst/database/log2SD_Catcher_filters.ini
else
$(MODIS_RULESDIR)/codegen_dep/cgen_filter_gen_Modem.det:
endif
endif
$(MODIS_RULESDIR)/codegen_dep/cgen_filter_gen_Modem.det: $(LOGGING_DATABASE)/XDD/mini_log_Catcher_filters.ini
ifneq ($(strip $(UPDATE_DSP)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_filter_gen_Modem.det: $(filter-out \
$(MODIS_RULESDIR)/codegen_dep/cgen_filter_gen_Modem.det \
$(MODIS_RULESDIR)/codegen_dep/cgen_gv.det \
$(MODIS_RULESDIR)/codegen_dep/cgen_l1v.det \
$(MODIS_RULESDIR)/codegen_dep/cgen_un.det \
,$(CODEGEN_DEPENDENCY_MODEM))
endif
$(MODIS_RULESDIR)/codegen_dep/cgen_filter_gen_Modem.det: $(NEED_CHECK_DEPEND_LIST) $(VERNOFILE) $(POSTGEN) $(NEED_CHECK_DEPEND_LIST) $(strip $(PROJECT_MAKEFILE))
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
@$(ECHO) -n $@: >>$@
@$(IF_NOT_EXIST) $(BUILD_TSTDIR)/src $(THEN) $(MKDIR) $(BUILD_TSTDIR)/src $(CMD_END)
@$(IF_EXIST) $(strip $(POSTGEN_CFG_MODEM)) $(THEN) $(DEL_FILE) $(strip $(POSTGEN_CFG_MODEM)) $(CMD_END)
@$(ECHO) -n $(POSTGEN) -log_sec_key_gen $(CODEGEN_DATABASE_OUT) $(CODEGEN_MDKEY) $(BUILD_TSTDIR)/src/traceKey.c $(strip $(CUS_OPT_INI)) > $(POSTGEN_CFG_MODEM)
@$(ECHO) -n $(POSTGEN) -filter_sig $(CODEGEN_DATABASE_OUT) $(BUILD_TSTDIR)/src/filterSig.c >> $(POSTGEN_CFG_MODEM)
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
ifneq ($(strip $(TEST_LOAD_TYPE)),L1S)
ifneq ($(strip $(CLOSE_MDM_LAYOUT)),TRUE)
@$(ECHO) -n $(POSTGEN) -em_filter_gen $(CODEGEN_DATABASE_OUT) $(strip $(LOGGING_DATABASE))/MSG_LIST $(MODISBUILD_TST_DB)/em_filter.bin >> $(POSTGEN_CFG_MODEM)
@$(ECHO) -n $(POSTGEN) -all_em_info $(CODEGEN_DATABASE_OUT) $(CODEGEN_DATABASE_OUT) $(strip $(LOGGING_DATABASE))/MSG_LIST >> $(POSTGEN_CFG_MODEM)
@$(ECHO) -n $(POSTGEN) -extract_all_em_info $(CODEGEN_DATABASE_OUT) $(MODISBUILD_TST_DB)/mdm_layout_desc.dat >> $(POSTGEN_CFG_MODEM)
endif
ifneq ($(strip $(NO_DSP)),TRUE)
ifneq ($(strip $(CUSTOM_RELEASE)),TRUE)
@$(IF_NOT_EXIST) $(strip $(MODISBUILD_TST_DB))/dbf $(THEN) $(MKDIR) $(strip $(MODISBUILD_TST_DB))/dbf $(CMD_END)
@$(FOR) $(DECLARE_VAR)i $(IN) $(DBF_INI_LIST) $(DO) \
($(IF_EXIST) $(strip $(DBFINI_DIR))/$(PRE_VAR)i $(THEN) \
(mono ${UNIVERSAL_COMMON}/tools/dex_gen/$(strip $(MD_VER_FOLDER))/DSPXMLUtil.exe -iFltrXML $(DSPDIR)/$(strip $(DSP_PROJECT))/$(strip $(DSP_FLAVOR))/final_bin/xml/filterXML -iFilterIni $(strip $(DBFINI_DIR))/$(PRE_VAR)i -oDBFDir "$(strip $(MODISBUILD_TST_DB))/dbf") >> $(strip $(COMPLOGDIR))/gen_dbf.log \
$(CMD_END)) \
$(DONE)
endif
@$(ECHO) -n $(POSTGEN) -gen_built_in_filter_utf bin $(CODEGEN_DATABASE_OUT) $(strip $(BUILTINFILTERINI)) $(BUILD_TST_DB) $(strip $(DBF_INPUT_PATH)) >> $(POSTGEN_CFG_MODEM)
endif
endif #end of L1S
endif #MODIS_CONFIG
@$(ECHO) -n $(POSTGEN) -gen_built_in_filter_utf src $(CODEGEN_DATABASE_OUT) $(strip $(BUILTINFILTERINI)) $(BUILD_TSTDIR)/src/dhl_builtin_filters.c $(strip $(DBF_INPUT_PATH)) >> $(POSTGEN_CFG_MODEM)
ifeq ($(strip $(ICD_SUPPORT)),TRUE)
@$(ECHO) -n $(POSTGEN) -gen_icd_built_in_filter $(CODEGEN_DATABASE_OUT) $(strip $(PROJDIR))/modem/icd_ac_gen/ICDJSONDef_cgen.json $(strip $(BUILTINFILTERINI)) $(strip $(LOGGING_DATABASE))/XDD/ICD $(BUILD_TSTDIR)/src/icd_builtin_filters.c >> $(POSTGEN_CFG_MODEM)
endif
ifneq ($(strip $(TEST_LOAD_TYPE)),L1S)
@$(ECHO) -n $(BUILD_TST_DB)/dsp_filter.bin >>$(CODE_GEN_LST)
@$(ECHO) -n $(BUILD_TST_DB)/merge_filter.bin >>$(CODE_GEN_LST)
# generate meta database
@$(ECHO) -n "@PROJECT_NAME@MTK = ENUM_DB" > $(MODISBUILD_TST_DB)/nvram_db_cnf.ini
@$(ECHO) -n "@PROJECT_NAME@CM = ENUM_DB" >> $(MODISBUILD_TST_DB)/nvram_db_cnf.ini
@$(ECHO) -n "nvram_mcf_ota_lid = ENUM_DB" >> $(MODISBUILD_TST_DB)/nvram_db_cnf.ini
@$(ECHO) -n "nvram_mcf_ota_by_operator_lid = ENUM_DB" >> $(MODISBUILD_TST_DB)/nvram_db_cnf.ini
@$(ECHO) -n "mcf_tool_version_info = ENUM_DB" >> $(MODISBUILD_TST_DB)/nvram_db_cnf.ini
@$(ECHO) -n "GPRF=SPECIFY_DB" >> $(MODISBUILD_TST_DB)/nvram_db_cnf.ini
@perl ./tools/NVRAMStatistic/gen_secure_nvram_lid_structure_to_db.pl ./interface/service/nvram/nvram_lid_structure_check_extend_list.h $(MODISBUILD_TST_DB)/nvram_db_cnf.ini
@$(ECHO) -n "$(POSTGEN) -meta_db_gen $(MODISBUILD_TST_DB)/$(MDDBMETA_V12) $(CODEGEN_DATABASE_OUT) $(MODISBUILD_TST_DB)/nvram_db_cnf.ini -saveXmlFile-$(MODISBUILD_TST_DB)/$(MDDBMETADATABASEXML)" >>$(POSTGEN_CFG_MODEM)
@$(ECHO) -n "$(POSTGEN) -compress_gen $(MODISBUILD_TST_DB)/$(MDDBMETADATABASEXML).GZ $(MODISBUILD_TST_DB)/$(MDDBMETADATABASEXML)" >>$(POSTGEN_CFG_MODEM)
@$(ECHO) -n $@: $(LOGGING_DATABASE)/XDD/mini_log_Catcher_filters.ini >> $@
@$(ECHO) -n $@ >>$(CODE_GEN_LST)
endif
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/cgen_cfg_Modem.det
# *************************************************************************
IS_LIB_RELEASE := REL_SUB_SW,SRC
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_cfg_Modem.det: FORCE
endif
ifneq ($(strip $(UPDATE_DSP)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_cfg_Modem.det: $(CODEGEN_DEPENDENCY_MODEM)
endif
$(MODIS_RULESDIR)/codegen_dep/cgen_cfg_Modem.det: $(CGEN)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
ifeq ($(strip $(CUSTOM_RELEASE)),TRUE)
ifneq ($(strip $(TEST_LOAD_TYPE)),L1S)
ifneq ($(words $(strip $(MDDBINFOCUSTOM))),1)
@$(ECHO) -n [ERROR] Cannot determine the original codegen database: $(strip $(MDDBINFOCUSTOM)) >> $(CODE_GEN_LOG)
@$(ECHO) -n [ERROR] Cannot determine the original codegen database: $(strip $(MDDBINFOCUSTOM))
@exit 2
endif
endif
else
ifneq ($(strip $(MTK_SW_DOMAIN)),TRUE)
ifeq ($(MPD_SOURCE_FULL_BUILD),FALSE)
ifneq ($(strip $(NO_LTECGEN)),TRUE)
ifeq ($(strip $(CODEGEN_DATABASE_IN_SEC)),)
@$(ECHO) -n "Error: There is no existing any LTE database in the path: $(CUS_MTK_REL)/dhl/lte_sec/database" >> $(CODE_GEN_LOG)
@$(ECHO) -n "Error: $@ Failed. Please check $(CODE_GEN_LOG)" $(WITH) exit 1
else ifneq ($(words $(strip $(CODEGEN_DATABASE_IN_SEC))),1)
@$(ECHO) -n "Error: There is existing multiple LTE databases: $(strip $(CODEGEN_DATABASE_IN_SEC))" >> $(CODE_GEN_LOG)
@$(ECHO) -n "Error: Please remove redundant LTE database in the path: $(CUS_MTK_REL)/dhl/lte_sec/datababase" >> $(CODE_GEN_LOG)
@$(ECHO) -n "Error: $@ Failed. Please check $(CODE_GEN_LOG)" $(WITH) exit 1
endif
endif
endif
endif
endif
@$(IF_NOT_EXIST) $(strip $(CGEN_CFG_MODEM)) $(THEN) (echo Error: $(CGEN_CFG_MODEM) does not exist!) $(AND) (exit 1) $(CMD_END)
ifneq ($(strip $(UPDATE_DSP)),TRUE)
ifeq ($(MPD_SOURCE_FULL_BUILD),TRUE)
@$(IF_EXIST) $(strip $(CGEN_CFG_MODEM_SEC)) $(THEN) \
echo Cgen $(strip $(GEN_DB_OPTION)) -cfg $(CGEN_CFG_MODEM_SEC) $(AND) \
($(CGEN) $(strip $(GEN_DB_OPTION)) -cfg $(CGEN_CFG_MODEM_SEC) 2>>$(CODE_GEN_LOG)) $(WITH) \
($(IF_ERR_TRUE) $(THEN) (echo Error: Cgen failed. Please check $(CODE_GEN_LOG) $(WITH) exit 1) $(CMD_END)) \
$(CMD_END)
#save enum to db
@$(ECHO) -n "$(strip $(MTK_MODEM_ARCH))=0" > $(MODISBUILD_TST_DB_SEC)/mtk_modem_arch_sec.ini
@$(ECHO) -n "AUTO_GEN@GLOBAL_DEBUG_LEVEL=$(strip $(GLOBAL_TRACE_DEBUG_LEVEL))" > $(MODISBUILD_TST_DB_SEC)/feature_option_enum_sec.ini
@$(ECHO) -n "$(strip $(DSP_PROJECT))=0" > $(MODISBUILD_TST_DB_SEC)/dsp_project_flavor_sec.ini
@$(ECHO) -n "$(strip $(DSP_FLAVOR))=1" >> $(MODISBUILD_TST_DB_SEC)/dsp_project_flavor_sec.ini
@$(ECHO) -n "catcher_filter_bin=0" > $(MODISBUILD_TST_DB_SEC)/modem_filter_list.ini
ifneq ($(LOG2SD_CATCHER_FILTERS_LIST),)
@perl ./tools/gen_md_filter_list.pl $(strip $(PROJDIR)) $(MODISBUILD_TST_DB_SEC)/modem_filter_list.ini
endif
@$(ECHO) -n "<@MK_MTK_MODEM_ARCH>$(MODISBUILD_TST_DB_SEC)/mtk_modem_arch_sec.ini" > $(MODISBUILD_TST_DB_SEC)/file2enum_sec.ini
@$(ECHO) -n "<@FEATURE_OPTION_ENUM>$(MODISBUILD_TST_DB_SEC)/feature_option_enum_sec.ini" >> $(MODISBUILD_TST_DB_SEC)/file2enum_sec.ini
@$(ECHO) -n "<@MK_DSP_PROJECT_FLAVOR>$(MODISBUILD_TST_DB_SEC)/dsp_project_flavor_sec.ini" >> $(MODISBUILD_TST_DB_SEC)/file2enum_sec.ini
@$(ECHO) -n "<@ModemDefaultFilterList>$(MODISBUILD_TST_DB_SEC)/modem_filter_list.ini" >> $(MODISBUILD_TST_DB_SEC)/file2enum_sec.ini
@$(IF_EXIST) $(strip $(CODEGEN_DATABASE_OUT_SEC)) $(THEN)\
echo $(POSTGEN) $(strip $(GEN_DB_OPTION)) -save_enum $(CODEGEN_DATABASE_OUT_SEC) $(MODISBUILD_TST_DB_SEC)/file2enum_sec.ini $(AND) \
($(POSTGEN) $(strip $(GEN_DB_OPTION)) -save_enum $(CODEGEN_DATABASE_OUT_SEC) $(MODISBUILD_TST_DB_SEC)/file2enum_sec.ini 2>>$(CODE_GEN_LOG)) $(WITH) \
($(IF_ERR_TRUE) $(THEN) (echo Error: PostGen failed. Please check $(CODE_GEN_LOG) $(WITH) exit 1) $(CMD_END)) \
$(CMD_END)
endif
ifeq ($(MPD_SOURCE_4G_BUILD),TRUE)
@$(IF_EXIST) $(MODISBUILD_TST_DB)/chk_cgen_step.ini $(THEN) \
($(IF_EXIST) $(strip $(CGEN_CFG_MODEM_4G)) $(THEN) \
$(ECHO) $(CGEN) $(strip $(GEN_DB_OPTION)) -cfg $(CGEN_CFG_MODEM_4G) $(AND) \
($(CGEN) $(strip $(GEN_DB_OPTION)) -cfg $(CGEN_CFG_MODEM_4G) 2>>$(CODE_GEN_LOG)) $(WITH) \
($(IF_ERR_TRUE) $(THEN) (echo Error: Cgen failed. Please check $(CODE_GEN_LOG) $(WITH) exit 1) $(CMD_END)) \
$(CMD_END)) \
$(ELSE) \
($(IF_EXIST) $(strip $(CGEN_CFG_MODEM_4G)) $(THEN) \
($(CAT) $(strip $(CGEN_CFG_MODEM_4G)) > $(strip $(CGEN_CFG_MODEM))_tmp) $(AND)\
($(CAT) $(strip $(CGEN_CFG_MODEM)) >> $(strip $(CGEN_CFG_MODEM))_tmp) $(AND)\
($(CAT) $(strip $(CGEN_CFG_MODEM)_tmp) > $(strip $(CGEN_CFG_MODEM))) \
$(CMD_END)) \
$(CMD_END)
endif
@$(ECHO) -n $(CGEN) $(strip $(GEN_DB_OPTION)) -cfg $(CGEN_CFG_MODEM)
@($(CGEN) $(strip $(GEN_DB_OPTION)) -cfg $(CGEN_CFG_MODEM) 2>>$(CODE_GEN_LOG)) $(WITH) \
($(IF_ERR_TRUE) $(THEN) (echo Error: Cgen failed. Please check $(CODE_GEN_LOG) $(WITH) exit 1) $(CMD_END))
endif #UPDATE_DSP
@$(IF_EXIST) $(strip $(POSTGEN_CFG_MODEM)) $(THEN) \
$(ECHO) $(POSTGEN) $(strip $(GEN_DB_OPTION)) -cfg $(POSTGEN_CFG_MODEM) $(AND) \
($(POSTGEN) $(strip $(GEN_DB_OPTION)) -cfg $(POSTGEN_CFG_MODEM) 2>>$(CODE_GEN_LOG)) $(WITH) \
($(IF_ERR_TRUE) $(THEN) \
$(DEL_FILE) "$(MODISBUILD_TST_DB)/*MDDB*" $(AND) \
(echo Error: Postgen failed. Please check $(CODE_GEN_LOG) $(WITH) exit 1) \
$(CMD_END)) \
$(CMD_END)
@$(IF_EXIST) $(BUILD_TST_DB)/catcher_filter_Default.bin $(THEN) \
$(MOVE) $(BUILD_TST_DB)/catcher_filter_Default.bin $(BUILD_TST_DB)/catcher_filter.bin >$(DEV_NUL) \
$(CMD_END)
ifneq ($(strip $(TEST_LOAD_TYPE)),L1S)
@$(DB_CONVERTER) V12ToV11 $(MODISBUILD_TST_DB)/$(MDDBMETA_V12) $(MODISBUILD_TST_DB)/$(MDDBMETA) 2>>$(CODE_GEN_LOG) $(WITH)\
$(IF_ERR_TRUE) $(THEN) (echo Error: DBv12_Converter error. Please check $(CODE_GEN_LOG) $(WITH) exit 1) $(CMD_END)
endif
ifeq ($(strip $(MCF_SUPPORT)),TRUE)
ifneq ($(strip $(UPDATE_DSP)),TRUE)
@$(MAKE) -fmake/common/build.mak -r -R --no-print-directory mcf_gen
endif
endif
@$(IF_EXIST) $(MODISBUILD_TST_DB)/$(MDDBMETADATABASEXML).GZ $(THEN) \
$(IF_EXIST) $(MODISBUILD_TST_DB)/$(MDDBMETADATABASEXML) $(THEN) \
$(DEL_FILE) "$(MODISBUILD_TST_DB)/$(MDDBMETADATABASEXML)" \
$(CMD_END) \
$(CMD_END)
ifneq ($(strip $(OS_VERSION)),MSWin32)
#restore xxx_trc_gen.h
@($(LIST_DIR) "$(MODISBUILD_TST_DB)/pstrace_db_bak/*.h" 1>$(DEV_NUL) 2>&1 $(WITH) \
$(IF_ERR_FALSE) $(THEN)\
($(FOR) $(F_OPT) $(DECLARE_VAR)i $(IN) `$(LIST_DIR) -n -b "$(MODISBUILD_TST_DB)/pstrace_db_bak/*.h"` $(DO)\
(($(COMPARE) $(MODISBUILD_TST_DB)/pstrace_db/$(PRE_VAR)i $(MODISBUILD_TST_DB)/pstrace_db_bak/$(PRE_VAR)i >$(DEV_NUL) 2>&1) $(WITH) \
($(IF_ERR_FALSE) $(THEN)(touch -r $(MODISBUILD_TST_DB)/pstrace_db_bak/$(PRE_VAR)i $(MODISBUILD_TST_DB)/pstrace_db/$(PRE_VAR)i >$(DEV_NUL)) \
$(ELSE) (echo $(PRE_VAR)i is updated) $(CMD_END) ))\
$(DONE))\
$(CMD_END))
@$(IF_EXIST) $(MODISBUILD_TST_DB)/pstrace_db_bak $(THEN) $(DEL_DIR) $(MODISBUILD_TST_DB)/pstrace_db_bak $(CMD_END)
@($(LIST_DIR) "$(BUILD_TSTDIR)/include_bak/*.h" 1>$(DEV_NUL) 2>&1 $(WITH) \
$(IF_ERR_FALSE) $(THEN) \
($(FOR) $(F_OPT) $(DECLARE_VAR)i $(IN) `$(LIST_DIR) -n -b "$(BUILD_TSTDIR)/include_bak/*.h"` $(DO)\
(($(COMPARE) $(BUILD_TSTDIR)/include/$(PRE_VAR)i $(BUILD_TSTDIR)/include_bak/$(PRE_VAR)i >$(DEV_NUL) 2>&1) $(WITH)\
($(IF_ERR_FALSE) $(THEN) (touch -r $(BUILD_TSTDIR)/include_bak/$(PRE_VAR)i $(BUILD_TSTDIR)/include/$(PRE_VAR)i >$(DEV_NUL))\
$(ELSE) (echo $(PRE_VAR)i is updated) $(CMD_END))) \
$(DONE))\
$(CMD_END))
@$(IF_EXIST) $(BUILD_TSTDIR)/include_bak $(THEN) $(DEL_DIR) $(BUILD_TSTDIR)/include_bak $(CMD_END)
@($(LIST_DIR) "$(BUILD_TSTDIR)/src_bak/*.*" 1>$(DEV_NUL) 2>&1 $(WITH) \
$(IF_ERR_FALSE) $(THEN) \
($(FOR) $(F_OPT) $(DECLARE_VAR)i $(IN) `$(LIST_DIR) -n -b "$(BUILD_TSTDIR)/src_bak/*.*"` $(DO)\
(($(COMPARE) $(BUILD_TSTDIR)/src/$(PRE_VAR)i $(BUILD_TSTDIR)/src_bak/$(PRE_VAR)i >$(DEV_NUL) 2>&1) $(WITH)\
($(IF_ERR_FALSE) $(THEN) (touch -r $(BUILD_TSTDIR)/src_bak/$(PRE_VAR)i $(BUILD_TSTDIR)/src/$(PRE_VAR)i >$(DEV_NUL))\
$(ELSE) (echo $(PRE_VAR)i is updated) $(CMD_END))) \
$(DONE))\
$(CMD_END))
@$(IF_EXIST) $(BUILD_TSTDIR)/src_bak $(THEN) $(DEL_DIR) $(BUILD_TSTDIR)/src_bak $(CMD_END)
@($(LIST_DIR) "$(strip $(PROJ_INTERNAL_DIR))/l1trace_bak/*.*" 1>$(DEV_NUL) 2>&1 $(WITH) \
$(IF_ERR_FALSE) $(THEN) \
($(FOR) $(F_OPT) $(DECLARE_VAR)i $(IN) `$(LIST_DIR) -n -b "$(strip $(PROJ_INTERNAL_DIR))/l1trace_bak/*.*"` $(DO)\
(($(COMPARE) $(strip $(PROJ_INTERNAL_DIR))/l1trace/$(PRE_VAR)i $(strip $(PROJ_INTERNAL_DIR))/l1trace_bak/$(PRE_VAR)i >$(DEV_NUL) 2>&1) $(WITH)\
($(IF_ERR_FALSE) $(THEN) (touch -r $(strip $(PROJ_INTERNAL_DIR))/l1trace_bak/$(PRE_VAR)i $(strip $(PROJ_INTERNAL_DIR))/l1trace/$(PRE_VAR)i >$(DEV_NUL))\
$(ELSE) (echo $(PRE_VAR)i is updated) $(CMD_END))) \
$(DONE))\
$(CMD_END))
@$(IF_EXIST) $(strip $(PROJ_INTERNAL_DIR))/l1trace_bak $(THEN) $(DEL_DIR) $(strip $(PROJ_INTERNAL_DIR))/l1trace_bak $(CMD_END)
endif #OS_VERSION
@$(ECHO) -n $@: $(CGEN) $(POSTGEN) >> $@
ifeq ($(MPD_SOURCE_FULL_BUILD),TRUE)
@$(ECHO) -n $@: $(MODISBUILD_TST_DB_SEC)/mtk_modem_arch_sec.ini >> $@
@$(ECHO) -n $@: $(MODISBUILD_TST_DB_SEC)/feature_option_enum_sec.ini >> $@
@$(ECHO) -n $@: $(MODISBUILD_TST_DB_SEC)/dsp_project_flavor_sec.ini >> $@
@$(ECHO) -n $@: $(MODISBUILD_TST_DB_SEC)/file2enum_sec.ini >> $@
endif
@$(IF_EXIST) $(MODIS_RULESDIR)/codegen_dep/codegen.det $(THEN) $(DEL_FILE) $(MODIS_RULESDIR)/codegen_dep/codegen.det $(CMD_END)
@perl ./tools/pack_dep_gen.pl $(dir $@)codegen.det $(dir $@)cgen_preflow.det $(patsubst %/,%,$(dir $@)) "\.det"
@$(ECHO) -n $(dir $@)cgen_preflow.det: >>$(dir $@)cgen_preflow.det
@$(ECHO) -n $@ >>$(CODE_GEN_LST)
@$(ECHO) -n $(dir $@)codegen.det >> $(CODE_GEN_LST)
@$(ECHO) -n $(CGEN_CFG_MODEM) >> $(CODE_GEN_LST)
@$(ECHO) -n $(CGEN_CFG_MODEM_SEC) >> $(CODE_GEN_LST)
@$(ECHO) -n $(CODEGEN_DATABASE_OUT) >> $(CODE_GEN_LST)
@$(ECHO) -n $(CODEGEN_DATABASE_OUT_SEC) >> $(CODE_GEN_LST)
@$(ECHO) -n $(dir $@)cgen_preflow.det: $(foreach comp, $(strip $(COMPLIST)), $(strip $(MODULEINFODIR))/$(comp)/$(comp).def) >> $(dir $@)codegen.det
@perl ./tools/pack_dep_gen.pl $(MODIS_RULESDIR)/codegen.dep custom_parse_db.obj $(patsubst %/,%,$(dir $@)) "\bcustom_parse_db\.det"
@perl ./tools/pack_dep_gen.pl $(MODIS_RULESDIR)/srcParseDbModem.d srcParseDbModem.obj $(patsubst %/,%,$(dir $@)) "\bsrcParseDbModem\.det"
@$(IF_EXIST) $(MODIS_RULESDIR)/srcParseDbModem.d $(THEN) (($(CAT) $(MODIS_RULESDIR)/srcParseDbModem.d >>$(MODIS_RULESDIR)/codegen.dep) $(AND) ($(DEL_FILE) $(MODIS_RULESDIR)/srcParseDbModem.d)) $(CMD_END)
ifneq ($(strip $(MTK_SW_DOMAIN)),TRUE)
ifneq ($(PCIBT_ACTION_LIST),)
$(PCIBT_SCRIPT_CMD) $(CHK_LTE_COMP) "service/dhl/database/msglog_db/custom_parse_db_tdd_fdd.c" $(dir $@)custom_parse_db_tdd_fdd.det $(filter-out $(IS_LIB_RELEASE), $(PCIBT_ACTION_LIST)) 2>>$(strip $(CODE_GEN_LOG))
$(PCIBT_SCRIPT_CMD) $(CHK_LTE_COMP) "service/dhl/database/msglog_db/custom_parse_db.c" $(dir $@)custom_parse_db.det $(filter-out $(IS_LIB_RELEASE), $(PCIBT_ACTION_LIST)) 2>>$(strip $(CODE_GEN_LOG))
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
ifeq ($(strip $(MPD_SOURCE_4G_BUILD)),TRUE)
$(PCIBT_SCRIPT_CMD) $(CHK_LTE_COMP) "service/dhl/database/msglog_db/libParseDbModem.c" $(dir $@)libParseDbModem.det REL_SUB_MPD_COMMON,SRC 2>>$(strip $(CODE_GEN_LOG))
$(PCIBT_SCRIPT_CMD) $(CHK_LTE_COMP) "service/dhl/database/msglog_db/libParseDbModem_tdd_fdd.c" $(dir $@)libParseDbModem_tdd_fdd.det REL_SUB_MPD_COMMON,SRC 2>>$(strip $(CODE_GEN_LOG))
endif
ifeq ($(strip $(MPD_SOURCE_FULL_BUILD)),TRUE)
$(PCIBT_SCRIPT_CMD) $(CHK_LTE_COMP) "service/dhl/database/msglog_db/libParseDbModem_4g.c" $(dir $@)libParseDbModem_4g.det REL_SUB_MPD_4G,SRC 2>>$(strip $(CODE_GEN_LOG))
endif
endif
endif
endif
ifeq ($(strip $(NVRAM_LID_CHECK)),TRUE)
@$(ECHO) -n ==== NVRAM LID CHECK START ====
@$(IF_EXIST) $(strip $(PROJDIR))/nvram_auto_gen/MDDB.META.ODB.XML $(THEN) $(DEL_FILE) $(strip $(PROJDIR))/nvram_auto_gen/MDDB.META.ODB.XML $(CMD_END)
@perl ./tools/NVRAMStatistic/nvram_lid_check.pl ./tools/NVRAMStatistic/lid/$(PROJECT_NAME)/$(FLAVOR) $(strip $(PROJDIR))/nvram_auto_gen $(strip $(COMPLOGDIR))/nvram_lid_check.log /s NVRAM_OTA_SMART_RESET=$(NVRAM_OTA_SMART_RESET) >$(strip $(COMPLOGDIR))/nvram_lid_check.log 2>&1\
$(WITH) \
($(IF_ERR_TRUE) $(THEN) (echo Error: NVRAM LID CHECK failed.Please check $(strip $(COMPLOGDIR))/nvram_lid_check.log $(WITH) exit 1) $(CMD_END))
@$(ECHO) -n $(dir $@)cgen_preflow.det: tools/NVRAMStatistic/nvram_lid_check.pl >> $(dir $@)codegen.det
@$(ECHO) -n ==== NVRAM LID CHECK END ====
endif
ifeq ($(strip $(NV_CHKSUM_ENHANCE)),TRUE)
@$(ECHO) -n ==== NVRAM CHECKSUM ALGORITHM DOUBLE CHECK START ====
@$(IF_EXIST) $(strip $(PROJDIR))/nvram_auto_gen/MDDB.META.ODB.XML $(THEN) $(DEL_FILE) $(strip $(PROJDIR))/nvram_auto_gen/MDDB.META.ODB.XML $(CMD_END)
@python ./tools/NVRAMStatistic/nvram_checksum_algorithm_double_check.py ./tools/NVRAMStatistic/lid/$(PROJECT_NAME)/$(FLAVOR) $(strip $(PROJDIR))/nvram_auto_gen >> $(strip $(COMPLOGDIR))/nvram_gen_full_log.log 2>>$(strip $(COMPLOGDIR))/nvram_gen.log\
$(WITH) \
($(IF_ERR_TRUE) $(THEN) (echo Error: NVRAM LID CHECKSum Double check failed.Please check $(strip $(COMPLOGDIR))/nvram_gen.log $(WITH) exit 1) $(CMD_END))
@$(ECHO) -n $(dir $@)cgen_preflow.det: tools/NVRAMStatistic/nvram_checksum_algorithm_double_check.py >> $(dir $@)codegen.det
@$(ECHO) -n ==== NVRAM CHECKSUM ALGORITHM DOUBLE CHECK END ====
endif
ifeq ($(strip $(NVRAM_OTA_SMART_RESET)),TRUE)
@$(ECHO) -n ==== NVRAM POST GEN START ====
@perl ./tools/NVRAMStatistic/nvram_post_gen.pl $(strip $(PROJDIR))/nvram_auto_gen $(strip $(COMPLOGDIR))/nvram_post_gen.log >$(strip $(COMPLOGDIR))/nvram_post_gen.log 2>&1 $(WITH)\
($(IF_ERR_TRUE) $(THEN) (echo Error: NVRAM post gen failed. Please check $(strip $(COMPLOGDIR))/nvram_post_gen.log $(WITH) exit 1) $(CMD_END))
@$(ECHO) -n $(dir $@)cgen_preflow.det: tools/NVRAMStatistic/nvram_post_gen.pl >> $(dir $@)codegen.det
@$(ECHO) -n ==== NVRAM POST GEN END ====
endif
@$(IF_EXIST) $(MODISBUILD_TST_DB)/pstrace_db/ps_trace_1.h $(THEN) $(DEL_FILE) $(MODISBUILD_TST_DB)/pstrace_db/ps_trace_1.h $(CMD_END)
@$(IF_EXIST) $(MODISBUILD_TST_DB)/pstrace_db/ps_trace_2.h $(THEN) $(DEL_FILE) $(MODISBUILD_TST_DB)/pstrace_db/ps_trace_2.h $(CMD_END)
@$(IF_EXIST) $(MODISBUILD_TST_DB)/chk_cgen_step.ini $(THEN) $(DEL_FILE) $(MODISBUILD_TST_DB)/chk_cgen_step.ini $(CMD_END)
#gen nvram lid db database
ifeq ($(strip $(NVRAM_LID_DESC_CHECK)),TRUE)
@(python ./tools/NVRAMStatistic/nvram_gen_excel/nvram_monitor.py $(strip $(PROJDIR)) >> $(strip $(TARGDIR))/build.log)
endif
@$(ECHO) "$@ END TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: mcf_gen
# Generate MCF Db
# *************************************************************************
MCF_XML_LIST := $(wildcard ./custom/service/mcf/ota_files/MTK_OTA.xml)
ifeq ($(strip $(OS_VERSION)),MSWin32)
MCF_OTA_GEN = ".\tools\MCF\MCF_OTA_Gen\MCF_OTA_Gen.exe"
else
MCF_OTA_GEN = ./tools/MCF/MCF_OTA_Gen/MCF_OTA_Gen
endif
ifeq ($(strip $(MCF_OTA_NAME)),DEFAULT)
ifneq ($(strip $(MCF_OTA_DEFAULT_NAME)),)
MCF_OTA_NAME = $(strip $(MCF_OTA_DEFAULT_NAME))
endif
endif
mcf_gen: $(POSTGEN_DEP)/mcf_gen.det
ifeq ($(strip $(SMART_CHECK)),TRUE)
include $(wildcard $(POSTGEN_DEP)/./mcf_gen.det)
else
$(POSTGEN_DEP)/mcf_gen.det: FORCE
endif
$(POSTGEN_DEP)/mcf_gen.det:
ifeq ($(strip $(MCF_SUPPORT)),TRUE)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(ECHO) "$@ START TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
@$(IF_NOT_EXIST) $(strip $(POSTGEN_DEP)) $(THEN) ($(MKDIR) $(strip $(POSTGEN_DEP))) $(CMD_END)
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_postcgen.log
endif
@$(IF_NOT_EXIST) $(strip $(PROJDIR))/modem/mcf $(THEN) $(MKDIR) $(strip $(PROJDIR))/modem/mcf $(CMD_END)
@$(IF_EXIST) $(strip $(PROJDIR))/modem/mcf/new_item_found.txt $(THEN) $(DEL_FILE) $(strip $(PROJDIR))/modem/mcf/new_item_found.txt $(CMD_END)
@$(ECHO) -n ==== MCF GEN START ====
ifeq ($(strip $(OS_VERSION)),MSWin32)
@".\tools\MCF\mcf_parser_gen.exe" codegen $(MODISBUILD_TST_DB)/$(MDDBMETADATABASEXML) $(strip $(PROJDIR))/nvram_auto_gen/custom_nvram_lid_cat.xml ./custom/service/mcf/system_files/mcf_system.csv ./custom/service/mcf/system_files/branch.txt $(strip $(PROJDIR))/modem/mcf $(strip $(PROJDIR))/modem/mcf $(strip $(PROJDIR))/modem/mcf/MDDB.MCF.ODB.xml -n>>$(strip $(COMPLOGDIR))/mcf_parser_gen.log $(WITH)\
$(IF_ERR_TRUE) $(THEN) (echo Error: mcf_parser_gen error. Please check $(strip $(COMPLOGDIR))/mcf_parser_gen.log $(WITH) exit 1) $(CMD_END)
else
@./tools/MCF/mcf_parser_gen codegen $(MODISBUILD_TST_DB)/$(MDDBMETADATABASEXML) $(strip $(PROJDIR))/nvram_auto_gen/custom_nvram_lid_cat.xml ./custom/service/mcf/system_files/mcf_system.csv ./custom/service/mcf/system_files/branch.txt $(strip $(PROJDIR))/modem/mcf $(strip $(PROJDIR))/modem/mcf $(strip $(PROJDIR))/modem/mcf/MDDB.MCF.ODB.xml -n>>$(strip $(COMPLOGDIR))/mcf_parser_gen.log $(WITH) \
$(IF_ERR_TRUE) $(THEN) (echo Error: mcf_gen mcf_parser_gen error. Please check $(strip $(COMPLOGDIR))/mcf_parser_gen.log | tee -a $(strip $(COMPLOGDIR))/mcf_parser_gen.log $(WITH) exit 1) $(CMD_END)
endif
@$(IF_NOT_EXIST) $(strip $(PROJDIR))/modem/mcf/all_ota_files $(THEN) $(MKDIR) $(strip $(PROJDIR))/modem/mcf/all_ota_files $(CMD_END)
@$(IF_NOT_EXIST) $(strip $(PROJDIR))/modem/mcf/flavor_ota_files $(THEN) $(MKDIR) $(strip $(PROJDIR))/modem/mcf/flavor_ota_files $(CMD_END)
@$(ECHO) -n Start to build all MCF OTA files > $(strip $(COMPLOGDIR))/mcf_ota_gen.log
@$(FOR) $(DECLARE_VAR)i $(IN) $(MCF_XML_LIST) $(DO) \
$(ECHO) -n Build $(PRE_VAR)i >> $(strip $(COMPLOGDIR))/mcf_ota_gen.log $(WITH) \
$(MCF_OTA_GEN) -d $(strip $(PROJDIR))/modem/mcf/MDDB.MCF.ODB.xml -i $(PRE_VAR)i -o $(strip $(PROJDIR))/modem/mcf/all_ota_files >>$(strip $(COMPLOGDIR))/mcf_ota_gen.log $(WITH) \
$(IF_ERR_TRUE) $(THEN) (echo Error: mcf_ota_gen error. Please check $(strip $(COMPLOGDIR))/mcf_ota_gen.log $(WITH) exit 1) $(CMD_END) \
$(DONE)
ifneq ($(strip $(MTK_OTA_LIST)),NONE)
@$(ECHO) -n Start to build flavor MCF OTA files >> $(strip $(COMPLOGDIR))/mcf_ota_gen.log
@$(FOR) $(DECLARE_VAR)i $(IN) $(MTK_OTA_LIST) $(DO) \
$(ECHO) -n Build ./custom/service/mcf/ota_files/$(PRE_VAR)i >> $(strip $(COMPLOGDIR))/mcf_ota_gen.log $(WITH) \
$(MCF_OTA_GEN) -d $(strip $(PROJDIR))/modem/mcf/MDDB.MCF.ODB.xml -i ./custom/service/mcf/ota_files/$(PRE_VAR)i.xml -o $(strip $(PROJDIR))/modem/mcf/flavor_ota_files >>$(strip $(COMPLOGDIR))/mcf_ota_gen.log $(WITH) \
$(IF_ERR_TRUE) $(THEN) (echo Error: mcf_ota_gen error. Please check $(strip $(COMPLOGDIR))/mcf_ota_gen.log $(WITH) exit 1) $(CMD_END) \
$(DONE)
endif
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
@$(IF_EXIST) $(strip $(PROJDIR))/modem/mcf/all_ota_files $(THEN) \
(($(COPY_FILE) ./custom/service/mcf/ota_files/* $(strip $(PROJDIR))/modem/mcf/all_ota_files > $(strip $(COMPLOGDIR))/tar_ota_file.log 2>&1) \
$(WITH) \
($(COPY_FILE) $(strip $(PROJDIR))/modem/mcf/flavor_ota_files/* $(strip $(PROJDIR))/modem/mcf/all_ota_files > $(strip $(COMPLOGDIR))/tar_ota_file.log 2>&1) \
$(WITH) \
(perl ./tools/MCF/modify_ota_config.pl $(strip $(PROJDIR))/modem/mcf/all_ota_files/MTK_MD_OTA_CONFIG.ini $(strip $(MCF_OTA_NAME)) > $(strip $(COMPLOGDIR))/tar_ota_file.log 2>&1) \
$(WITH) \
(tar -zcv -f $(strip $(TARGDIR))/MCF_OTA_FILES.tar.gz -C $(strip $(PROJDIR))/modem/mcf/all_ota_files . > $(strip $(COMPLOGDIR))/tar_ota_file.log 2>&1) \
$(WITH) \
($(IF_ERR_TRUE) $(THEN) (echo Error: mcf_gen pack ota files failed. Please check $(strip $(COMPLOGDIR))/tar_ota_file.log | tee -a $(strip $(COMPLOGDIR))/tar_ota_file.log $(WITH) exit 1) $(CMD_END))) \
$(CMD_END)
@$(IF_EXIST) $(strip $(PROJDIR))/modem/mcf/MDDB.MCF.ODB.xml $(THEN) \
((tar -zcvf $(strip $(TARGDIR))/MDDB.MCF.ODB.tar.gz -C $(strip $(PROJDIR))/modem/mcf/ MDDB.MCF.ODB.xml > $(strip $(COMPLOGDIR))/tar_mcf_db.log 2>&1) \
$(WITH) \
($(IF_ERR_TRUE) $(THEN) (echo Error: mcf_gen pack mcf db failed. Please check $(strip $(COMPLOGDIR))/tar_mcf_db.log | tee -a $(strip $(COMPLOGDIR))/tar_mcf_db.log $(WITH) exit 1) $(CMD_END))) \
$(CMD_END)
ifeq ($(strip $(MCF_DIFF_CHECK)),TRUE)
@$(IF_EXIST) $(strip $(PROJDIR))/modem/mcf/new_item_found.txt $(THEN) \
((echo Error: MCF diff check error. >> $(strip $(COMPLOGDIR))/mcf_diff_check.log) \
$(WITH) ($(CAT) ./tools/MCF/new_var_found_guideline.txt >> $(strip $(COMPLOGDIR))/mcf_diff_check.log) \
$(WITH) ($(CAT) $(strip $(PROJDIR))/modem/mcf/new_item_found.txt >> $(strip $(COMPLOGDIR))/mcf_diff_check.log) \
$(WITH) (echo MCF diff check end. >> $(strip $(COMPLOGDIR))/mcf_diff_check.log) \
$(WITH) (echo MCF diff check error. Please check $(strip $(COMPLOGDIR))/mcf_diff_check.log) \
$(WITH) (exit 1)) \
$(CMD_END)
endif
else
@$(IF_EXIST) $(strip $(PROJDIR))/modem/mcf/all_ota_files $(THEN) \
(($(IF_NOT_EXIST) $(strip $(MODISPROJDIR))/WIN32FS/mdota $(THEN) $(MKDIR) $(strip $(MODISPROJDIR))/WIN32FS/mdota $(CMD_END)) \
$(WITH) \
($(COPY_FILE) ./custom/service/mcf/ota_files/* $(strip $(PROJDIR))/modem/mcf/all_ota_files > $(strip $(COMPLOGDIR))/tar_ota_file.log 2>&1) \
$(WITH) \
(perl ./tools/MCF/modify_ota_config.pl $(strip $(PROJDIR))/modem/mcf/all_ota_files/MTK_MD_OTA_CONFIG.ini $(strip $(MCF_OTA_NAME)) > $(strip $(COMPLOGDIR))/tar_ota_file.log 2>&1) \
$(WITH) \
($(COPY_FILE) $(strip $(PROJDIR))/modem/mcf/all_ota_files/* $(strip $(MODISPROJDIR))/WIN32FS/mdota > $(strip $(COMPLOGDIR))/tar_ota_file.log 2>&1) \
$(WITH) \
($(COPY_FILE) $(strip $(PROJDIR))/modem/mcf/flavor_ota_files/* $(strip $(MODISPROJDIR))/WIN32FS/mdota > $(strip $(COMPLOGDIR))/tar_ota_file.log 2>&1)) \
$(CMD_END)
endif
@$(ECHO) -n "$@: $(MODISBUILD_TST_DB)/$(MDDBMETADATABASEXML)" >> $@
@$(ECHO) -n "$@: $(strip $(PROJDIR))/nvram_auto_gen/custom_nvram_lid_cat.xml" >> $@
@$(ECHO) -n "$@: custom/service/mcf/system_files/mcf_system.csv" >> $@
@$(ECHO) -n "$@: custom/service/mcf/system_files/branch.txt" >> $@
@$(ECHO) -n "$@: tools/MCF/mcf_parser_gen" >> $@
@$(ECHO) -n ==== MCF GEN END ====
ifneq ($(strip $(OS_VERSION)),MSWin32)
#delete target file for cleaning legacy code
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
@$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common >>$(strip $(COMPLOGDIR))/genJson.log 2>&1 $(WITH) \
($(IF_ERR_TRUE) $(THEN) \
((echo Error: the command is \"$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common\") $(AND) \
echo Error: Failed in tools/genTargetFile.py at $@. Please check $(strip $(COMPLOGDIR))/genJson.log !$(WITH) exit 1) \
$(CMD_END))
endif
@$(ECHO) "$@ END TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
endif # MCF_SUPPORT
# *************************************************************************
# TARGET: cleancodegen
# Clean Generated Code Sources
# *************************************************************************
cleancodegen:
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(ECHO) "$@ START TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
ifneq ($(strip $(SMART_CHECK)),TRUE)
ifneq ($(strip $(AUTO_CHECK_DEPEND)),TRUE)
@$(ECHO) -n clean codegen list
# $(CODE_GEN_LST) should be copied to another place then delete
@$(IF_EXIST) $(CODE_GEN_LST) $(THEN)\
(($(COPY_FILE) $(CODE_GEN_LST) $(strip $(TMPDIR))/~codegenlis.tmp >$(DEV_NUL)) $(AND) \
($(FOR) $(F_OPT) $(DECLARE_VAR)i $(IN) `$(CAT) $(CODE_GEN_LST)` $(DO) \
($(IF_EXIST) $(PRE_VAR)i $(THEN) $(DEL_FILE) $(PRE_VAR)i $(CMD_END)) \
$(DONE)) $(WITH) \
($(DEL_FILE) $(CODE_GEN_LST))) \
$(CMD_END)
ifeq ($(strip $(MODIS_CONFIG)),TRUE)
@$(IF_EXIST) $(strip ${CODEGEN_DEP}) $(THEN) $(DEL_DIR) $(strip ${CODEGEN_DEP}) $(CMD_END)
@$(IF_NOT_EXIST) $(strip ${CODEGEN_DEP}) $(THEN) $(MKDIR) $(strip ${CODEGEN_DEP}) $(CMD_END)
endif
endif
endif
@$(ECHO) "$@ END TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# Target: sysgen_init
# Copy custom files to build folder
# *************************************************************************
sysgen_init: $(PREGEN_DEP)/sysgen_init.det
ifeq ($(strip $(SMART_CHECK)),TRUE)
include $(wildcard $(PREGEN_DEP)/./sysgen_init.det)
else
$(PREGEN_DEP)/sysgen_init.det: FORCE
endif
$(PREGEN_DEP)/sysgen_init.det:
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
ifneq ($(strip $(DISABLE_SYS)),TRUE)
#backup custom/system files
ifneq ($(strip $(OS_VERSION)),MSWin32)
#can not remove system backup folder due to previously incremental build may fail at autogen steps.
# @$(IF_EXIST) $(strip $(PROJDIR))/custom/system_bak $(THEN) ($(DEL_DIR) $(strip $(PROJDIR))/custom/system_bak) $(CMD_END)
@$(IF_NOT_EXIST) $(strip $(PROJDIR))/custom/system_bak $(THEN) ($(MKDIR) $(strip $(PROJDIR))/custom/system_bak) $(CMD_END)
@($(LIST_DIR) "$(strip $(PROJDIR))/custom/system/*.*" 1>$(DEV_NUL) 2>&1 $(WITH) \
$(IF_ERR_FALSE) $(THEN) \
($(FOR) $(F_OPT) $(DECLARE_VAR)i $(IN) `$(LIST_DIR) -n -b "$(strip $(PROJDIR))/custom/system/*.*"` $(DO) \
(mv -f $(strip $(PROJDIR))/custom/system/$(PRE_VAR)i $(strip $(PROJDIR))/custom/system_bak/$(PRE_VAR)i) $(AND) \
(echo $(strip $(PROJDIR))/custom/system/$(PRE_VAR)i is moved to $(strip $(PROJDIR))/custom/system_bak/$(PRE_VAR)i!) \
$(DONE)) \
$(CMD_END))
endif
@perl ./tools/sysgen_init.pl $(call CUSTOM_FLD_MAPPING,./custom/system) $(strip $(BUILD_SYSDIR)) $(strip $(SMART_CHECK)) > $(strip $(COMPLOGDIR))/sysgen_init.log $(WITH) \
($(IF_ERR_TRUE) $(THEN) (echo Error: sysgen_init Failed. Please check $(strip $(COMPLOGDIR))/sysgen_init.log $(WITH) exit 1) $(CMD_END))
endif
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# Target: emigen
# Generate emi settings based on configurations in custom_MemoryDevice.h
# *************************************************************************
MEMORY_FILE := $(wildcard $(strip $(TMPDIR))/*.xls)
emigen: sysgen_init $(PREGEN_DEP)/emigen.det
ifeq ($(strip $(SMART_CHECK)),TRUE)
include $(wildcard $(PREGEN_DEP)/./emigen.det)
else
$(PREGEN_DEP)/emigen.det: FORCE
endif
$(PREGEN_DEP)/emigen.det:
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(ECHO) "$@ START TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
@$(IF_NOT_EXIST) $(strip $(PREGEN_DEP)) $(THEN) ($(MKDIR) $(strip $(PREGEN_DEP))) $(CMD_END)
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_precgen.log
endif
ifneq ($(MEMORY_FILE),)
@$(IF_EXIST) $(MEMORY_FILE) $(THEN) ($(DEL_FILE) $(MEMORY_FILE)) $(CMD_END)
endif
@$(IF_NOT_EXIST) $(COMPLOGDIR) $(THEN) ($(MKDIR) $(COMPLOGDIR)) $(CMD_END)
@$(ECHO) -n Generate EMI settings
@$(IF_EXIST) $(strip $(EMI_GENERATOR)) $(THEN) \
(perl $(strip $(EMI_GENERATOR)) FALSE $(strip $(MEMORY_DEVICE_HDR)) "$(strip $(PROJECT_MAKEFILE))" FALSE $(strip $(INSIDE_MTK)) $(strip $(TMPDIR)) $@ > $(strip $(COMPLOGDIR))/emigen.log 2>&1) $(WITH) \
($(IF_ERR_TRUE) $(THEN) (echo Error: emigen Failed. Please check $(strip $(COMPLOGDIR))/emigen.log $(WITH) exit 1) $(CMD_END)) \
$(CMD_END)
ifneq ($(strip $(OS_VERSION)),MSWin32)
#delete target file for cleaning legacy code
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
@$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common >> $(strip $(COMPLOGDIR))/genJson.log 2>&1 $(WITH) \
($(IF_ERR_TRUE) $(THEN) \
((echo Error: the command is \"$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common\") $(AND) \
echo Error: Failed in tools/genTargetFile.py at $@. Please check $(strip $(COMPLOGDIR))/genJson.log !$(WITH) exit 1) \
$(CMD_END))
endif
@$(ECHO) "$@ END TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# Target: copro_info_gen
# *************************************************************************
copro_info_gen: $(PREGEN_DEP)/copro_info_gen.det
ifeq ($(strip $(SMART_CHECK)),TRUE)
include $(wildcard $(PREGEN_DEP)/./copro_info_gen.det)
else
$(PREGEN_DEP)/copro_info_gen.det: FORCE
endif
$(PREGEN_DEP)/copro_info_gen.det:
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_NOT_EXIST) $(strip $(PREGEN_DEP)) $(THEN) ($(MKDIR) $(strip $(PREGEN_DEP))) $(CMD_END)
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_precgen.log
endif
@$(ECHO) -n "L1CORE_IMAGELAYOUT = $(L1CORE_SCATTERFILE)">$(strip $(TMPDIR))/~copro_info.tmp
@$(ECHO) -n "L1CORE_MAP = $(L1CORE_MAP_FILE)" >> $(strip $(TMPDIR))/~copro_info.tmp
@$(ECHO) -n "L1CORE_SYM = $(L1CORE_SYM_FILE)" >> $(strip $(TMPDIR))/~copro_info.tmp
@$(IF_EXIST) $(FIXPATH)/tools/copro_info_gen.pl $(THEN)\
(perl $(FIXPATH)/tools/copro_info_gen.pl $(FORCE_GEN) $(strip $(TMPDIR))/~copro_info.tmp "$(strip $(PROJECT_MAKEFILE))" $(strip $(INFOMAKELOG)) $(SINGLE_CORE) $@ > $(strip $(COMPLOGDIR))/copro_info_gen.log 2>&1) $(WITH) \
($(IF_ERR_TRUE) $(THEN) echo Error: copro_info_gen.pl failed. Please check $(strip $(COMPLOGDIR))/copro_info_gen.log $(WITH) exit 1 $(CMD_END)) \
$(CMD_END)
ifneq ($(strip $(OS_VERSION)),MSWin32)
@$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common >> $(strip $(COMPLOGDIR))/genJson.log 2>&1 $(WITH) \
($(IF_ERR_TRUE) $(THEN) \
((echo Error: the command is \"$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common\") $(AND) \
echo Error: Failed in tools/genTargetFile.py at $@. Please check $(strip $(COMPLOGDIR))/genJson.log !$(WITH) exit 1) \
$(CMD_END))
endif
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# Generate custom\system\BB\* base on makefile and EMI.h
# *************************************************************************
ifeq ($(strip $(MODIS_CONFIG)),TRUE)
sysgen: sys_auto_gen sys_mem_gen
else
sysgen: sys_auto_gen sys_mem_gen mertos_codegen
endif
sys_auto_gen: $(PREGEN_DEP)/sysgen_conf.det ckmemlayout
$(PREGEN_DEP)/sysgen_conf.det: genlog copro_info_gen emigen
ifeq ($(strip $(SMART_CHECK)),TRUE)
include $(wildcard $(PREGEN_DEP)/./sysgen_conf.det)
else
$(PREGEN_DEP)/sysgen_conf.det: FORCE
endif
$(PREGEN_DEP)/sysgen_conf.det:
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(ECHO) "$@ START TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
@$(IF_NOT_EXIST) $(strip $(PREGEN_DEP)) $(THEN) ($(MKDIR) $(strip $(PREGEN_DEP))) $(CMD_END)
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_precgen.log
endif
# use specific lds
ifeq ($(strip $(HARDCODE_LDS)),TRUE)
@$(IF_EXIST) $(FIXPATH)/$(SCATTERFILE_PATH)/$(USER_DEFINE_SCATTERFILE_SRC) $(THEN) \
$(COPY_FILE) $(SCATTERFILE_PATH)/$(USER_DEFINE_SCATTERFILE_SRC) $(SCATTERFILE) \
$(ELSE) \
(echo Error: no such lds file: $(FIXPATH)/$(SCATTERFILE_PATH)/$(USER_DEFINE_SCATTERFILE_SRC) $(WITH) exit 1) \
$(CMD_END)
endif
@$(IF_EXIST) $(FIXPATH)/tools/sys_auto_gen.pl $(THEN) \
((perl $(FIXPATH)/tools/sys_auto_gen.pl $(SCATTERFILE) $(BL_SCATTERFILE) "$(strip $(PROJECT_MAKEFILE))" $(strip $(BUILD_SYSDIR)) $(strip $(NEED_BUILD_BOOTLOADER)) $(strip $(INSIDE_MTK)) $(strip $(DUMMY_LIS)) $(strip $(INFOMAKELOG)) $(strip $(TMPDIR))/~copro_info.tmp $(LIBDIR_TEMP) $(strip $(CC)) $@ > $(strip $(COMPLOGDIR))/sysgen.log) \
$(WITH) \
($(IF_ERR_TRUE) $(THEN) (echo Error: sys_auto_gen Failed. Please check $(strip $(COMPLOGDIR))/sysgen.log $(WITH) exit 1) $(CMD_END))) \
$(CMD_END)
@$(ECHO) "$@ END TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# Calculate system memory size and generate header files
# *************************************************************************
sys_mem_gen:
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
sys_mem_gen: genlog
endif
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_EXIST) $(strip $(TMPDIR))/~config_optInc.tmp $(THEN) ($(DEL_FILE) $(strip $(TMPDIR))/~config_optInc.tmp) $(CMD_END)
@$(IF_EXIST) $(strip $(TMPDIR))/~config_Option.tmp $(THEN) ($(DEL_FILE) $(strip $(TMPDIR))/~config_Option.tmp) $(CMD_END)
@$(MAKE) -fmake/common/build.mak -r -R --no-print-directory --old-file=genlog MODIS_CONFIG=$(strip $(MODIS_CONFIG)) MODIS_UESIM=$(strip $(MODIS_UESIM)) ALL_MODULELIS=config.lis genmoduleinfo
ifeq ($(strip $(MODIS_CONFIG)),TRUE)
@$(ECHO) -n System memory calculation for $(strip $(MODIS_UESIM))>$(strip $(MODISLOGDIR))/syscomp.log
else
@$(ECHO) -n System memory calculation for Target>$(strip $(COMPLOGDIR))/syscomp.log
@$(STRCMPEX) inc inc e $(strip $(TMPDIR))/~config_optInc.tmp $(foreach inc,$(subst \,/,$(COMMINCDIRS)),-I$(inc))
@$(STRCMPEX) def def e $(strip $(TMPDIR))/~config_opt.tmp $(foreach def,$(COM_DEFS),-D$(def))
@$(CAT) $(strip $(TMPDIR))/~config_opt.tmp >> $(strip $(TMPDIR))/~config_optInc.tmp
endif
@$(ECHO) -n -D__SYS_MEM_GEN__ >> $(strip $(TMPDIR))/~config_optInc.tmp
ifeq ($(strip $(OS_VERSION)),MSWin32)
@$(IF_EXIST) $(strip $(MODULEINFODIR))/config $(THEN)\
($(FOR) $(F_OPT) $(DECLARE_VAR)i $(IN) `$(CAT) $(strip $(MODULEINFODIR))/config/config.def ` \
$(DO)\
(echo ^#define $(PRE_VAR)i >>$(strip $(TMPDIR))/~config_Option.tmp) $(DONE)) $(WITH) \
(perl ./tools/replace_string.pl $(strip $(TMPDIR))/~config_Option.tmp = " " $(strip $(TMPDIR))/~config_Option.tmp) $(WITH) \
($(FOR) $(F_OPT) $(DECLARE_VAR)i $(IN) `$(CAT) $(strip $(MODULEINFODIR))/config/config.inc ` \
$(DO)\
(echo -I$(PRE_VAR)i >>$(strip $(TMPDIR))/~config_optInc.tmp) $(DONE)) \
$(CMD_END)
else
@$(IF_EXIST) $(strip $(MODULEINFODIR))/config $(THEN)\
($(FOR) $(F_OPT) $(DECLARE_VAR)i $(IN) `$(CAT) $(strip $(MODULEINFODIR))/config/config.def ` \
$(DO)\
(echo -D$(PRE_VAR)i >>$(strip $(TMPDIR))/~config_optInc.tmp) $(DONE)) $(WITH) \
($(FOR) $(F_OPT) $(DECLARE_VAR)i $(IN) `$(CAT) $(strip $(MODULEINFODIR))/config/config.inc ` \
$(DO)\
(echo -I$(PRE_VAR)i >>$(strip $(TMPDIR))/~config_optInc.tmp) $(DONE)) \
$(CMD_END)
endif
#backup syscomp_config for incremental build
ifneq ($(strip $(OS_VERSION)),MSWin32)
@$(IF_EXIST) $(strip $(TMPDIR))/~syscomp_config.o $(THEN) mv $(strip $(TMPDIR))/~syscomp_config.o $(strip $(TMPDIR))/~syscomp_config_bak.o >$(DEV_NUL) $(CMD_END)
endif
ifeq ($(strip $(OS_VERSION)),MSWin32)
@$(IF_EXIST) ./service/config/src/hal/syscomp_config.c $(THEN)\
($(CC) $(VIA)$(strip $(TMPDIR))/~config_optInc.tmp -imacros $(strip $(TMPDIR))/~config_Option.tmp -c ./service/config/src/hal/syscomp_config.c -o $(strip $(TMPDIR))/~syscomp_config.o 2>$(strip $(MODISLOGDIR))/sys_mem_gen.log $(AND) \
(perl ./tools/sys_mem_gen/sys_mem_gen.pl $(strip $(TMPDIR))/~syscomp_config.o $(strip $(BUILD_SYSDIR)) $(MODIS_CONFIG) $(strip $(MODISLOGDIR)) $(INFOMAKELOG) "$(CROSS)" $(strip $(MTK_MODEM_ARCH)) >>$(strip $(MODISLOGDIR))/sys_mem_gen.log $(WITH) \
$(IF_ERR_TRUE) $(THEN) (echo Error: System memory calculation failed. Please check $(strip $(MODISLOGDIR))/sys_mem_gen.log $(WITH) exit 1) $(CMD_END))) \
$(CMD_END)
else
ifeq ($(strip $(COMPILER_ARCH)),MIPS)
@$(ECHO) -EL -fshort-enums >> $(strip $(TMPDIR))/~config_optInc.tmp
endif
@$(IF_EXIST) ./service/config/src/hal/syscomp_config.c $(THEN)\
($(CC) $(VIA)$(strip $(TMPDIR))/~config_optInc.tmp -c ./service/config/src/hal/syscomp_config.c -o $(strip $(TMPDIR))/~syscomp_config.o 2>$(strip $(COMPLOGDIR))/sys_mem_gen.log $(AND) \
(perl ./tools/sys_mem_gen/sys_mem_gen.pl $(strip $(TMPDIR))/~syscomp_config.o $(strip $(BUILD_SYSDIR)) $(MODIS_CONFIG) $(strip $(COMPLOGDIR)) $(INFOMAKELOG) "$(CROSS)" $(strip $(MTK_MODEM_ARCH)) >>$(strip $(COMPLOGDIR))/sys_mem_gen.log $(WITH) \
$(IF_ERR_TRUE) $(THEN) (echo Error: System memory calculation failed. Please check $(strip $(COMPLOGDIR))/sys_mem_gen.log $(WITH) exit 1) $(CMD_END))) \
$(CMD_END)
ifneq ($(strip $(CUSTOM_RELEASE)),TRUE)
ifneq ($(strip $(MODIS_CONFIG)),TRUE)
ifeq ($(filter CHIP10992,$(strip $(COM_DEFS))),)
@python ./tools/kal_config/kal_config_irq_info_parser.py $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(MTK_MODEM_ARCH)) $(strip $(PLATFORM)) > $(strip $(COMPLOGDIR))/irq_config_table.csv 2>$(strip $(COMPLOGDIR))/irq_config_table.log $(WITH) \
$(IF_ERR_TRUE) $(THEN) (echo Error: Generate IRQ configuration table failed. Please check $(strip $(COMPLOGDIR))/irq_config_table.log $(WITH) exit 1) $(CMD_END)
else
@python ./tools/kal_config/kal_config_irq_info_parser.py $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(MTK_MODEM_ARCH)) $(strip CHIP10992) > $(strip $(COMPLOGDIR))/irq_config_table.csv 2>$(strip $(COMPLOGDIR))/irq_config_table.log $(WITH) \
$(IF_ERR_TRUE) $(THEN) (echo Error: Generate IRQ configuration table failed. Please check $(strip $(COMPLOGDIR))/irq_config_table.log $(WITH) exit 1) $(CMD_END)
endif
endif
endif
endif
ifneq ($(strip $(OS_VERSION)),MSWin32)
@$(IF_EXIST) $(strip $(TMPDIR))/~syscomp_config_bak.o $(THEN) \
(($(COMPARE) $(strip $(TMPDIR))/~syscomp_config.o $(strip $(TMPDIR))/~syscomp_config_bak.o >$(DEV_NUL) 2>&1) $(WITH) \
($(IF_ERR_FALSE) $(THEN) \
(touch -r $(strip $(TMPDIR))/~syscomp_config_bak.o $(strip $(TMPDIR))/~syscomp_config.o >$(DEV_NUL)) $(AND) \
(echo $(strip $(TMPDIR))/~syscomp_config.o timestamp is changed from $(strip $(TMPDIR))/~syscomp_config_bak.o!) \
$(CMD_END))) $(AND) \
($(DEL_FILE) $(strip $(TMPDIR))/~syscomp_config_bak.o) \
$(CMD_END)
endif
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# Generate codes required by MERTOS
# *************************************************************************
mertos_codegen: sys_mem_gen $(PREGEN_DEP)/mertos_codegen.det
ifeq ($(strip $(SMART_CHECK)),TRUE)
include $(wildcard $(PREGEN_DEP)/./mertos_codegen.det)
else
$(PREGEN_DEP)/mertos_codegen.det: FORCE
endif
$(PREGEN_DEP)/mertos_codegen.det:
ifeq ($(strip $(RTOS)),MERTOS)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(ECHO) "$@ START TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
@$(IF_NOT_EXIST) $(strip $(PREGEN_DEP)) $(THEN) ($(MKDIR) $(strip $(PREGEN_DEP))) $(CMD_END)
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_precgen.log
endif
@$(IF_NOT_EXIST) $(strip $(PREGEN_DEP)) $(THEN) ($(MKDIR) $(strip $(PREGEN_DEP))) $(CMD_END)
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
@$(IF_NOT_EXIST) $(COMPLOGDIR) $(THEN) ($(MKDIR) $(COMPLOGDIR)) $(CMD_END)
# Body Start
@$(ECHO) -n Generating MERTOS required information ...
# Execute codegen script; reuse the ~syscomp_config.o generated in sys_mem_gen
@$(ECHO) -n python ./tools/mertos/mer_codegen.py $(strip $(CROSS))readelf $(strip $(TMPDIR))/~syscomp_config.o $(strip $(BUILD_SYSDIR)) > $(strip $(COMPLOGDIR))/mertos_codegen.log
@(python ./tools/mertos/mer_codegen.py $(strip $(CROSS))readelf $(strip $(TMPDIR))/~syscomp_config.o $(strip $(BUILD_SYSDIR)) >> $(strip $(COMPLOGDIR))/mertos_codegen.log 2>&1 $(WITH) \
$(IF_ERR_TRUE) $(THEN) (echo Error: mertos_codegen Failed. Please check $(strip $(COMPLOGDIR))/mertos_codegen.log $(WITH) exit 1) $(CMD_END))
# Body End
ifneq ($(strip $(OS_VERSION)),MSWin32)
@$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common >> $(strip $(COMPLOGDIR))/genJson.log 2>&1 $(WITH) \
($(IF_ERR_TRUE) $(THEN) \
((echo Error: the command is \"$(GEN_TARGET_FILE) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(DSP_PROJECT)) $(strip $(DSP_FLAVOR)) $(strip $(TARGET_MODIS_UESIM)) $@ $@ common\") $(AND) \
echo Error: Failed in tools/genTargetFile.py at $@. Please check $(strip $(COMPLOGDIR))/genJson.log !$(WITH) exit 1) \
$(CMD_END))
endif
@$(ECHO) "$@ END TIME=" >> $(strip $(TARGDIR))/build.log
@$(CHK_TIME) >> $(strip $(TARGDIR))/build.log
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
endif
# *************************************************************************
# *************************************************************************
# Target: gen_sfini
# *************************************************************************
gen_sfini: $(PREGEN_DEP)/gen_sfini.det
ifeq ($(strip $(SMART_CHECK)),TRUE)
include $(wildcard $(PREGEN_DEP)/./gen_sfini.det)
else
$(PREGEN_DEP)/gen_sfini.det: FORCE
endif
$(PREGEN_DEP)/gen_sfini.det:
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_NOT_EXIST) $(strip $(PREGEN_DEP)) $(THEN) ($(MKDIR) $(strip $(PREGEN_DEP))) $(CMD_END)
@$(IF_EXIST) $@ $(THEN) ($(DEL_FILE) $@) $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
# @$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_precgen.log
endif
@$(IF_EXIST) $(strip $(TARGDIR))/$(TARGNAME).lis $(THEN)\
(perl ./tools/MarginCalc.pl $(strip $(TARGDIR))/$(TARGNAME).lis >$(strip $(COMPLOGDIR))/MarginCalc.log 2>&1 $(WITH) \
($(IF_ERR_TRUE) $(THEN) (echo ./tools/MarginCalc.pl Error. Please check $(strip $(COMPLOGDIR))/MarginCalc.log $(WITH) exit 1) $(CMD_END)))\
$(CMD_END)
@$(IF_EXIST) $(strip $(COMPLOGDIR))/libs.log $(THEN) ($(DEL_FILE) $(strip $(COMPLOGDIR))/libs.log) $(CMD_END)
ifneq ($(strip $(CUSTOM_RELEASE)),TRUE)
@$(FOR) $(DECLARE_VAR)i $(IN) $(COMPLIST) $(DO) \
(echo $(strip $(COMPLIBDIR))/lib$(PRE_VAR)i.a >> $(strip $(COMPLOGDIR))/libs.log) \
$(DONE)
else
ifneq ($(strip $(MTK_LIBS)),)
@$(STRCMPEX) abc abc e $(strip $(COMPLOGDIR))/libs.log $(MTK_LIBS)
@perl ./tools/lnitem.pl $(strip $(COMPLOGDIR))/libs.log
endif
endif
@$(IF_EXIST) $(FIXPATH)/tools/libinfo.pl $(THEN) \
((perl $(FIXPATH)/tools/libinfo.pl $(strip $(COMPLOGDIR))/libs.log > $(strip $(COMPLOGDIR))/libinfo.log) \
$(WITH) \
($(IF_ERR_TRUE) $(THEN) (echo Error: ./tools/libinfo.pl Failed. Please check $(strip $(COMPLOGDIR))/libinfo.log $(WITH) exit 1) $(CMD_END))) \
$(CMD_END)
#Preprocess mt_config.h
@$(IF_EXIST) $(strip $(TMPDIR))/~mt_config_inc.tmp $(THEN) ($(DEL_FILE) $(strip $(TMPDIR))/~mt_config_inc.tmp) $(CMD_END)
@$(IF_EXIST) $(strip $(TMPDIR))/~mt_config_def.tmp $(THEN) ($(DEL_FILE) $(strip $(TMPDIR))/~mt_config_def.tmp) $(CMD_END)
@$(IF_EXIST) $(strip $(TMPDIR))/~mt_config.o $(THEN) ($(DEL_FILE) $(strip $(TMPDIR))/~mt_config.o) $(CMD_END)
@$(STRCMPEX) inc inc e $(strip $(TMPDIR))/~mt_config_inc.tmp $(foreach inc,$(XGEN_INC_DIR),-I$(inc))
@$(STRCMPEX) def def e $(strip $(TMPDIR))/~mt_config_def.tmp $(foreach def,$(COM_DEFS_TARGET),-D$(def))
@$(IF_EXIST) $(strip .)/interface/service/config/mt_config.h $(THEN) \
$(CC) -E -W $(VIA)$(strip $(TMPDIR))/~mt_config_inc.tmp $(VIA)$(strip $(TMPDIR))/~mt_config_def.tmp $(strip .)/interface/service/config/mt_config.h -o $(strip $(TMPDIR))/~mt_config.o > $(strip $(COMPLOGDIR))/mt_config.log $(WITH) \
($(IF_ERR_TRUE) $(THEN) (echo Error: Preprocess mt_config.h Failed. Please check $(strip $(COMPLOGDIR))/mt_config_info.log $(WITH) exit 1) $(CMD_END)) \
$(CMD_END)
ifeq ($(filter CHIP10992,$(strip $(COM_DEFS))),)
#MDProfilerMETAInfoGen
@$(IF_EXIST) $(strip $(TMPDIR))/~syscomp_config.o $(THEN) \
$(IF_EXIST) ./tools/MDProfilerMETAInfoGen/MDProfiler_META_info_gen.pl $(THEN) \
((perl ./tools/MDProfilerMETAInfoGen/MDProfiler_META_info_gen.pl $(strip $(TMPDIR))/~syscomp_config.o $(strip $(TMPDIR))/~mt_config.o $(strip $(MODISBUILD_TST_DB)) $(strip $(COMPLOGDIR)) $(strip $(PLATFORM)) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(VERNO)) $(strip $(MD_VER_FOLDER)) $(strip $(CROSS))) \
$(WITH) \
($(IF_ERR_TRUE) $(THEN) (echo Error: ./tools/MDProfilerMETAInfoGen/MDProfiler_META_info_gen.pl Failed. Please check $(strip $(COMPLOGDIR))/swla_meta_info.log $(WITH) exit 1) $(CMD_END))) \
$(CMD_END) \
$(CMD_END)
else
#MDProfilerMETAInfoGen
@$(IF_EXIST) $(strip $(TMPDIR))/~syscomp_config.o $(THEN) \
$(IF_EXIST) ./tools/MDProfilerMETAInfoGen/MDProfiler_META_info_gen.pl $(THEN) \
((perl ./tools/MDProfilerMETAInfoGen/MDProfiler_META_info_gen.pl $(strip $(TMPDIR))/~syscomp_config.o $(strip $(TMPDIR))/~mt_config.o $(strip $(MODISBUILD_TST_DB)) $(strip $(COMPLOGDIR)) $(strip CHIP10992) $(strip $(PROJECT_NAME)) $(strip $(FLAVOR)) $(strip $(VERNO)) $(strip $(MD_VER_FOLDER)) $(strip $(CROSS))) \
$(WITH) \
($(IF_ERR_TRUE) $(THEN) (echo Error: ./tools/MDProfilerMETAInfoGen/MDProfiler_META_info_gen.pl Failed. Please check $(strip $(COMPLOGDIR))/swla_meta_info.log $(WITH) exit 1) $(CMD_END))) \
$(CMD_END) \
$(CMD_END)
endif
@$(ECHO) -n $(strip $(INFOLOG)) > $(MODISBUILD_TST_DB)/sf.ini
@$(ECHO) -n $(strip "$(PROJECT_MAKEFILE)") >> $(MODISBUILD_TST_DB)/sf.ini
@$(ECHO) -n $(strip $(COMPLOGDIR))/emigen.log >> $(MODISBUILD_TST_DB)/sf.ini
@$(ECHO) -n $(strip $(COMPLOGDIR))/ckSysDrv.log >> $(MODISBUILD_TST_DB)/sf.ini
@$(ECHO) -n $(strip $(COMPLOGDIR))/drv_features_option.log >> $(MODISBUILD_TST_DB)/sf.ini
@$(ECHO) -n $(strip $(COMPLOGDIR))/MarginCalc.log >> $(MODISBUILD_TST_DB)/sf.ini
@$(ECHO) -n $(strip $(COMPLOGDIR))/libinfo.log >> $(MODISBUILD_TST_DB)/sf.ini
@$(ECHO) -n "<ICDJSONDef_0>$(strip $(PROJDIR))/modem/icd_ac_gen/ICDJSONDef_0.json" >> $(MODISBUILD_TST_DB)/sf.ini
@$(ECHO) -n "<ICDJSONDef_1>$(strip $(PROJDIR))/modem/icd_ac_gen/ICDJSONDef_1.json" >> $(MODISBUILD_TST_DB)/sf.ini
@$(ECHO) -n "<MCUFilter@ModLayerRATInfo>$(strip $(LOGGING_DATABASE))/XDD/module_layer_rat_info.txt" >> $(MODISBUILD_TST_DB)/sf.ini
ifeq ($(strip $(CUSTOM_RELEASE)),FALSE)
ifdef EUTRAN_MODE_SUPPORT
ifneq ($(strip $(EUTRAN_MODE_SUPPORT)),NONE)
ifeq ($(strip $(NO_LTECGEN)),FALSE)
ifeq ($(strip $(NO_DSP)),FALSE)
@$(ECHO) -n "<DSPXMLUtil@filterXML>$(DSPDIR)/$(strip $(DSP_PROJECT))/$(strip $(DSP_FLAVOR))/final_bin/xml/filterXML" >> $(MODISBUILD_TST_DB)/sf.ini
endif
endif
endif
endif
endif
@$(IF_EXIST) $(strip $(TMPDIR))/~syscomp_config.o $(THEN) \
($(ECHO) -n "<92SWLAMetaInfoFile>$(strip $(MODISBUILD_TST_DB))/MDProfiler_METAInfo.ini" >>$(MODISBUILD_TST_DB)/sf.ini) \
$(CMD_END)
ifneq ($(wildcard $(CUSTOMIZATION)/log2SD_Catcher_filters_meta.ini),)
ifneq ($(LOG2SD_CATCHER_FILTERS_LIST),)
@$(FOR) $(DECLARE_VAR)i $(IN) $(LOG2SD_CATCHER_FILTERS_LIST) $(DO) \
$(IF_EXIST) $(MODISBUILD_TST_DB)/catcher_filter_$(PRE_VAR)i.bin $(THEN) \
($(ECHO) -n "<catcher_filter@$(PRE_VAR)i>$(MODISBUILD_TST_DB)/catcher_filter_$(PRE_VAR)i.bin" >> $(MODISBUILD_TST_DB)/sf.ini) \
$(CMD_END) \
$(DONE)
endif
endif
# generate modem_list_filter for sf.ini
@$(IF_EXIST) $(MODISBUILD_TST_DB)/catcher_filter.bin $(THEN) \
($(ECHO) -n "<ModemDefaultFilter_catcher_filter_bin>$(MODISBUILD_TST_DB)/catcher_filter.bin" >> $(MODISBUILD_TST_DB)/sf.ini) \
$(CMD_END)
ifneq ($(LOG2SD_CATCHER_FILTERS_LIST),)
@$(FOR) $(DECLARE_VAR)i $(IN) $(LOG2SD_CATCHER_FILTERS_LIST) $(DO) \
$(IF_EXIST) $(MODISBUILD_TST_DB)/catcher_filter_$(PRE_VAR)i.bin $(THEN) \
($(ECHO) "<ModemDefaultFilter_catcher_filter_${PRE_VAR}i" >> $(MODISBUILD_TST_DB)/sf.ini) $(AND) \
($(ECHO) -n "_bin>$(MODISBUILD_TST_DB)/catcher_filter_$(PRE_VAR)i.bin" >> $(MODISBUILD_TST_DB)/sf.ini) \
$(CMD_END) \
$(DONE)
endif
#ifeq ($(strip $(SMART_CHECK)),TRUE)
# @$(ECHO) -n $@: $(strip $(INFOLOG)) >>$@
# @$(ECHO) -n "$@: $(strip $(PROJECT_MAKEFILE))" >> $@
# @$(ECHO) -n $@: $(MODISBUILD_TST_DB)/sf.ini >> $@
# @$(ECHO) -n $@: $(MAKE_COMMON)/codegen.mak >> $@
# @$(ECHO) -n $@: ./tools/MDProfilerMETAInfoGen/MDProfiler_META_info_gen.pl >> $@
#endif
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: gencustominfo
# Generate Custom Information
# *************************************************************************
gencustominfo:
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_EXIST) $(strip $(TARGDIR))/build.log $(THEN)\
($(ECHO) "$@ START TIME=" >>$(strip $(TARGDIR))/build.log $(AND) \
perl ./tools/time.pl -n >>$(strip $(TARGDIR))/build.log) \
$(CMD_END)
ifdef DRV_CUSTOM_TOOL_SUPPORT
ifeq ($(strip $(DRV_CUSTOM_TOOL_SUPPORT)),TRUE)
ifeq ($(findstring MT6129D,$(strip $(RF_MODULE))),)
ifeq ($(findstring MT6139E,$(strip $(RF_MODULE))),)
@$(IF_NOT_EXIST) $(BUILD_CODEGENDIR) $(THEN) ($(MKDIR) $(BUILD_CODEGENDIR)) $(CMD_END)
@$(IF) "$(strip $(DRV_CUSTOM_TOOL_SUPPORT))" $(EQU) "TRUE" $(THEN) \
($(IF_EXIST) $(DRV_GEN) $(THEN) \
($(IF_EXIST) $(call CUSTOM_FLD_MAPPING, custom/driver/drv_gen)/codegen.dws $(THEN) \
($(DRV_GEN) $(call CUSTOM_FLD_MAPPING,./custom/driver/drv_gen)/codegen.dws $(strip $(BUILD_CODEGENDIR)) $(strip $(PROJDIR))) \
$(CMD_END)) \
$(CMD_END)) \
$(CMD_END)
endif
endif
endif
endif
@$(IF_EXIST) $(strip $(TARGDIR))/build.log $(THEN)\
($(ECHO) "$@ END TIME=" >> $(strip $(TARGDIR))/build.log $(AND) \
perl ./tools/time.pl -n >> $(strip $(TARGDIR))/build.log) $(CMD_END)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
# *************************************************************************
# TARGET: $(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det: FORCE
# *************************************************************************
ifneq ($(strip $(AUTO_CHECK_CGEN)),TRUE)
$(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det: FORCE
endif
$(MODIS_RULESDIR)/codegen_dep/cgen_db_sig.det: $(NEED_CHECK_DEPEND_LIST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_S,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif
@$(IF_EXIST) $@ $(THEN) $(DEL_FILE) $@ $(CMD_END)
ifeq ($(strip $(SMART_CHECK)),TRUE)
@$(ECHO) -n "[SMART LOG] $@ target is triggered by: $?" >> $(strip $(COMPLOGDIR))/smart_log_cgen.log
endif
@$(IF_NOT_EXIST) $(BUILD_TSTDIR)/src $(THEN) ($(MKDIR) $(BUILD_TSTDIR)/src) $(CMD_END)
@$(ECHO) -n "Generate dbSig File ......"
@$(IF_EXIST) $(MODISBUILD_TST_DB)/chk_cgen_step.ini $(THEN) \
($(ECHO) -n "$(CGEN) -db_sig $(CODEGEN_DATABASE_OUT) $(BUILD_TSTDIR)/src/dbSig.c " >> $(CGEN_CFG_MODEM)) \
$(ELSE) \
($(ECHO) -n "$(CGEN) -rdb_sig $(CODEGEN_DATABASE_OUT) $(BUILD_TSTDIR)/src/dbSig.c " >> $(CGEN_CFG_MODEM)) \
$(CMD_END)
@$(ECHO) -n $@: $(CGEN) >> $@
@$(ECHO) -n $@ >> $(CODE_GEN_LST)
# mbis time probe
ifeq ($(strip $(MBIS_EN)),TRUE)
@$(ECHO) -n -t "T_E,$@,T," >> $(MBIS_BUILD_TIME_TMP)
endif