diff --git a/.gitignore b/.gitignore
index 33f8ea3..a182a45 100644
--- a/.gitignore
+++ b/.gitignore
monitor/btmon
emulator/btvirt
emulator/b1ee
+client/bluetoothctl
doc/*.bak
doc/*.stamp
diff --git a/Makefile.tools b/Makefile.tools
index 84213aa..9c23b99 100644
--- a/Makefile.tools
+++ b/Makefile.tools
emulator_b1ee_SOURCES = emulator/b1ee.c monitor/mainloop.h monitor/mainloop.c
if READLINE
-bin_PROGRAMS += attrib/gatttool
+noinst_PROGRAMS += client/bluetoothctl
+client_bluetoothctl_SOURCES = client/main.c
+client_bluetoothctl_LDADD = @GLIB_LIBS@ @DBUS_LIBS@ -lreadline
+bin_PROGRAMS += attrib/gatttool
attrib_gatttool_SOURCES = attrib/gatttool.c attrib/att.c attrib/gatt.c \
attrib/gattrib.c btio/btio.c \
attrib/gatttool.h attrib/interactive.c \
diff --git a/client/main.c b/client/main.c
new file mode 100644
index 0000000..b38861a
--- /dev/null
+++ b/client/main.c
+/*
+ *
+ * BlueZ - Bluetooth protocol stack for Linux
+ *
+ * Copyright (C) 2012 Intel Corporation. All rights reserved.
+ *
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program 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 General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; 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
+
+int main(int argc, char *argv[])
+{
+ return 0;
+}
diff --git a/configure.ac b/configure.ac
index 0ae5c2c..cfead7f 100644
--- a/configure.ac
+++ b/configure.ac
AC_SUBST(ICAL_LIBS)
AM_CONDITIONAL(OBEX, test "${enable_obex}" != "no")
+AC_ARG_ENABLE(client, AC_HELP_STRING([--disable-client],
+ [disable command line client]), [enable_client=${enableval}])
+AM_CONDITIONAL(CLIENT, test "${enable_client}" != "no" &&
+ test "${enable_readline}" != "no")
+
AC_ARG_ENABLE(datafiles, AC_HELP_STRING([--disable-datafiles],
[do not install configuration and data files]),
[enable_datafiles=${enableval}])