mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 946618 - Add native tests for cubeb. r=kinetik
--HG-- extra : rebase_source : 9b2e8e702ce5f8ea4d5416f3b45c91bc4cd94432
This commit is contained in:
parent
1140f95c5d
commit
ba92d7c5b8
@ -134,6 +134,7 @@ speex_resampler_reset_mem
|
||||
speex_resampler_strerror
|
||||
cubeb_destroy
|
||||
cubeb_init
|
||||
cubeb_get_backend_id
|
||||
cubeb_get_max_channel_count
|
||||
cubeb_get_min_latency
|
||||
cubeb_get_preferred_sample_rate
|
||||
|
@ -5,4 +5,5 @@
|
||||
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
DIRS += ['include', 'src']
|
||||
TEST_TOOL_DIRS += ['tests']
|
||||
|
||||
|
@ -4,6 +4,8 @@
|
||||
# License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
LIBRARY_NAME = 'cubeb'
|
||||
|
||||
SOURCES += [
|
||||
'cubeb.c',
|
||||
]
|
||||
|
26
media/libcubeb/tests/Makefile.in
Normal file
26
media/libcubeb/tests/Makefile.in
Normal file
@ -0,0 +1,26 @@
|
||||
# -*- Mode: makefile; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- #
|
||||
# This Source Code Form is subject to the terms of the Mozilla Public
|
||||
# License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
ifeq ($(OS_ARCH),WINNT)
|
||||
# On windows, the WASAPI backend needs the resampler we have in
|
||||
# /media/libspeex_resampler, so we can't get away with just linking cubeb's .o
|
||||
LIBS = $(call EXPAND_LIBNAME_PATH,gkmedias,$(DEPTH)/layout/media) \
|
||||
$(NULL)
|
||||
else
|
||||
# Otherwise, we can just grab all the compiled .o and compile against that,
|
||||
# linking the appriopriate libraries.
|
||||
LIBS = $(call EXPAND_LIBNAME_PATH,cubeb,$(DEPTH)/media/libcubeb/src)
|
||||
ifeq ($(OS_TARGET),Darwin)
|
||||
LIBS += -framework AudioUnit -framework CoreAudio
|
||||
else
|
||||
ifeq ($(OS_TARGET), OpenBSD)
|
||||
LIBS += -lsndio
|
||||
else
|
||||
LIBS += $(MOZ_ALSA_LIBS) \
|
||||
$(MOZ_PULSEAUDIO_LIBS)
|
||||
endif
|
||||
endif
|
||||
LIBS += $(NULL)
|
||||
endif
|
19
media/libcubeb/tests/moz.build
Normal file
19
media/libcubeb/tests/moz.build
Normal file
@ -0,0 +1,19 @@
|
||||
# -*- Mode: python; c-basic-offset: 4; indent-tabs-mode: nil; tab-width: 40 -*-
|
||||
# vim: set filetype=python:
|
||||
# This Source Code Form is subject to the terms of the Mozilla Public
|
||||
# License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
CPP_UNIT_TESTS += [
|
||||
'test_audio.cpp',
|
||||
'test_latency.cpp',
|
||||
'test_sanity.cpp',
|
||||
'test_tone.cpp'
|
||||
]
|
||||
|
||||
LOCAL_INCLUDES += [
|
||||
'../include'
|
||||
]
|
||||
|
||||
FAIL_ON_WARNINGS = True
|
||||
|
@ -18,6 +18,12 @@ cp $1/src/android/sles_definitions.h src/android
|
||||
cp $1/LICENSE .
|
||||
cp $1/README .
|
||||
cp $1/AUTHORS .
|
||||
cp $1/test/common.h tests/common.h
|
||||
cp $1/test/test_audio.c tests/test_audio.cpp
|
||||
cp $1/test/test_tone.c tests/test_tone.cpp
|
||||
cp $1/test/test_sanity.c tests/test_sanity.cpp
|
||||
cp $1/test/test_latency.c tests/test_latency.cpp
|
||||
|
||||
if [ -d $1/.git ]; then
|
||||
rev=$(cd $1 && git rev-parse --verify HEAD)
|
||||
dirty=$(cd $1 && git diff-index --name-only HEAD)
|
||||
|
Loading…
Reference in New Issue
Block a user