modules: Fix compatibility with PulseAudio 13.0.
There were some API changes: -878ef44079-6665b466d2Leading to: Error relocating /usr/lib/pulse-13.0/modules/libdroid-sink.so: pa_make_realtime: symbol not found Error relocating /usr/lib/pulse-13.0/modules/libdroid-source.so: pa_make_realtime: symbol not found Error relocating /usr/lib/pulse-13.0/modules/libdroid-source.so: pa_source_get_state: symbol not found Fixes are: - include <pulse/util.h>, replace pa_make_realtime -> pa_thread_make_realtime - replace pa_source_get_state(X) -> X->state - replace pa_sink_get_state(X) -> X->state [modules] Fix compatibility with PulseAudio 13.0. JB#47666
This commit is contained in:
parent
97a0c98f84
commit
21b3c42db7
2 changed files with 11 additions and 1 deletions
|
|
@ -54,6 +54,7 @@
|
|||
#include <pulsecore/time-smoother.h>
|
||||
#include <pulsecore/hashmap.h>
|
||||
#include <pulsecore/core-subscribe.h>
|
||||
#include <pulse/version.h>
|
||||
|
||||
#include "droid-sink.h"
|
||||
#include <droid/droid-util.h>
|
||||
|
|
@ -371,7 +372,11 @@ static void thread_func(void *userdata) {
|
|||
pa_log_debug("Thread starting up.");
|
||||
|
||||
if (u->core->realtime_scheduling)
|
||||
#if PA_CHECK_VERSION(13,0,0)
|
||||
pa_thread_make_realtime(u->core->realtime_priority);
|
||||
#else
|
||||
pa_make_realtime(u->core->realtime_priority);
|
||||
#endif
|
||||
|
||||
pa_thread_mq_install(&u->thread_mq);
|
||||
|
||||
|
|
|
|||
|
|
@ -51,6 +51,7 @@
|
|||
#include <pulsecore/rtpoll.h>
|
||||
#include <pulsecore/time-smoother.h>
|
||||
#include <pulsecore/resampler.h>
|
||||
#include <pulse/version.h>
|
||||
|
||||
#include "droid-source.h"
|
||||
#include <droid/droid-util.h>
|
||||
|
|
@ -211,7 +212,11 @@ static void thread_func(void *userdata) {
|
|||
pa_log_debug("Thread starting up.");
|
||||
|
||||
if (u->core->realtime_scheduling)
|
||||
#if PA_CHECK_VERSION(13,0,0)
|
||||
pa_thread_make_realtime(u->core->realtime_priority);
|
||||
#else
|
||||
pa_make_realtime(u->core->realtime_priority);
|
||||
#endif
|
||||
|
||||
pa_thread_mq_install(&u->thread_mq);
|
||||
|
||||
|
|
@ -366,7 +371,7 @@ static int source_set_port_cb(pa_source *s, pa_device_port *p) {
|
|||
|
||||
pa_log_debug("Source set port %#010x", data->device);
|
||||
|
||||
if (!PA_SOURCE_IS_OPENED(pa_source_get_state(u->source)))
|
||||
if (!PA_SOURCE_IS_OPENED(u->source->state))
|
||||
do_routing(u, data->device);
|
||||
else {
|
||||
pa_asyncmsgq_post(u->source->asyncmsgq, PA_MSGOBJECT(u->source), SOURCE_MESSAGE_DO_ROUTING, PA_UINT_TO_PTR(data->device), 0, NULL, NULL);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue