2013-12-12 03:56:52 +01:00
|
|
|
CODEC_UNITTEST_PREFIX=CODEC_UNITTEST
|
|
|
|
CODEC_UNITTEST_SRCDIR=test
|
|
|
|
CODEC_UNITTEST_CPP_SRCS=\
|
2014-01-09 04:20:05 +01:00
|
|
|
$(CODEC_UNITTEST_SRCDIR)/./decoder_test.cpp\
|
|
|
|
$(CODEC_UNITTEST_SRCDIR)/./encoder_test.cpp\
|
2013-12-12 03:56:52 +01:00
|
|
|
$(CODEC_UNITTEST_SRCDIR)/./simple_test.cpp\
|
|
|
|
|
|
|
|
CODEC_UNITTEST_OBJS += $(CODEC_UNITTEST_CPP_SRCS:.cpp=.o)
|
|
|
|
ifeq ($(USE_ASM), Yes)
|
|
|
|
CODEC_UNITTEST_ASM_SRCS=\
|
|
|
|
|
|
|
|
CODEC_UNITTEST_OBJS += $(CODEC_UNITTEST_ASM_SRCS:.asm=.o)
|
|
|
|
endif
|
|
|
|
|
|
|
|
OBJS += $(CODEC_UNITTEST_OBJS)
|
2014-01-08 15:33:35 +01:00
|
|
|
$(CODEC_UNITTEST_SRCDIR)/%.o: $(CODEC_UNITTEST_SRCDIR)/%.cpp
|
|
|
|
$(CXX) $(CFLAGS) $(CXXFLAGS) $(INCLUDES) $(CODEC_UNITTEST_CFLAGS) $(CODEC_UNITTEST_INCLUDES) -c -o $@ $<
|
|
|
|
|
|
|
|
$(CODEC_UNITTEST_SRCDIR)/%.o: $(CODEC_UNITTEST_SRCDIR)/%.asm
|
|
|
|
$(ASM) $(ASMFLAGS) $(ASM_INCLUDES) $(CODEC_UNITTEST_ASMFLAGS) $(CODEC_UNITTEST_ASM_INCLUDES) -o $@ $<
|
2013-12-12 03:56:52 +01:00
|
|
|
|
2014-01-08 15:18:01 +01:00
|
|
|
codec_unittest: $(CODEC_UNITTEST_OBJS) $(LIBS) $(CODEC_UNITTEST_LIBS) $(CODEC_UNITTEST_DEPS)
|
2013-12-12 03:56:52 +01:00
|
|
|
$(CXX) -o $@ $(CODEC_UNITTEST_OBJS) $(CODEC_UNITTEST_LDFLAGS) $(CODEC_UNITTEST_LIBS) $(LDFLAGS) $(LIBS)
|
|
|
|
|
|
|
|
binaries: codec_unittest
|
|
|
|
BINARIES += codec_unittest
|