From b5ea25a9d2bd7829e87837e44af298bdfd470cca Mon Sep 17 00:00:00 2001 From: Rahul Tank Date: Tue, 26 May 2026 22:00:39 +0530 Subject: [PATCH] fix(nimble): Fix compilation issues in Gatt SPS service Co-authored-by: Cursor --- .../bluetooth/nimble/ble_chan_sound_initiator/main/gatt_svr.c | 3 ++- .../bluetooth/nimble/ble_chan_sound_reflector/main/gatt_svr.c | 3 ++- examples/bluetooth/nimble/ble_htp/htp_prph/main/gatt_svr.c | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/examples/bluetooth/nimble/ble_chan_sound_initiator/main/gatt_svr.c b/examples/bluetooth/nimble/ble_chan_sound_initiator/main/gatt_svr.c index 168d0035c79..2f06346da8c 100644 --- a/examples/bluetooth/nimble/ble_chan_sound_initiator/main/gatt_svr.c +++ b/examples/bluetooth/nimble/ble_chan_sound_initiator/main/gatt_svr.c @@ -31,7 +31,8 @@ gatt_svr_init(void) #if MYNEWT_VAL(BLE_GATTS) ble_svc_gatt_init(); #endif +#if MYNEWT_VAL(BLE_GATTS) && CONFIG_BT_NIMBLE_RAS_SERVICE ble_svc_ras_init(); - +#endif return 0; } diff --git a/examples/bluetooth/nimble/ble_chan_sound_reflector/main/gatt_svr.c b/examples/bluetooth/nimble/ble_chan_sound_reflector/main/gatt_svr.c index fdadd4c2aa7..f559b1d6f34 100644 --- a/examples/bluetooth/nimble/ble_chan_sound_reflector/main/gatt_svr.c +++ b/examples/bluetooth/nimble/ble_chan_sound_reflector/main/gatt_svr.c @@ -31,7 +31,8 @@ custom_gatt_svr_init(void) #if MYNEWT_VAL(BLE_GATTS) ble_svc_gatt_init(); #endif +#if MYNEWT_VAL(BLE_GATTS) && CONFIG_BT_NIMBLE_RAS_SERVICE ble_svc_ras_init(); - +#endif return 0; } diff --git a/examples/bluetooth/nimble/ble_htp/htp_prph/main/gatt_svr.c b/examples/bluetooth/nimble/ble_htp/htp_prph/main/gatt_svr.c index 82b6b1f1bcf..aae6bd14d51 100644 --- a/examples/bluetooth/nimble/ble_htp/htp_prph/main/gatt_svr.c +++ b/examples/bluetooth/nimble/ble_htp/htp_prph/main/gatt_svr.c @@ -123,7 +123,7 @@ gatt_svr_init(void) #if MYNEWT_VAL(BLE_GATTS) ble_svc_gatt_init(); #endif -#if CONFIG_BT_NIMBLE_ANS_SERVICE +#if CONFIG_BT_NIMBLE_HTP_SERVICE ble_svc_htp_init(); #endif