fix compiling issues when nimble is disabled in sdkconfig

This commit is contained in:
2021-09-21 16:49:45 +02:00
parent 7f853fa04b
commit 641f297120
16 changed files with 20 additions and 13 deletions

View File

@ -12,7 +12,7 @@
* Author: kolban
*/
#include "sdkconfig.h"
#if defined(CONFIG_BT_ENABLED)
#if defined(CONFIG_BT_ENABLED) && defined(CONFIG_NIMBLE_ENABLED)
#include <algorithm>

View File

@ -15,7 +15,7 @@
#ifndef COMPONENTS_NIMBLEADDRESS_H_
#define COMPONENTS_NIMBLEADDRESS_H_
#include "sdkconfig.h"
#if defined(CONFIG_BT_ENABLED)
#if defined(CONFIG_BT_ENABLED) && defined(CONFIG_NIMBLE_ENABLED)
#include "nimble/ble.h"
/**** FIX COMPILATION ****/

View File

@ -12,7 +12,7 @@
* Author: kolban
*/
#include "sdkconfig.h"
#if defined(CONFIG_BT_ENABLED)
#if defined(CONFIG_BT_ENABLED) && defined(CONFIG_NIMBLE_ENABLED)
#include <string.h>
#include <algorithm>

View File

@ -15,6 +15,7 @@
#ifndef MAIN_NIMBLEBEACON_H_
#define MAIN_NIMBLEBEACON_H_
#if defined(CONFIG_BT_ENABLED) && defined(CONFIG_NIMBLE_ENABLED)
#include "NimBLEUUID.h"
/**
* @brief Representation of a beacon.
@ -48,4 +49,5 @@ public:
void setSignalPower(int8_t signalPower);
}; // NimBLEBeacon
#endif
#endif /* MAIN_NIMBLEBEACON_H_ */

View File

@ -12,7 +12,7 @@
* Author: kolban
*/
#include "sdkconfig.h"
#if defined(CONFIG_BT_ENABLED)
#if defined(CONFIG_BT_ENABLED) && defined(CONFIG_NIMBLE_ENABLED)
#include "nimconfig.h"
#include "NimBLEDevice.h"

View File

@ -15,7 +15,7 @@
#ifndef MAIN_NIMBLEDEVICE_H_
#define MAIN_NIMBLEDEVICE_H_
#include "sdkconfig.h"
#if defined(CONFIG_BT_ENABLED)
#if defined(CONFIG_BT_ENABLED) && defined(CONFIG_NIMBLE_ENABLED)
#include "nimconfig.h"

View File

@ -12,7 +12,7 @@
* Author: pcbreflux
*/
#include "sdkconfig.h"
#if defined(CONFIG_BT_ENABLED)
#if defined(CONFIG_BT_ENABLED) && defined(CONFIG_NIMBLE_ENABLED)
#include "NimBLEEddystoneTLM.h"
#include "NimBLELog.h"

View File

@ -14,6 +14,8 @@
#ifndef _NimBLEEddystoneTLM_H_
#define _NimBLEEddystoneTLM_H_
#if defined(CONFIG_BT_ENABLED) && defined(CONFIG_NIMBLE_ENABLED)
#include "NimBLEUUID.h"
#include <string>
@ -57,4 +59,5 @@ private:
}; // NimBLEEddystoneTLM
#endif
#endif /* _NimBLEEddystoneTLM_H_ */

View File

@ -12,7 +12,7 @@
* Author: pcbreflux
*/
#include "sdkconfig.h"
#if defined(CONFIG_BT_ENABLED)
#if defined(CONFIG_BT_ENABLED) && defined(CONFIG_NIMBLE_ENABLED)
#include "NimBLEEddystoneURL.h"
#include "NimBLELog.h"

View File

@ -14,6 +14,7 @@
#ifndef _NIMBLEEddystoneURL_H_
#define _NIMBLEEddystoneURL_H_
#if defined(CONFIG_BT_ENABLED) && defined(CONFIG_NIMBLE_ENABLED)
#include "NimBLEUUID.h"
#include <string>
@ -49,4 +50,5 @@ private:
}; // NIMBLEEddystoneURL
#endif
#endif /* _NIMBLEEddystoneURL_H_ */

View File

@ -13,7 +13,7 @@
*/
#include "sdkconfig.h"
#if defined(CONFIG_BT_ENABLED)
#if defined(CONFIG_BT_ENABLED) && defined(CONFIG_NIMBLE_ENABLED)
#include "NimBLESecurity.h"
#include "NimBLEDevice.h"

View File

@ -15,7 +15,7 @@
#ifndef COMPONENTS_NIMBLESECURITY_H_
#define COMPONENTS_NIMBLESECURITY_H_
#include "sdkconfig.h"
#if defined(CONFIG_BT_ENABLED)
#if defined(CONFIG_BT_ENABLED) && defined(CONFIG_NIMBLE_ENABLED)
#include "host/ble_gap.h"
/**** FIX COMPILATION ****/

View File

@ -12,7 +12,7 @@
* Author: kolban
*/
#include "sdkconfig.h"
#if defined(CONFIG_BT_ENABLED)
#if defined(CONFIG_BT_ENABLED) && defined(CONFIG_NIMBLE_ENABLED)
#include "NimBLEUtils.h"
#include "NimBLEUUID.h"

View File

@ -15,7 +15,7 @@
#ifndef COMPONENTS_NIMBLEUUID_H_
#define COMPONENTS_NIMBLEUUID_H_
#include "sdkconfig.h"
#if defined(CONFIG_BT_ENABLED)
#if defined(CONFIG_BT_ENABLED) && defined(CONFIG_NIMBLE_ENABLED)
#include "host/ble_uuid.h"
/**** FIX COMPILATION ****/

View File

@ -7,7 +7,7 @@
*/
#include "sdkconfig.h"
#if defined(CONFIG_BT_ENABLED)
#if defined(CONFIG_BT_ENABLED) && defined(CONFIG_NIMBLE_ENABLED)
#include "NimBLEUtils.h"
#include "NimBLELog.h"

View File

@ -9,7 +9,7 @@
#ifndef COMPONENTS_NIMBLEUTILS_H_
#define COMPONENTS_NIMBLEUTILS_H_
#include "sdkconfig.h"
#if defined(CONFIG_BT_ENABLED)
#if defined(CONFIG_BT_ENABLED) && defined(CONFIG_NIMBLE_ENABLED)
#include "host/ble_gap.h"