mirror of
https://github.com/bluekitchen/btstack.git
synced 2025-01-25 09:35:42 +00:00
sbc: update Makefile
This commit is contained in:
parent
646894e8ea
commit
7a805e12c1
@ -1,4 +1,35 @@
|
||||
test-sine:
|
||||
CC=gcc
|
||||
|
||||
BTSTACK_ROOT = ../..
|
||||
SBC_DECODER_ROOT = ${BTSTACK_ROOT}/3rd-party/bluedroid/decoder
|
||||
SBC_ENCODER_ROOT = ${BTSTACK_ROOT}/3rd-party/bluedroid/encoder
|
||||
|
||||
include ${SBC_DECODER_ROOT}/Makefile.inc
|
||||
include ${SBC_ENCODER_ROOT}/Makefile.inc
|
||||
|
||||
SBC_DECODER_OBJ = $(SBC_DECODER:.c=.o)
|
||||
SBC_ENCODER_OBJ = $(SBC_ENCODER:.c=.o)
|
||||
|
||||
CFLAGS = -g -Wall -I. -I../ -I${SBC_DECODER_ROOT}/include -I${SBC_ENCODER_ROOT}/include -D PRINT_SAMPLES -D PRINT_SCALEFACTORS -D OI_DEBUG -D SBC_NO_PCM_CPY_OPTION
|
||||
# -D TRACE_EXECUTION -D CODEC_DEBUG
|
||||
LDFLAGS += -lCppUTest -lCppUTestExt
|
||||
VPATH += ${SBC_DECODER_ROOT}/srce ${SBC_ENCODER_ROOT}/srce
|
||||
|
||||
SBC_TESTS = sbc_decoder_test sbc_encoder_test
|
||||
|
||||
all: ${SBC_TESTS}
|
||||
|
||||
sbc_decoder_test: ${SBC_DECODER_OBJ} sbc_decoder_test.o
|
||||
${CC} $^ ${CFLAGS} ${LDFLAGS} -o $@
|
||||
|
||||
sbc_encoder_test: ${SBC_ENCODER_OBJ} sbc_encoder_test.o
|
||||
${CC} $^ ${CFLAGS} ${LDFLAGS} -o $@
|
||||
|
||||
test: all
|
||||
./sbc_decoder_test data/sine-4sb-mono.sbc data/sine-4sb-decoded-mono.wav
|
||||
./sbc_encoder_test data/sine-mono.wav data/sine-4sb-mono.sbc
|
||||
|
||||
pytest-sine:
|
||||
./sbc_decoder_test.py data/sine-4sb-mono.sbc data/sine-4sb-decoded-mono.wav
|
||||
./sbc_decoder_test.py data/sine-8sb-mono.sbc data/sine-8sb-decoded-mono.wav
|
||||
./sbc_decoder_test.py data/sine-4sb-stereo.sbc data/sine-4sb-decoded-stereo.wav
|
||||
@ -9,18 +40,18 @@ test-sine:
|
||||
./sbc_encoder_test.py data/sine-stereo.wav 16 4 30 1 2 data/sine-4sb-stereo.sbc
|
||||
./sbc_encoder_test.py data/sine-stereo.wav 16 8 64 2 data/sine-8sb-stereo.sbc
|
||||
|
||||
test-short:
|
||||
./sbc_decoder_test.py data/fanfare-short-4sb-mono.sbc data/fanfare-short-4sb-decoded-mono.wav
|
||||
./sbc_decoder_test.py data/fanfare-short-8sb-mono.sbc data/fanfare-short-8sb-decoded-mono.wav
|
||||
./sbc_decoder_test.py data/fanfare-short-4sb-stereo.sbc data/fanfare-short-4sb-decoded-stereo.wav
|
||||
./sbc_decoder_test.py data/fanfare-short-8sb-stereo.sbc data/fanfare-short-8sb-decoded-stereo.wav
|
||||
pytest-short:
|
||||
./sbc_decoder_test.py data/fanfare-short-4sb-mono.sbc 0 SIG data/fanfare-short-4sb-decoded-mono.wav
|
||||
./sbc_decoder_test.py data/fanfare-short-8sb-mono.sbc 0 V1 data/fanfare-short-8sb-decoded-mono.wav
|
||||
./sbc_decoder_test.py data/fanfare-short-4sb-stereo.sbc 2 SIG data/fanfare-short-4sb-decoded-stereo.wav
|
||||
./sbc_decoder_test.py data/fanfare-short-8sb-stereo.sbc 2 SIG data/fanfare-short-8sb-decoded-stereo.wav
|
||||
|
||||
./sbc_encoder_test.py data/fanfare-short-mono.wav 16 4 31 1 0 data/fanfare-short-4sb-mono.sbc
|
||||
./sbc_encoder_test.py data/fanfare-short-mono.wav 16 8 64 1 0 data/fanfare-short-8sb-mono.sbc
|
||||
./sbc_encoder_test.py data/fanfare-short-stereo.wav 16 4 30 1 2 data/fanfare-short-4sb-stereo.sbc
|
||||
./sbc_encoder_test.py data/fanfare-short-stereo.wav 16 8 62 1 2 data/fanfare-short-8sb-stereo.sbc
|
||||
|
||||
test:
|
||||
pytest:
|
||||
./sbc_decoder_test.py data/fanfare-4sb-mono.sbc data/fanfare-4sb-decoded-mono.wav
|
||||
./sbc_decoder_test.py data/fanfare-8sb-mono.sbc data/fanfare-8sb-decoded-mono.wav
|
||||
./sbc_decoder_test.py data/fanfare-4sb-stereo.sbc data/fanfare-4sb-decoded-stereo.wav
|
||||
@ -32,4 +63,4 @@ test:
|
||||
./sbc_encoder_test.py data/fanfare-stereo.wav 16 8 64 2 data/fanfare-8sb-stereo.sbc
|
||||
|
||||
clean:
|
||||
rm -f *.pyc *.wav *.sbc data/*-decoded.wav data/*-encoded.sbc
|
||||
rm -f *.pyc *.wav *.sbc data/*-decoded.wav data/*-encoded.sbc *.o $(SBC_TESTS) *.dSYM
|
Loading…
x
Reference in New Issue
Block a user