meson: Build libwebrtc-util as a shared library

As it'sdone in the autotools

Signed-off-by: Arnaud Rebillout <arnaud.rebillout@collabora.com>
This commit is contained in:
Arnaud Rebillout 2018-11-26 16:44:06 +07:00 committed by Arun Raghavan
parent f5c9ef59f3
commit d717089218
2 changed files with 6 additions and 4 deletions

View file

@ -2,18 +2,20 @@
# link module-echo-cancel with C++ (which it does if there are any C++ deps, # link module-echo-cancel with C++ (which it does if there are any C++ deps,
# even conditional ones). # even conditional ones).
# Defining this library as shared fails, as it actually requires a symbol # This library requires a symbol from module-echo-cancel, hence we need
# from module-echo-cancel.c. Setting it to static solves that. # '-Wl,--unresolved-symbols=ignore-in-object-files' otherwise it fails
# at link time.
libwebrtc_util_sources = [ libwebrtc_util_sources = [
'webrtc.cc' 'webrtc.cc'
] ]
libwebrtc_util = static_library('webrtc-util', libwebrtc_util = shared_library('webrtc-util',
libwebrtc_util_sources, libwebrtc_util_sources,
cpp_args : [pa_c_args, server_c_args], cpp_args : [pa_c_args, server_c_args],
include_directories : [configinc, topinc], include_directories : [configinc, topinc],
dependencies : [libpulse_dep, libpulsecommon_dep, libpulsecore_dep, webrtc_dep], dependencies : [libpulse_dep, libpulsecommon_dep, libpulsecore_dep, webrtc_dep],
link_args : [ '-Wl,--unresolved-symbols=ignore-in-object-files' ],
install : true, install : true,
install_dir : modlibexecdir, install_dir : modlibexecdir,
) )

View file

@ -142,7 +142,7 @@ endforeach
norun_tests += [ norun_tests += [
[ 'echo-cancel-test', echo_cancel_test_sources, [ 'echo-cancel-test', echo_cancel_test_sources,
module_echo_cancel_deps + [ libpulse_dep, libpulsecore_dep ], module_echo_cancel_deps + [ libpulse_dep, libpulsecommon_dep, libpulsecore_dep ],
module_echo_cancel_libs, module_echo_cancel_libs,
module_echo_cancel_flags + server_c_args + [ '-DPA_MODULE_NAME=module_echo_cancel', '-DECHO_CANCEL_TEST=1' ] ] module_echo_cancel_flags + server_c_args + [ '-DPA_MODULE_NAME=module_echo_cancel', '-DECHO_CANCEL_TEST=1' ] ]
] ]