blob: fb5acd541d29538a187041936e245cdb7eb812fe [file] [log] [blame]
# /*****************************************************************************
#* °æÈ¨ËùÓÐ (C)2015, ÖÐÐËͨѶ¹É·ÝÓÐÏÞ¹«Ë¾¡£
#*
#* ÎļþÃû³Æ: Makefile
#* Îļþ±êʶ: Makefile
#* ÄÚÈÝÕªÒª: Makefile of ZTE librarys
#* ʹÓ÷½·¨: void
#*
#* ÐÞ¸ÄÈÕÆÚ °æ±¾ºÅ Ð޸ıê¼Ç ÐÞ¸ÄÈË ÐÞ¸ÄÄÚÈÝ
#* -----------------------------------------------------------------------------
#* 2019/09/25 V1.0 Create xxq ´´½¨
#*
# ******************************************************************************/
#*******************************************************************************
# include ZTE library makefile
#*******************************************************************************
include $(COMMON_MK)
#*******************************************************************************
# library
#*******************************************************************************
LIB_SHARED = libaudiomix.so
LIB_STATIC = libaudiomix.a
OBJS = mix.o mixtest.o
CFLAGS += -g
LDFLAGS += -lpthread
##############USER COMIZE END##################
CFLAGS += -I$(zte_lib_path)/libaudiomix/include
CFLAGS += -I$(STAGEDIR)/include
CFLAGS += -I$(APP_DIR)/include
CFLAGS += -fPIC
LDFLAGS_SHARED += -shared
#*******************************************************************************
# comp test app and
#*******************************************************************************
EXEC_mixtest = mixtest
#*******************************************************************************
# objects
#*******************************************************************************
mixtest_OBJECTS += mix.o mixtest.o
#########################for linux######################################
ifeq ($(V3PHONE_TYPE), K318)
CFLAGS += -D_USE_7520V3_PHONE_TYPE_K318
endif
ifeq ($(V3PHONE_TYPE), C31F)
CFLAGS += -D_USE_7520V3_PHONE_TYPE_C31F
endif
ifeq ($(V3PHONE_TYPE), XRSD)
CFLAGS += -D_USE_7520V3_PHONE_TYPE_XRSD
endif
ifeq ($(V3PHONE_TYPE), FWP)
CFLAGS += -D_USE_7520V3_PHONE_TYPE_FWP
endif
ifeq ($(V3PHONE_TYPE), WTWD)
CFLAGS += -D_USE_7520V3_PHONE_TYPE_WTWD
endif
CFLAGS += -I./include/
CFLAGS += -g -Werror=implicit-function-declaration
SHAREDFLAG := -shared -lc
LDLIBS += -L$(LIB_DIR)/libtinyalsa
LDLIBS += -ltinyalsa
all: $(LIB_STATIC) $(LIB_SHARED) $(EXEC_mixtest)
$(LIB_STATIC) : $(OBJS)
$(AR) rcs $(LIB_STATIC) $(OBJS)
$(LIB_SHARED): $(OBJS)
$(CC) $(LDFLAGS) $(LDFLAGS_SHARED) -o $@ $^
$(EXEC_mixtest): $(mixtest_OBJECTS)
$(CC) $(LDFLAGS) -o $@ $(mixtest_OBJECTS) -Wl,--start-group $(LDLIBS) -Wl,--end-group
clean:
rm -f $(mixtest_OBJECTS) $(lib_OBJECTS) $(LIB_SHARED) $(LIB_STATIC) $(EXEC_mixtest) *.elf *.gdb *.o core
romfs:
$(ROMFSINST) $(LIB_SHARED) /lib/$(LIB_SHARED)
cp -v $(EXEC_mixtest) $(APP_DIR)/test_tools/