From 166aaa0c711b3666b6a0554b51efeab1a401f47c Mon Sep 17 00:00:00 2001 From: Richard Fuchs Date: Tue, 4 Jun 2019 09:08:24 -0400 Subject: [PATCH] fix compilation for with_transcoding=no closes #789 Change-Id: Ia0a50f77ae25b8af5e387d40b2b570285836e32d --- daemon/codec.c | 6 ++++-- t/Makefile | 12 ++++++++---- 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/daemon/codec.c b/daemon/codec.c index c88c90c0b..b1b606e47 100644 --- a/daemon/codec.c +++ b/daemon/codec.c @@ -15,9 +15,7 @@ #include "rtcp.h" #include "call_interfaces.h" #include "dtmf.h" -#include "resample.h" #include "dtmflib.h" -#include "dtmf_rx_fillin.h" @@ -57,6 +55,10 @@ static GList *__delete_receiver_codec(struct call_media *receiver, GList *link) #ifdef WITH_TRANSCODING +#include "resample.h" +#include "dtmf_rx_fillin.h" + + struct codec_ssrc_handler { struct ssrc_entry h; // must be first diff --git a/t/Makefile b/t/Makefile index 2b39a551e..1885435fe 100644 --- a/t/Makefile +++ b/t/Makefile @@ -56,13 +56,13 @@ LDLIBS+= -lhiredis LDLIBS+= $(shell mysql_config --libs) endif -SRCS= bitstr-test.c aes-crypt.c payload-tracker-test.c const_str_hash-test.strhash.c +SRCS= bitstr-test.c aes-crypt.c const_str_hash-test.strhash.c LIBSRCS= loglib.c auxlib.c str.c rtplib.c DAEMONSRCS= crypto.c ssrc.c aux.c rtp.c HASHSRCS= ifeq ($(with_transcoding),yes) -SRCS+= transcode-test.c test-dtmf-detect.c +SRCS+= transcode-test.c test-dtmf-detect.c payload-tracker-test.c ifeq ($(with_amr_tests),yes) SRCS+= amr-decode-test.c amr-encode-test.c endif @@ -84,9 +84,9 @@ include .depend .PHONY: all-tests unit-tests daemon-tests -TESTS= bitstr-test aes-crypt payload-tracker-test const_str_hash-test.strhash +TESTS= bitstr-test aes-crypt const_str_hash-test.strhash ifeq ($(with_transcoding),yes) -TESTS+= transcode-test test-dtmf-detect +TESTS+= transcode-test test-dtmf-detect payload-tracker-test ifeq ($(with_amr_tests),yes) TESTS+= amr-decode-test amr-encode-test endif @@ -94,7 +94,11 @@ endif ADD_CLEAN= tests-preload.so $(TESTS) +ifeq ($(with_transcoding),yes) all-tests: unit-tests daemon-tests +else +all-tests: unit-tests +endif true # override linking recipe from common.Makefile unit-tests: $(TESTS)