summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarcel Holtmann <marcel@holtmann.org>2007-01-31 08:52:52 +0000
committerMarcel Holtmann <marcel@holtmann.org>2007-01-31 08:52:52 +0000
commit61f64a95d1e0e8cf4f79b799394444d4bc03b5f7 (patch)
tree646659009a14cad04c7fe32faa8e02d6c6581392
parent5ae83f09aa7142c995fb68b2f18fcea02fac955b (diff)
Add skeleton for embedding SBC library
-rw-r--r--Makefile.am2
-rw-r--r--acinclude.m43
-rw-r--r--audio/Makefile.am9
-rw-r--r--configure.in1
-rw-r--r--sbc/Makefile.am6
-rw-r--r--sbc/sbc.c28
-rw-r--r--sbc/sbc.h35
7 files changed, 80 insertions, 4 deletions
diff --git a/Makefile.am b/Makefile.am
index 78838c5c..b39a554c 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,5 +1,5 @@
-SUBDIRS = eglib common sdpd hcid daemon \
+SUBDIRS = sbc eglib common sdpd hcid daemon \
transfer network serial input audio print sync \
tools rfcomm dund pand hidd \
cups test scripts
diff --git a/acinclude.m4 b/acinclude.m4
index 83ab46d8..58bf8637 100644
--- a/acinclude.m4
+++ b/acinclude.m4
@@ -310,6 +310,9 @@ AC_DEFUN([AC_ARG_BLUEZ], [
AM_CONDITIONAL(EXPAT, test "${expat_enable}" = "yes" && test "${expat_found}" = "yes")
fi
+ AC_SUBST([SBC_CFLAGS], ['-I$(top_srcdir)/sbc'])
+ AC_SUBST([SBC_LIBS], ['$(top_builddir)/sbc/libsbc.la'])
+
AM_CONDITIONAL(INOTIFY, test "${inotify_enable}" = "yes" && test "${inotify_found}" = "yes")
AM_CONDITIONAL(USB, test "${usb_enable}" = "yes" && test "${usb_found}" = "yes")
AM_CONDITIONAL(OBEX, test "${obex_enable}" = "yes" && test "${openobex_found}" = "yes")
diff --git a/audio/Makefile.am b/audio/Makefile.am
index f7e48a3f..5fbbcd21 100644
--- a/audio/Makefile.am
+++ b/audio/Makefile.am
@@ -6,12 +6,15 @@ noinst_PROGRAMS = bluetoothd-service-audio \
bluetoothd_service_audio_SOURCES = main.c
+bluetoothd_service_audio_LDADD = $(top_builddir)/common/libhelper.a \
+ @SBC_LIBS@ @GLIB_LIBS@ @DBUS_LIBS@ @BLUEZ_LIBS@
+
bluetoothd_service_headset_SOURCES = headset.c
-LDADD = $(top_builddir)/common/libhelper.a \
- @GLIB_LIBS@ @DBUS_LIBS@ @BLUEZ_LIBS@
+bluetoothd_service_headset_LDADD = $(top_builddir)/common/libhelper.a \
+ @GLIB_LIBS@ @DBUS_LIBS@ @BLUEZ_LIBS@
-AM_CFLAGS = @BLUEZ_CFLAGS@ @DBUS_CFLAGS@ @GLIB_CFLAGS@
+AM_CFLAGS = @BLUEZ_CFLAGS@ @DBUS_CFLAGS@ @GLIB_CFLAGS@ @SBC_CFLAGS@
INCLUDES = -I$(top_srcdir)/common
diff --git a/configure.in b/configure.in
index 822f931b..1697b28c 100644
--- a/configure.in
+++ b/configure.in
@@ -37,6 +37,7 @@ AC_ARG_BLUEZ
AC_OUTPUT([
Makefile
+ sbc/Makefile
eglib/Makefile
common/Makefile
daemon/Makefile
diff --git a/sbc/Makefile.am b/sbc/Makefile.am
new file mode 100644
index 00000000..9478d120
--- /dev/null
+++ b/sbc/Makefile.am
@@ -0,0 +1,6 @@
+
+noinst_LTLIBRARIES = libsbc.la
+
+libsbc_la_SOURCES = sbc.h sbc.c
+
+MAINTAINERCLEANFILES = Makefile.in
diff --git a/sbc/sbc.c b/sbc/sbc.c
new file mode 100644
index 00000000..de479c4f
--- /dev/null
+++ b/sbc/sbc.c
@@ -0,0 +1,28 @@
+/*
+ *
+ * Bluetooth low-complexity, subband codec (SBC) library
+ *
+ * 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
+
+#include "sbc.h"
diff --git a/sbc/sbc.h b/sbc/sbc.h
new file mode 100644
index 00000000..ae31af4c
--- /dev/null
+++ b/sbc/sbc.h
@@ -0,0 +1,35 @@
+/*
+ *
+ * Bluetooth low-complexity, subband codec (SBC) library
+ *
+ * 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
+ *
+ */
+
+#ifndef __SBC_H
+#define __SBC_H
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __SBC_H */