summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJim Mussared <jim.mussared@gmail.com>2020-11-24 07:56:34 +1100
committerDamien George <damien@micropython.org>2020-11-24 11:57:29 +1100
commit5a7027915c3b9ec2dffc3af9530dad90b56b8cc0 (patch)
treeb313eb83c250a259419215824f4af59451d929d0
parent23fad2526db2bbc8b6b07bfd67cc6feba1770249 (diff)
extmod/nimble/modbluetooth_nimble: Fix build when l2cap unavailable.
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
-rw-r--r--extmod/nimble/modbluetooth_nimble.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/extmod/nimble/modbluetooth_nimble.c b/extmod/nimble/modbluetooth_nimble.c
index fa416ebc3..bbff26b53 100644
--- a/extmod/nimble/modbluetooth_nimble.c
+++ b/extmod/nimble/modbluetooth_nimble.c
@@ -42,9 +42,11 @@
#include "services/gap/ble_svc_gap.h"
#include "services/gatt/ble_svc_gatt.h"
+#if MICROPY_PY_BLUETOOTH_ENABLE_L2CAP_CHANNELS
// We need the definition of "struct ble_l2cap_chan".
// See l2cap_channel_event() for details.
#include "nimble/host/src/ble_l2cap_priv.h"
+#endif
#ifndef MICROPY_PY_BLUETOOTH_DEFAULT_GAP_NAME
#define MICROPY_PY_BLUETOOTH_DEFAULT_GAP_NAME "MPY NIMBLE"