Skip to content

Commit

Permalink
Make sure CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR is always defined. (#…
Browse files Browse the repository at this point in the history
…29224)

Possibly as 0.
  • Loading branch information
bzbarsky-apple authored and pull[bot] committed Nov 27, 2023
1 parent 6aea9a4 commit 1095176
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 15 deletions.
6 changes: 3 additions & 3 deletions examples/pump-app/cc13x2x7_26x2x7/main/AppTask.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
#include <credentials/examples/DeviceAttestationCredsExample.h>
#include <examples/platform/cc13x2_26x2/CC13X2_26X2DeviceAttestationCreds.h>

#if defined(CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR)
#if CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR
#include <app/clusters/ota-requestor/BDXDownloader.h>
#include <app/clusters/ota-requestor/DefaultOTARequestor.h>
#include <app/clusters/ota-requestor/DefaultOTARequestorDriver.h>
Expand Down Expand Up @@ -81,7 +81,7 @@ AppTask AppTask::sAppTask;

static DeviceCallbacks sDeviceCallbacks;

#if defined(CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR)
#if CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR
static DefaultOTARequestor sRequestorCore;
static DefaultOTARequestorStorage sRequestorStorage;
static DefaultOTARequestorDriver sRequestorUser;
Expand Down Expand Up @@ -231,7 +231,7 @@ int AppTask::Init()

ConfigurationMgr().LogDeviceConfig();

#if defined(CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR)
#if CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR
InitializeOTARequestor();
#endif

Expand Down
6 changes: 3 additions & 3 deletions examples/pump-app/cc13x4_26x4/main/AppTask.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
#include <app/util/af-types.h>
#include <app/util/af.h>

#if defined(CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR)
#if CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR
#include <app/clusters/ota-requestor/BDXDownloader.h>
#include <app/clusters/ota-requestor/DefaultOTARequestor.h>
#include <app/clusters/ota-requestor/DefaultOTARequestorDriver.h>
Expand Down Expand Up @@ -82,7 +82,7 @@ AppTask AppTask::sAppTask;

static DeviceCallbacks sDeviceCallbacks;

#if defined(CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR)
#if CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR
static DefaultOTARequestor sRequestorCore;
static DefaultOTARequestorStorage sRequestorStorage;
static DefaultOTARequestorDriver sRequestorUser;
Expand Down Expand Up @@ -231,7 +231,7 @@ int AppTask::Init()

ConfigurationMgr().LogDeviceConfig();

#if defined(CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR)
#if CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR
InitializeOTARequestor();
#endif

Expand Down
6 changes: 3 additions & 3 deletions examples/pump-controller-app/cc13x2x7_26x2x7/main/AppTask.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
#include <app/util/af-types.h>
#include <app/util/af.h>

#if defined(CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR)
#if CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR
#include <app/clusters/ota-requestor/BDXDownloader.h>
#include <app/clusters/ota-requestor/DefaultOTARequestor.h>
#include <app/clusters/ota-requestor/DefaultOTARequestorDriver.h>
Expand Down Expand Up @@ -70,7 +70,7 @@ static Button_Handle sAppRightHandle;

AppTask AppTask::sAppTask;

#if defined(CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR)
#if CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR
static DefaultOTARequestor sRequestorCore;
static DefaultOTARequestorStorage sRequestorStorage;
static DefaultOTARequestorDriver sRequestorUser;
Expand Down Expand Up @@ -225,7 +225,7 @@ int AppTask::Init()

ConfigurationMgr().LogDeviceConfig();

#if defined(CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR)
#if CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR
InitializeOTARequestor();
#endif

Expand Down
6 changes: 3 additions & 3 deletions examples/pump-controller-app/cc13x4_26x4/main/AppTask.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
#include <app/util/af-types.h>
#include <app/util/af.h>

#if defined(CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR)
#if CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR
#include <app/clusters/ota-requestor/BDXDownloader.h>
#include <app/clusters/ota-requestor/DefaultOTARequestor.h>
#include <app/clusters/ota-requestor/DefaultOTARequestorDriver.h>
Expand Down Expand Up @@ -70,7 +70,7 @@ static Button_Handle sAppRightHandle;

AppTask AppTask::sAppTask;

#if defined(CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR)
#if CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR
static DefaultOTARequestor sRequestorCore;
static DefaultOTARequestorStorage sRequestorStorage;
static DefaultOTARequestorDriver sRequestorUser;
Expand Down Expand Up @@ -225,7 +225,7 @@ int AppTask::Init()

ConfigurationMgr().LogDeviceConfig();

#if defined(CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR)
#if CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR
InitializeOTARequestor();
#endif

Expand Down
6 changes: 3 additions & 3 deletions src/platform/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -133,9 +133,9 @@ if (chip_device_platform != "none" && chip_device_platform != "external") {
]
}

if (chip_enable_ota_requestor) {
defines += [ "CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR=1" ]
}
defines += [
"CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR=${chip_enable_ota_requestor}",
]

if (chip_device_project_config_include != "") {
defines += [ "CHIP_DEVICE_PROJECT_CONFIG_INCLUDE=${chip_device_project_config_include}" ]
Expand Down

0 comments on commit 1095176

Please sign in to comment.