2013-12-11 06:51:26 -08:00
|
|
|
COMMON_SRCDIR=codec/common
|
|
|
|
COMMON_CPP_SRCS=\
|
2014-04-17 10:43:10 +08:00
|
|
|
$(COMMON_SRCDIR)/src/copy_mb.cpp\
|
2014-03-18 19:41:32 -07:00
|
|
|
$(COMMON_SRCDIR)/src/cpu.cpp\
|
|
|
|
$(COMMON_SRCDIR)/src/crt_util_safe_x.cpp\
|
|
|
|
$(COMMON_SRCDIR)/src/deblocking_common.cpp\
|
|
|
|
$(COMMON_SRCDIR)/src/logging.cpp\
|
2014-03-25 15:35:55 +08:00
|
|
|
$(COMMON_SRCDIR)/src/sad_common.cpp\
|
2014-03-18 19:41:32 -07:00
|
|
|
$(COMMON_SRCDIR)/src/WelsThreadLib.cpp\
|
2013-12-11 06:51:26 -08:00
|
|
|
|
2014-03-18 11:21:46 +02:00
|
|
|
COMMON_OBJS += $(COMMON_CPP_SRCS:.cpp=.$(OBJ))
|
2014-02-12 22:11:05 +02:00
|
|
|
|
2014-02-25 23:52:36 +02:00
|
|
|
ifeq ($(ASM_ARCH), x86)
|
2013-12-11 06:51:26 -08:00
|
|
|
COMMON_ASM_SRCS=\
|
2014-03-18 19:41:32 -07:00
|
|
|
$(COMMON_SRCDIR)/x86/cpuid.asm\
|
|
|
|
$(COMMON_SRCDIR)/x86/deblock.asm\
|
|
|
|
$(COMMON_SRCDIR)/x86/expand_picture.asm\
|
|
|
|
$(COMMON_SRCDIR)/x86/mb_copy.asm\
|
|
|
|
$(COMMON_SRCDIR)/x86/mc_chroma.asm\
|
|
|
|
$(COMMON_SRCDIR)/x86/mc_luma.asm\
|
|
|
|
$(COMMON_SRCDIR)/x86/satd_sad.asm\
|
|
|
|
$(COMMON_SRCDIR)/x86/vaa.asm\
|
2013-12-11 06:51:26 -08:00
|
|
|
|
2014-03-18 11:21:46 +02:00
|
|
|
COMMON_OBJS += $(COMMON_ASM_SRCS:.asm=.$(OBJ))
|
2013-12-11 06:51:26 -08:00
|
|
|
endif
|
|
|
|
|
2014-02-26 14:31:52 +02:00
|
|
|
ifeq ($(ASM_ARCH), arm)
|
2014-04-23 10:44:44 +03:00
|
|
|
COMMON_ASM_ARM_SRCS=\
|
2014-04-17 10:43:10 +08:00
|
|
|
$(COMMON_SRCDIR)/arm/copy_mb_neon.S\
|
2014-03-18 19:41:32 -07:00
|
|
|
$(COMMON_SRCDIR)/arm/deblocking_neon.S\
|
|
|
|
$(COMMON_SRCDIR)/arm/expand_picture_neon.S\
|
|
|
|
$(COMMON_SRCDIR)/arm/mc_neon.S\
|
2014-02-26 14:31:52 +02:00
|
|
|
|
2014-04-23 10:44:44 +03:00
|
|
|
COMMON_OBJS += $(COMMON_ASM_ARM_SRCS:.S=.$(OBJ))
|
2014-02-26 14:31:52 +02:00
|
|
|
endif
|
|
|
|
|
2014-04-23 10:51:39 +03:00
|
|
|
ifeq ($(ASM_ARCH), arm64)
|
|
|
|
COMMON_ASM_ARM64_SRCS=\
|
|
|
|
$(COMMON_SRCDIR)/arm64/expand_picture_aarch64_neon.S\
|
|
|
|
$(COMMON_SRCDIR)/arm64/mc_aarch64_neon.S\
|
|
|
|
|
|
|
|
COMMON_OBJS += $(COMMON_ASM_ARM64_SRCS:.S=.$(OBJ))
|
|
|
|
endif
|
|
|
|
|
2013-12-11 06:51:26 -08:00
|
|
|
OBJS += $(COMMON_OBJS)
|
2014-03-18 11:21:46 +02:00
|
|
|
$(COMMON_SRCDIR)/%.$(OBJ): $(COMMON_SRCDIR)/%.cpp
|
2014-01-30 11:32:51 +02:00
|
|
|
$(QUIET_CXX)$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(COMMON_CFLAGS) $(COMMON_INCLUDES) -c $(CXX_O) $<
|
2013-12-11 06:51:26 -08:00
|
|
|
|
2014-03-18 11:21:46 +02:00
|
|
|
$(COMMON_SRCDIR)/%.$(OBJ): $(COMMON_SRCDIR)/%.asm
|
2014-01-30 11:32:51 +02:00
|
|
|
$(QUIET_ASM)$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(COMMON_ASMFLAGS) $(COMMON_ASM_INCLUDES) -o $@ $<
|
2014-01-03 14:49:45 +08:00
|
|
|
|
2014-03-18 11:21:46 +02:00
|
|
|
$(COMMON_SRCDIR)/%.$(OBJ): $(COMMON_SRCDIR)/%.S
|
2014-02-26 14:31:52 +02:00
|
|
|
$(QUIET_CCAS)$(CCAS) $(CFLAGS) $(ASMFLAGS) $(INCLUDES) $(COMMON_CFLAGS) $(COMMON_INCLUDES) -c -o $@ $<
|
|
|
|
|
2013-12-11 06:51:26 -08:00
|
|
|
$(LIBPREFIX)common.$(LIBSUFFIX): $(COMMON_OBJS)
|
2014-01-30 11:32:51 +02:00
|
|
|
$(QUIET)rm -f $@
|
|
|
|
$(QUIET_AR)$(AR) $(AR_OPTS) $+
|
2013-12-11 06:51:26 -08:00
|
|
|
|
|
|
|
libraries: $(LIBPREFIX)common.$(LIBSUFFIX)
|
|
|
|
LIBRARIES += $(LIBPREFIX)common.$(LIBSUFFIX)
|