summaryrefslogtreecommitdiffstats
path: root/src/bluetooth/bluetooth.pro
diff options
context:
space:
mode:
authorAlex Blasche <alexander.blasche@digia.com>2014-06-16 12:27:55 +0200
committerAlex Blasche <alexander.blasche@digia.com>2014-06-16 14:17:42 +0200
commit50e7588d6d2b4a21b2c4aebc0417b5cfcd8a9c03 (patch)
treefdc93854fb3614f8557a4b53ce983ac9c09c78e0 /src/bluetooth/bluetooth.pro
parent680537e519c859c79251da94fa15740d87b5ca35 (diff)
Provide guarding against non-BTLE enabled versions of Bluez
This disables the gatttool based controller as well. While it might compile on older systems they are likely to not have a gatttool and why would a Bluez version without BTLE symbols ever work anyway. Change-Id: I761e482d3dd1e99008c5d170053e19a1a3a51e6c Reviewed-by: Fabian Bumberger <fbumberger@rim.com>
Diffstat (limited to 'src/bluetooth/bluetooth.pro')
-rw-r--r--src/bluetooth/bluetooth.pro26
1 files changed, 21 insertions, 5 deletions
diff --git a/src/bluetooth/bluetooth.pro b/src/bluetooth/bluetooth.pro
index 0d798956..b8f241c9 100644
--- a/src/bluetooth/bluetooth.pro
+++ b/src/bluetooth/bluetooth.pro
@@ -88,11 +88,27 @@ config_bluez:qtHaveModule(dbus) {
qbluetoothserver_bluez.cpp \
qbluetoothlocaldevice_bluez.cpp \
qbluetoothtransferreply_bluez.cpp \
- qlowenergyprocess_bluez.cpp \
- qlowenergyserviceinfo_bluez.cpp \
- qlowenergycharacteristicinfo_bluez.cpp \
- qlowenergycontroller_bluez.cpp \
- qlowenergycontrollernew_bluez.cpp
+
+
+ # old versions of Bluez do not have the required BTLE symbols
+ config_bluez_le {
+ SOURCES += \
+ qlowenergyprocess_bluez.cpp \
+ qlowenergyserviceinfo_bluez.cpp \
+ qlowenergycharacteristicinfo_bluez.cpp \
+ qlowenergycontroller_bluez.cpp \
+ qlowenergycontrollernew_bluez.cpp
+ } else {
+ message("Bluez version is too old to support Bluetooth Low Energy.")
+ message("Only classic Bluetooth will be available.")
+ DEFINES += QT_BLUEZ_NO_BTLE
+ SOURCES += \
+ qlowenergyserviceinfo_p.cpp \
+ qlowenergycharacteristicinfo_p.cpp \
+ qlowenergyprocess_p.cpp \
+ qlowenergycontroller_p.cpp \
+ qlowenergycontrollernew_p.cpp
+ }
CONFIG += link_pkgconfig
PKGCONFIG_PRIVATE += bluez