Skip to content

Commit

Permalink
conditionally use qubesdb dependency in vchan-sink module
Browse files Browse the repository at this point in the history
  • Loading branch information
easydozen committed May 30, 2020
1 parent ddd8a9b commit bf3dfb2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion pulse/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,6 @@ module-vchan-sink.so: module-vchan-sink.o
$(CC) -shared -o module-vchan-sink.so module-vchan-sink.o \
$(VCHANLIBS) $(LIBS)
module-vchan-sink.o: module-vchan-sink.c
$(CC) $(CFLAGS) -g -c $(VCHANCFLAGS) -fPIC module-vchan-sink.c -DHAVE_CONFIG_H -I.
$(CC) $(CFLAGS) -g -c $(VCHANCFLAGS) -fPIC module-vchan-sink.c -DHAVE_CONFIG_H -DHAVE_QUBESDB_CLIENT_H -I.
clean:
rm -f *.so *.o *~
4 changes: 4 additions & 0 deletions pulse/module-vchan-sink.c
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,9 @@
#include "module-vchan-sink-symdef.h"
#include "qubes-vchan-sink.h"
#include <libvchan.h>
#ifdef HAVE_QUBESDB_CLIENT_H
#include <qubesdb-client.h>
#endif

PA_MODULE_AUTHOR("Marek Marczykowski-Górecki");
PA_MODULE_DESCRIPTION("VCHAN sink/source");
Expand Down Expand Up @@ -660,6 +662,7 @@ int pa__init(pa_module * m)
pa_sink_new_data data_sink;
pa_source_new_data data_source;
int domid = DEFAULT_DOMID;
#ifdef HAVE_QUBESDB_CLIENT_H
qdb_handle_t qdb;
char *qdb_entry, *tmp;
int qdb_domid;
Expand All @@ -679,6 +682,7 @@ int pa__init(pa_module * m)
free(qdb_entry);
}
qdb_close(qdb);
#endif

pa_assert(m);

Expand Down

0 comments on commit bf3dfb2

Please sign in to comment.