diff options
| -rw-r--r-- | acinclude.m4 | 36 | ||||
| -rw-r--r-- | audio/Makefile.am | 11 | ||||
| -rw-r--r-- | audio/module-bluetooth-sink.c | 39 | ||||
| -rw-r--r-- | configure.in | 3 | 
4 files changed, 76 insertions, 13 deletions
| diff --git a/acinclude.m4 b/acinclude.m4 index 4f54dadc..2a0d4b30 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -117,6 +117,12 @@ AC_DEFUN([AC_PATH_GSTREAMER], [  	AC_SUBST(GSTREAMER_PLUGINSDIR)  ]) +AC_DEFUN([AC_PATH_PULSE], [ +        PKG_CHECK_MODULES(PULSE, libpulse, pulse_found=yes, pulse_found=no) +        AC_SUBST(PULSE_CFLAGS) +        AC_SUBST(PULSE_LIBS) +]) +  AC_DEFUN([AC_PATH_ALSA], [  	PKG_CHECK_MODULES(ALSA, alsa, alsa_found=yes, alsa_found=no)  	AC_SUBST(ALSA_CFLAGS) @@ -161,10 +167,11 @@ AC_DEFUN([AC_ARG_BLUEZ], [  	obex_enable=${openobex_found}  	glib_enable=no  	gstreamer_enable=${gstreamer_found} -	network_enable=no -	serial_enable=no -	input_enable=no +	pulse_enable=${pulse_found}  	audio_enable=no +	input_enable=no +	serial_enable=no +	network_enable=no  	sync_enable=no  	echo_enable=no  	hcid_enable=yes @@ -246,20 +253,24 @@ AC_DEFUN([AC_ARG_BLUEZ], [  		gstreamer_enable=${enableval}  	]) -	AC_ARG_ENABLE(network, AC_HELP_STRING([--enable-network], [enable network service]), [ -		network_enable=${enableval} +	AC_ARG_ENABLE(pulse, AC_HELP_STRING([--enable-pulse], [enable PulseAudio support]), [ +		pulse_enable=${enableval}  	]) -	AC_ARG_ENABLE(serial, AC_HELP_STRING([--enable-serial], [enable serial service]), [ -		serial_enable=${enableval} +	AC_ARG_ENABLE(audio, AC_HELP_STRING([--enable-audio], [enable audio service]), [ +		audio_enable=${enableval}  	])  	AC_ARG_ENABLE(input, AC_HELP_STRING([--enable-input], [enable input service]), [  		input_enable=${enableval}  	]) -	AC_ARG_ENABLE(audio, AC_HELP_STRING([--enable-audio], [enable audio service]), [ -		audio_enable=${enableval} +	AC_ARG_ENABLE(serial, AC_HELP_STRING([--enable-serial], [enable serial service]), [ +		serial_enable=${enableval} +	]) + +	AC_ARG_ENABLE(network, AC_HELP_STRING([--enable-network], [enable network service]), [ +		network_enable=${enableval}  	])  	AC_ARG_ENABLE(sync, AC_HELP_STRING([--enable-sync], [enable synchronization service]), [ @@ -368,10 +379,11 @@ AC_DEFUN([AC_ARG_BLUEZ], [  	AM_CONDITIONAL(ALSA, test "${alsa_enable}" = "yes" && test "${alsa_found}" = "yes")  	AM_CONDITIONAL(OBEX, test "${obex_enable}" = "yes" && test "${openobex_found}" = "yes")  	AM_CONDITIONAL(GSTREAMER, test "${gstreamer_enable}" = "yes" && test "${gstreamer_found}" = "yes") -	AM_CONDITIONAL(NETWORKSERVICE, test "${network_enable}" = "yes") -	AM_CONDITIONAL(SERIALSERVICE, test "${serial_enable}" = "yes") -	AM_CONDITIONAL(INPUTSERVICE, test "${input_enable}" = "yes") +	AM_CONDITIONAL(PULSE, test "${pulse_enable}" = "yes" && test "${pulse_found}" = "yes")  	AM_CONDITIONAL(AUDIOSERVICE, test "${audio_enable}" = "yes") +	AM_CONDITIONAL(INPUTSERVICE, test "${input_enable}" = "yes") +	AM_CONDITIONAL(SERIALSERVICE, test "${serial_enable}" = "yes") +	AM_CONDITIONAL(NETWORKSERVICE, test "${network_enable}" = "yes")  	AM_CONDITIONAL(SYNCSERVICE, test "${sync_enable}" = "yes" && test "${opensync_found}" = "yes")  	AM_CONDITIONAL(ECHOSERVICE, test "${echo_enable}" = "yes")  	AM_CONDITIONAL(HCID, test "${hcid_enable}" = "yes") diff --git a/audio/Makefile.am b/audio/Makefile.am index ce16cd12..42fd1590 100644 --- a/audio/Makefile.am +++ b/audio/Makefile.am @@ -34,6 +34,17 @@ libasound_module_ctl_bluetooth_la_LIBADD = @ALSA_LIBS@  libasound_module_ctl_bluetooth_la_CFLAGS = @ALSA_CFLAGS@  endif +if PULSE +pulsedir = $(libdir)/pulse-0.9/modules + +noinst_LTLIBRARIES = module-bluetooth-sink.la + +module_bluetooth_sink_la_SOURCES = module-bluetooth-sink.c ipc.h +module_bluetooth_sink_la_LDFLAGS = -module -avoid-version +module_bluetooth_sink_la_LIBADD = @SBC_LIBS@ @PULSE_LIBS@ +module_bluetooth_sink_la_CFLAGS = @PULSE_CFLAGS@ @SBC_CFLAGS@ +endif +  if GSTREAMER  gstreamerdir = $(libdir)/gstreamer-0.10 diff --git a/audio/module-bluetooth-sink.c b/audio/module-bluetooth-sink.c new file mode 100644 index 00000000..96b5d98f --- /dev/null +++ b/audio/module-bluetooth-sink.c @@ -0,0 +1,39 @@ +/* + * + *  BlueZ - Bluetooth protocol stack for Linux + * + *  Copyright (C) 2004-2007  Marcel Holtmann <marcel@holtmann.org> + * + * + *  This library is free software; you can redistribute it and/or + *  modify it under the terms of the GNU Lesser General Public + *  License as published by the Free Software Foundation; either + *  version 2.1 of the License, or (at your option) any later version. + * + *  This library is distributed in the hope that it will be useful, + *  but WITHOUT ANY WARRANTY; without even the implied warranty of + *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU + *  Lesser General Public License for more details. + * + *  You should have received a copy of the GNU Lesser General Public + *  License along with this library; if not, write to the Free Software + *  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA + * + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#if 0 +#include <pulsecore/module.h> + +PA_MODULE_AUTHOR("Marcel Holtmann <marcel@holtmann.org>") +PA_MODULE_DESCRIPTION("Bluetooth sink") +PA_MODULE_VERSION(VERSION) + +int pa__init(pa_core *core, pa_module *module) +{ +	return 0; +} +#endif diff --git a/configure.in b/configure.in index 272cec46..2e9162be 100644 --- a/configure.in +++ b/configure.in @@ -28,9 +28,10 @@ AC_PATH_BLUEZ  AC_PATH_GLIB  AC_PATH_DBUS  AC_PATH_ALSA +AC_PATH_PULSE +AC_PATH_GSTREAMER  AC_PATH_OPENOBEX  AC_PATH_OPENSYNC -AC_PATH_GSTREAMER  AC_PATH_HAL  AC_PATH_USB  AC_PATH_EXPAT | 
