| # Copyright (c) 2021 Project CHIP Authors |
| # |
| # Licensed under the Apache License, Version 2.0 (the "License"); |
| # you may not use this file except in compliance with the License. |
| # You may obtain a copy of the License at |
| # |
| # http://www.apache.org/licenses/LICENSE-2.0 |
| # |
| # Unless required by applicable law or agreed to in writing, software |
| # distributed under the License is distributed on an "AS IS" BASIS, |
| # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| # See the License for the specific language governing permissions and |
| # limitations under the License. |
| |
| import("//build_overrides/chip.gni") |
| import("//build_overrides/pigweed.gni") |
| |
| import("${chip_root}/src/platform/device.gni") |
| |
| import("${chip_root}/build/chip/buildconfig_header.gni") |
| import("${chip_root}/src/crypto/crypto.gni") |
| |
| silabs_platform_dir = "${chip_root}/src/platform/silabs" |
| |
| assert(chip_device_platform == "SiWx917") |
| |
| if (chip_enable_openthread) { |
| import("//build_overrides/openthread.gni") |
| } |
| |
| static_library("SiWx917") { |
| sources = [ |
| "${silabs_platform_dir}/BLEManagerImpl.h", |
| "${silabs_platform_dir}/BlePlatformConfig.h", |
| "${silabs_platform_dir}/CHIPDevicePlatformConfig.h", |
| "${silabs_platform_dir}/CHIPDevicePlatformEvent.h", |
| "${silabs_platform_dir}/CHIPMem-Platform.cpp", |
| "${silabs_platform_dir}/CHIPPlatformConfig.h", |
| "${silabs_platform_dir}/ConfigurationManagerImpl.h", |
| "${silabs_platform_dir}/ConnectivityManagerImpl.h", |
| "${silabs_platform_dir}/DiagnosticDataProviderImpl.cpp", |
| "${silabs_platform_dir}/DiagnosticDataProviderImpl.h", |
| "${silabs_platform_dir}/InetPlatformConfig.h", |
| "${silabs_platform_dir}/KeyValueStoreManagerImpl.h", |
| "${silabs_platform_dir}/Logging.cpp", |
| "${silabs_platform_dir}/PlatformManagerImpl.h", |
| "${silabs_platform_dir}/SilabsConfig.cpp", |
| "${silabs_platform_dir}/SilabsConfig.h", |
| "${silabs_platform_dir}/SystemPlatformConfig.h", |
| "../../FreeRTOS/SystemTimeSupport.cpp", |
| "../../SingletonConfigurationManager.cpp", |
| "BLEManagerImpl.cpp", |
| "ConfigurationManagerImpl.cpp", |
| "KeyValueStoreManagerImpl.cpp", |
| "PlatformManagerImpl.cpp", |
| "bluetooth/rsi_ble_config.h", |
| "bluetooth/wfx_sl_ble_init.c", |
| "bluetooth/wfx_sl_ble_init.h", |
| ] |
| |
| # TODO: OTA on CCP platform |
| if (chip_enable_ota_requestor) { |
| sources += [ |
| #"OTAImageProcessorImpl.cpp", |
| #"OTAImageProcessorImpl.h", |
| ] |
| } |
| |
| public_deps = [ "${chip_root}/src/platform:platform_base" ] |
| |
| # Add pigweed KVS |
| deps = [ |
| "$dir_pw_kvs:crc16", |
| "$dir_pw_log", |
| ] |
| public_deps += [ |
| "$dir_pw_checksum", |
| "$dir_pw_kvs", |
| ] |
| |
| if (chip_enable_wifi) { |
| sources += [ |
| "${silabs_platform_dir}/ConnectivityManagerImpl_WIFI.cpp", |
| "${silabs_platform_dir}/NetworkCommissioningWiFiDriver.cpp", |
| "${silabs_platform_dir}/NetworkCommissioningWiFiDriver.h", |
| ] |
| } |
| } |