# /***************************************************************************** | |
#* °æÈ¨ËùÓÐ(C) 2013 ÖÐÐËͨѶ¹É·ÝÓÐÏÞ¹«Ë¾ | |
#* | |
#* ÎļþÃû³Æ: Makefile | |
#* Îļþ±êʶ: plat_mk | |
#* ÄÚÈÝÕªÒª: ±àÒëÖ§³Åƽ̨×Óϵͳ | |
#* ʹÓ÷½·¨: | |
#* | |
#* ÐÞ¸ÄÈÕÆÚ °æ±¾ºÅ Ð޸ıê¼Ç ÐÞ¸ÄÈË ÐÞ¸ÄÄÚÈÝ | |
#* ----------------------------------------------------------------------------- | |
#* 2013/01/01 V1.0 001 P98G ´´½¨ | |
#* | |
# *****************************************************************************/ | |
include $(PRJ_PATH)/config/project.mk | |
.PHONY : | |
default: help | |
lib: zplat | |
clean: zplatclean | |
#=============================================================================== | |
#help | |
#=============================================================================== | |
help: | |
@$(ECHO) "============Make help=====================================" | |
@$(ECHO) "make [help] help" | |
@$(ECHO) "make zplat[clean] compile all moudle" | |
@$(ECHO) "" | |
@$(ECHO) "make oss[clean/help] make oss subsystem" | |
@$(ECHO) "make drv[clean/help] make drv subsystem" | |
@$(ECHO) "" | |
@$(ECHO) "============Env============================================" | |
@$(ECHO) "FLAVOR =$(FLAVOR)" | |
@$(ECHO) "COMPILER =$(COMPILER)" | |
@$(ECHO) "OSTYPE =$(OSTYPE)" | |
@$(ECHO) "VERBOSE =$(VERBOSE)" | |
@$(ECHO) "LINTCHK =$(LINTCHK)" | |
@$(ECHO) "HOST =$(HOST)" | |
#=============================================================================== | |
#ƽ̨±àÒë | |
#=============================================================================== | |
ifeq ($(USE_PLAT_OSS),yes) | |
PLAT_MODS += oss | |
PLAT_MODS_CLEAN += ossclean | |
endif | |
ifeq ($(USE_PLAT_MMP),yes) | |
PLAT_MODS += mmp | |
PLAT_MODS_CLEAN += mmpclean | |
endif | |
ifeq ($(USE_PLAT_MSP),yes) | |
PLAT_MODS += msp | |
PLAT_MODS_CLEAN += mspclean | |
endif | |
ifeq ($(USE_PLAT_WBT),yes) | |
PLAT_MODS += wbt | |
PLAT_MODS_CLEAN += wbtclean | |
endif | |
zplat: $(PLAT_MODS) | |
@$(ECHO) "--make plat done" | |
zplatclean: $(PLAT_MODS_CLEAN) wraplibclean | |
@$(ECHO) "--clean plat done" | |
#=============================================================================== | |
#OS×Óϵͳ±àÒë | |
#´Ë´¦²»ÄܲÉÓöàÏ̱߳àÒëMAKEOPTSÑ¡Ïî | |
#=============================================================================== | |
PLAT_OSS_PATH = $(PLAT_PATH)/src/oss | |
oss: | |
@$(GNUMAKE) --no-print-directory -C $(PLAT_OSS_PATH)/ws lib | |
ossclean: | |
@$(GNUMAKE) --no-print-directory -C $(PLAT_OSS_PATH)/ws clean | |
#=============================================================================== | |
# mmp | |
#=============================================================================== | |
PLAT_MMP_PATH = $(PLAT_PATH)/src/mmp | |
mmp: | |
@$(GNUMAKE) --no-print-directory -C $(PLAT_MMP_PATH)/ws lib | |
mmpclean: | |
@$(GNUMAKE) --no-print-directory -C $(PLAT_MMP_PATH)/ws clean | |
#=============================================================================== | |
# MSP×Óϵͳ±àÒë | |
#=============================================================================== | |
PLAT_MSP_PATH = $(PLAT_PATH)/src/msp | |
msp: | |
@$(ECHO) "---Compile msp" | |
@$(GNUMAKE) --no-print-directory -C $(PLAT_MSP_PATH)/ws lib | |
@$(COPY) --force $(PLAT_LIB_INTERNAL_PATH)/plat_msp.a $(PLAT_LIB_EXTERNAL_PATH) | |
mspclean: | |
@$(GNUMAKE) --no-print-directory -C $(PLAT_MSP_PATH)/ws clean | |
#=============================================================================== | |
# wbt×Óϵͳ±àÒë | |
#=============================================================================== | |
PLAT_WBT_PATH = $(PLAT_PATH)/src/test/wbt | |
wbt: | |
@$(ECHO) "--to build wbt" | |
@$(GNUMAKE) --no-print-directory -C $(PLAT_WBT_PATH)/ws lib | |
@$(COPY) --force $(PLAT_LIB_INTERNAL_PATH)/plat_wbt.a $(PLAT_LIB_EXTERNAL_PATH) | |
wbtclean: | |
@$(ECHO) "--to clean wbt" | |
@$(GNUMAKE) --no-print-directory -C $(PLAT_WBT_PATH)/ws clean | |
#=============================================================================== | |
#´ò°ü×ÓÄ£¿éµÄ.a¿â | |
#=============================================================================== | |
wraplib: | |
@$(COPY) --force $(FINAL_LIB_TO_WARP) $(PLAT_LIB_EXTERNAL_PATH) | |
# @$(AR) $(ARFLAGS) $(PLAT_PATH)/lib/$(PRJ_NAME)/$(FLAVOR)/plat.a $(FINAL_LIB_TO_WARP) | |
wraplibclean: | |
@$(RM) -rf $(PLAT_LIB_INTERNAL_PATH) | |
@$(RM) -rf $(PLAT_LIB_EXTERNAL_PATH)/*.a |