diff --git a/examples/platform/silabs/SiWx917/BUILD.gn b/examples/platform/silabs/SiWx917/BUILD.gn index 2d7b1ec9c8592e..ae115f49b9fb98 100644 --- a/examples/platform/silabs/SiWx917/BUILD.gn +++ b/examples/platform/silabs/SiWx917/BUILD.gn @@ -148,10 +148,6 @@ source_set("siwx917-attestation-credentials") { } source_set("silabs-factory-data-provider") { - if (siwx917_commissionable_data) { - defines = [ "SIWX917_USE_COMISSIONABLE_DATA=1" ] - } - sources = [ "${silabs_common_plat_dir}/SilabsDeviceDataProvider.cpp", "${silabs_common_plat_dir}/SilabsDeviceDataProvider.h", @@ -162,6 +158,8 @@ source_set("silabs-factory-data-provider") { "${chip_root}/src/platform:platform_base", "${chip_root}/src/setup_payload", ] + + public_configs = [ ":siwx917-common-config" ] } config("siwx917-common-config") { @@ -184,6 +182,10 @@ config("siwx917-common-config") { if (enable_heap_monitoring) { defines += [ "HEAP_MONITORING" ] } + + if (siwx917_commissionable_data) { + defines += [ "SIWX917_USE_COMISSIONABLE_DATA=1" ] + } } config("silabs-wifi-config") { diff --git a/examples/platform/silabs/SilabsDeviceDataProvider.cpp b/examples/platform/silabs/SilabsDeviceDataProvider.cpp index 4c87804c72c706..2722409cf94608 100644 --- a/examples/platform/silabs/SilabsDeviceDataProvider.cpp +++ b/examples/platform/silabs/SilabsDeviceDataProvider.cpp @@ -161,6 +161,7 @@ CHIP_ERROR SIWx917DeviceDataProvider::FlashFactoryData() return err; } } + return CHIP_NO_ERROR; } #endif