From 32e2f71e767792f6b15c7ec6726a63fd08bff6d8 Mon Sep 17 00:00:00 2001 From: liyashuai Date: Tue, 2 Apr 2024 14:26:36 +0800 Subject: [PATCH 1/3] update idf version to v5.2.1 for fixing Bootloader TOCTOU Vulnerability in Anti-rollback Scheme --- .github/workflows/docker-image.yml | 2 +- .gitlab-ci.yml | 8 +++---- README.md | 2 +- docs/en/developing.rst | 24 +++++++++---------- docs/en/security.rst | 2 +- .../main/esp_matter_console_helpers.cpp | 22 ++++++++++------- examples/controller/main/esp_ot_config.h | 2 +- 7 files changed, 33 insertions(+), 29 deletions(-) diff --git a/.github/workflows/docker-image.yml b/.github/workflows/docker-image.yml index 4ba73eca8..46d931305 100644 --- a/.github/workflows/docker-image.yml +++ b/.github/workflows/docker-image.yml @@ -30,7 +30,7 @@ env: # Github runner is running out of space when we are building for multiple architectures in single runner BUILD_PLATFORMS: linux/amd64 DOCKERHUB_REPO: ${{ github.repository }} - REQUIRED_IDF_VERSION: v5.1.2 + REQUIRED_IDF_VERSION: v5.2.1 jobs: build: diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 6eaa582fc..8b0ab35bf 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -170,7 +170,7 @@ variables: - mkdir -p ${REPOS_PATH} - *update_build_caches variables: - IDF_VERSION: "v5.1.2" + IDF_VERSION: "v5.2.1" REPOS_PATH: "$CI_PROJECT_DIR/repos" IDF_CCACHE_ENABLE: 1 @@ -190,7 +190,7 @@ build_esp_matter_examples_pytest_C6_idf_v5_1: when: always expire_in: 4 days variables: - IDF_VERSION: "v5.1.2" + IDF_VERSION: "v5.2.1" script: - cd ${ESP_MATTER_PATH} - pip install -r tools/ci/requirements-build.txt @@ -222,7 +222,7 @@ build_esp_matter_examples_pytest_H2_idf_v5_1: when: always expire_in: 4 days variables: - IDF_VERSION: "v5.1.2" + IDF_VERSION: "v5.2.1" script: - *setup_ot_rcp - *setup_ot_br @@ -245,7 +245,7 @@ build_esp_matter_examples_non_pytest_idf_v5_1: when: always expire_in: 4 days variables: - IDF_VERSION: "v5.1.2" + IDF_VERSION: "v5.2.1" script: - *build_external_platform_example - *build_esp32c6_thread_example diff --git a/README.md b/README.md index 60c1218d1..b85c05c61 100644 --- a/README.md +++ b/README.md @@ -29,7 +29,7 @@ section in the ESP-Matter Programming Guide. ## Supported ESP-IDF and connectedhomeip versions - This SDK currently works with commit [d38a6496c3](https://github.com/project-chip/connectedhomeip/tree/d38a6496c3) of connectedhomeip. -- For Matter projects development with this SDK, it is recommended to utilize ESP-IDF [v5.1.2](https://github.com/espressif/esp-idf/tree/v5.1.2). +- For Matter projects development with this SDK, it is recommended to utilize ESP-IDF [v5.2.1](https://github.com/espressif/esp-idf/tree/v5.2.1). ## Documentation diff --git a/docs/en/developing.rst b/docs/en/developing.rst index b2a9a0b34..e9534681c 100644 --- a/docs/en/developing.rst +++ b/docs/en/developing.rst @@ -34,7 +34,7 @@ Development on Windows is supported using Windows Subsystem for Linux (WSL). Ple - Windows does not support exposing COM ports to WSL distros. Install usbipd-win on `Windows `__ and `WSL `__ (usbipd-win `WSL Support `__). - Here onwards process for setting esp-matter and building examples is same as other hosts. -- Please clone the repositories from inside the WSL environment and not inside a mounted directory. +- Please clone the repositories from inside the WSL environment and not inside a mounted directory. For using CHIP tool on WSL, please check `Using CHIP-tool in WSL `__. @@ -43,7 +43,7 @@ For using VSCode for development, please check `Developing in WSL 2.1.2 Getting the Repositories @@ -66,7 +66,7 @@ Cloning esp-idf: :: git clone --recursive https://github.com/espressif/esp-idf.git - cd esp-idf; git checkout v5.1.2; git submodule update --init --recursive; + cd esp-idf; git checkout v5.2.1; git submodule update --init --recursive; ./install.sh cd .. @@ -248,7 +248,7 @@ Choose IDF target. :: ERROR: This script was called from a virtual environment, can not create a virtual environment again - + It can be fixed by running below command: :: @@ -646,14 +646,14 @@ creating in the *app_main.cpp* of the example. Examples: - on_off_light: :: - + on_off_light::config_t light_config; endpoint_t *endpoint = on_off_light::create(node, &light_config, ENDPOINT_FLAG_NONE); - fan: :: - + fan::config_t fan_config; endpoint_t *endpoint = fan::create(node, &fan_config, ENDPOINT_FLAG_NONE); @@ -691,7 +691,7 @@ creating in the *app_main.cpp* of the example. Examples: 2.4.2.2 Clusters ^^^^^^^^^^^^^^^^ -Additional clusters can also be added to an endpoint. Examples: +Additional clusters can also be added to an endpoint. Examples: - on_off: @@ -710,7 +710,7 @@ Additional clusters can also be added to an endpoint. Examples: - window_covering: :: - + window_covering::config_t window_covering_config(static_cast(chip::app::Clusters::WindowCovering::EndProductType::kTiltOnlyInteriorBlind)); cluster_t *cluster = window_covering::create(endpoint, &window_covering_config, CLUSTER_FLAG_SERVER); @@ -733,7 +733,7 @@ Additional clusters can also be added to an endpoint. Examples: ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Additional attributes and commands can also be added to a cluster. -Examples: +Examples: - attribute: on_off: @@ -793,19 +793,19 @@ Non-Standard endpoint can be created, without any clusters. 2.4.3.2 Clusters ^^^^^^^^^^^^^^^^ -Non-Standard/Custom clusters can also be created: +Non-Standard/Custom clusters can also be created: - Cluster create: :: - + uint32_t custom_cluster_id = 0x131bfc00; cluster_t *cluster = cluster::create(endpoint, custom_cluster_id, CLUSTER_FLAG_SERVER); 2.4.3.3 Attributes and Commands ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -Non-Standard/Custom attributes can also be created on any cluster: +Non-Standard/Custom attributes can also be created on any cluster: - Attribute create: diff --git a/docs/en/security.rst b/docs/en/security.rst index d3189919b..31d3b9963 100644 --- a/docs/en/security.rst +++ b/docs/en/security.rst @@ -1,7 +1,7 @@ 5. Security Considerations ========================== -{IDF_TARGET_RELEASE:default="v5.1.2"} +{IDF_TARGET_RELEASE:default="v5.2.1"} 5.1 Overview ------------ diff --git a/examples/all_device_types_app/main/esp_matter_console_helpers.cpp b/examples/all_device_types_app/main/esp_matter_console_helpers.cpp index 3c32b3201..ba42e63ae 100644 --- a/examples/all_device_types_app/main/esp_matter_console_helpers.cpp +++ b/examples/all_device_types_app/main/esp_matter_console_helpers.cpp @@ -77,10 +77,14 @@ static void initialize_console(void) .source_clk = UART_SCLK_XTAL, #endif }; +#if (CONFIG_ESP_CONSOLE_UART_NUM == 0) + uart_port_t uart_port = UART_NUM_0; +#elif (CONFIG_ESP_CONSOLE_UART_NUM == 1) + uart_port_t uart_port = UART_NUM_1; +#endif /* Install UART driver for interrupt-driven reads and writes */ - ESP_ERROR_CHECK( uart_driver_install(CONFIG_ESP_CONSOLE_UART_NUM, - 256, 0, 0, NULL, 0) ); - ESP_ERROR_CHECK( uart_param_config(CONFIG_ESP_CONSOLE_UART_NUM, &uart_config) ); + ESP_ERROR_CHECK( uart_driver_install(uart_port, 256, 0, 0, NULL, 0) ); + ESP_ERROR_CHECK( uart_param_config(uart_port, &uart_config) ); /* Tell VFS to use UART driver */ esp_vfs_dev_uart_use_driver(CONFIG_ESP_CONSOLE_UART_NUM); @@ -369,7 +373,7 @@ int create(uint8_t device_type_index) break; } } - + if (!endpoint) { ESP_LOGE(TAG, "Matter create endpoint failed"); return 1; @@ -387,7 +391,7 @@ int create(uint8_t device_type_index) xSemaphoreGive(semaphoreHandle); } } - + return 0; } @@ -402,7 +406,7 @@ namespace console { struct arg_str *device_type; struct arg_end *end; } create_device_args; - + static int create(int argc, char **argv) { int nerrors = arg_parse(argc, argv, (void **) &create_device_args); @@ -441,11 +445,11 @@ esp_err_t register_create_device_commands() }; return esp_console_cmd_register(&create_cmd); - + } void init(void) -{ +{ #if CONFIG_STORE_HISTORY initialize_filesystem(); ESP_LOGI(TAG, "Command history enabled"); @@ -513,7 +517,7 @@ void init(void) } void deinit(void) -{ +{ fflush(stdout); fsync(fileno(stdout)); esp_console_deinit(); diff --git a/examples/controller/main/esp_ot_config.h b/examples/controller/main/esp_ot_config.h index 97b8e4a09..dbe997704 100644 --- a/examples/controller/main/esp_ot_config.h +++ b/examples/controller/main/esp_ot_config.h @@ -28,7 +28,7 @@ { \ .radio_mode = RADIO_MODE_UART_RCP, \ .radio_uart_config = { \ - .port = UART_NUM_1, \ + .port = UART_NUM_1, \ .uart_config = \ { \ .baud_rate = 460800, \ From b061c3c6d04097b2b5909326a031e2cf244d01be Mon Sep 17 00:00:00 2001 From: liyashuai Date: Wed, 10 Apr 2024 10:39:17 +0800 Subject: [PATCH 2/3] update c2 relinker for ci fix --- examples/common/relinker/esp32c2/object.csv | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/common/relinker/esp32c2/object.csv b/examples/common/relinker/esp32c2/object.csv index e002b90c8..6cff4e5a5 100644 --- a/examples/common/relinker/esp32c2/object.csv +++ b/examples/common/relinker/esp32c2/object.csv @@ -44,7 +44,7 @@ libesp_wifi.a,esp_adapter.c.obj,esp-idf/esp_wifi/CMakeFiles/__idf_esp_wifi.dir/e libfreertos.a,list.c.obj,esp-idf/freertos/CMakeFiles/__idf_freertos.dir/FreeRTOS-Kernel/list.c.obj libfreertos.a,port.c.obj,esp-idf/freertos/CMakeFiles/__idf_freertos.dir/FreeRTOS-Kernel/portable/riscv/port.c.obj libfreertos.a,port_common.c.obj,esp-idf/freertos/CMakeFiles/__idf_freertos.dir/port_common.c.obj -libfreertos.a,port_systick.c.obj,esp-idf/freertos/CMakeFiles/__idf_freertos.dir/FreeRTOS-Kernel/portable/port_systick.c.obj +libfreertos.a,port_systick.c.obj,esp-idf/freertos/CMakeFiles/__idf_freertos.dir/port_systick.c.obj libfreertos.a,queue.c.obj,esp-idf/freertos/CMakeFiles/__idf_freertos.dir/FreeRTOS-Kernel/queue.c.obj libfreertos.a,tasks.c.obj,esp-idf/freertos/CMakeFiles/__idf_freertos.dir/FreeRTOS-Kernel/tasks.c.obj libhal.a,brownout_hal.c.obj,esp-idf/hal/CMakeFiles/__idf_hal.dir/brownout_hal.c.obj From 2ef30e7a477da0cbc3214680fb59257e821e7f5d Mon Sep 17 00:00:00 2001 From: liyashuai Date: Wed, 10 Apr 2024 16:43:53 +0800 Subject: [PATCH 3/3] fix ci error --- examples/all_device_types_app/CMakeLists.txt | 2 +- examples/blemesh_bridge/CMakeLists.txt | 2 +- examples/controller/CMakeLists.txt | 2 +- examples/demo/badge/CMakeLists.txt | 2 +- examples/esp-now_bridge_light/CMakeLists.txt | 2 +- examples/generic_switch/CMakeLists.txt | 2 +- examples/icd_app/CMakeLists.txt | 2 +- examples/light/CMakeLists.txt | 2 +- examples/light_switch/CMakeLists.txt | 2 +- examples/mfg_test_app/CMakeLists.txt | 2 +- examples/refrigerator/CMakeLists.txt | 2 +- examples/room_air_conditioner/CMakeLists.txt | 2 +- examples/zap_light/CMakeLists.txt | 2 +- examples/zigbee_bridge/CMakeLists.txt | 2 +- 14 files changed, 14 insertions(+), 14 deletions(-) diff --git a/examples/all_device_types_app/CMakeLists.txt b/examples/all_device_types_app/CMakeLists.txt index c8d9b375c..37569540b 100644 --- a/examples/all_device_types_app/CMakeLists.txt +++ b/examples/all_device_types_app/CMakeLists.txt @@ -37,7 +37,7 @@ set(EXTRA_COMPONENT_DIRS project(all_device_types_app) -idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H" APPEND) +idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H;-Wno-overloaded-virtual" APPEND) idf_build_set_property(C_COMPILE_OPTIONS "-Os" APPEND) # For RISCV chips, project_include.cmake sets -Wno-format, but does not clear various # flags that depend on -Wformat diff --git a/examples/blemesh_bridge/CMakeLists.txt b/examples/blemesh_bridge/CMakeLists.txt index b79c59f1e..9b69b502a 100644 --- a/examples/blemesh_bridge/CMakeLists.txt +++ b/examples/blemesh_bridge/CMakeLists.txt @@ -37,7 +37,7 @@ set(EXTRA_COMPONENT_DIRS project(blemesh_bridge) -idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H;-fpermissive" APPEND) +idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H;-fpermissive;-Wno-overloaded-virtual" APPEND) idf_build_set_property(C_COMPILE_OPTIONS "-Os" APPEND) # For RISCV chips, project_include.cmake sets -Wno-format, but does not clear various # flags that depend on -Wformat diff --git a/examples/controller/CMakeLists.txt b/examples/controller/CMakeLists.txt index f0e3ace13..d0d1befa1 100644 --- a/examples/controller/CMakeLists.txt +++ b/examples/controller/CMakeLists.txt @@ -34,7 +34,7 @@ set(EXTRA_COMPONENT_DIRS project(controller) -idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H" APPEND) +idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H;-Wno-overloaded-virtual" APPEND) idf_build_set_property(C_COMPILE_OPTIONS "-Os" APPEND) # For RISCV chips, project_include.cmake sets -Wno-format, but does not clear various diff --git a/examples/demo/badge/CMakeLists.txt b/examples/demo/badge/CMakeLists.txt index fffa101e1..f6e2efb9c 100644 --- a/examples/demo/badge/CMakeLists.txt +++ b/examples/demo/badge/CMakeLists.txt @@ -39,7 +39,7 @@ if(CONFIG_ENABLE_ENCRYPTED_OTA) target_add_binary_data(light.elf "esp_image_encryption_key.pem" TEXT) endif() -idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H" APPEND) +idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H;-Wno-overloaded-virtual" APPEND) idf_build_set_property(C_COMPILE_OPTIONS "-Os" APPEND) # For RISCV chips, project_include.cmake sets -Wno-format, but does not clear various # flags that depend on -Wformat diff --git a/examples/esp-now_bridge_light/CMakeLists.txt b/examples/esp-now_bridge_light/CMakeLists.txt index ff4abb240..65dbe2abd 100644 --- a/examples/esp-now_bridge_light/CMakeLists.txt +++ b/examples/esp-now_bridge_light/CMakeLists.txt @@ -37,7 +37,7 @@ set(EXTRA_COMPONENT_DIRS project(espnow_light) -idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H" APPEND) +idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H;-Wno-overloaded-virtual" APPEND) idf_build_set_property(C_COMPILE_OPTIONS "-Os" APPEND) # For RISCV chips, project_include.cmake sets -Wno-format, but does not clear various # flags that depend on -Wformat diff --git a/examples/generic_switch/CMakeLists.txt b/examples/generic_switch/CMakeLists.txt index 98946f8dd..8406f4eec 100644 --- a/examples/generic_switch/CMakeLists.txt +++ b/examples/generic_switch/CMakeLists.txt @@ -46,7 +46,7 @@ if(CONFIG_IDF_TARGET_ESP32C2) include(relinker) endif() -idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H" APPEND) +idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H;-Wno-overloaded-virtual" APPEND) idf_build_set_property(C_COMPILE_OPTIONS "-Os" APPEND) # For RISCV chips, project_include.cmake sets -Wno-format, but does not clear various # flags that depend on -Wformat diff --git a/examples/icd_app/CMakeLists.txt b/examples/icd_app/CMakeLists.txt index 3eb277396..784b9b4da 100644 --- a/examples/icd_app/CMakeLists.txt +++ b/examples/icd_app/CMakeLists.txt @@ -35,7 +35,7 @@ set(EXTRA_COMPONENT_DIRS project(icd_app) -idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H;-DCONFIG_OPENTHREAD_CONFIG_SRP_CLIENT_BUFFERS_MAX_SERVICES=5" APPEND) +idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H;-DCONFIG_OPENTHREAD_CONFIG_SRP_CLIENT_BUFFERS_MAX_SERVICES=5;-Wno-overloaded-virtual" APPEND) idf_build_set_property(C_COMPILE_OPTIONS "-Os;-DCONFIG_OPENTHREAD_CONFIG_SRP_CLIENT_BUFFERS_MAX_SERVICES=5" APPEND) # For RISCV chips, project_include.cmake sets -Wno-format, but does not clear various # flags that depend on -Wformat diff --git a/examples/light/CMakeLists.txt b/examples/light/CMakeLists.txt index 435ebf1a0..a54a069e6 100644 --- a/examples/light/CMakeLists.txt +++ b/examples/light/CMakeLists.txt @@ -33,7 +33,7 @@ if(CONFIG_IDF_TARGET_ESP32C2) include(relinker) endif() -idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H" APPEND) +idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H;-Wno-overloaded-virtual" APPEND) idf_build_set_property(C_COMPILE_OPTIONS "-Os" APPEND) # For RISCV chips, project_include.cmake sets -Wno-format, but does not clear various # flags that depend on -Wformat diff --git a/examples/light_switch/CMakeLists.txt b/examples/light_switch/CMakeLists.txt index 0fab4effe..57eb801f5 100644 --- a/examples/light_switch/CMakeLists.txt +++ b/examples/light_switch/CMakeLists.txt @@ -46,7 +46,7 @@ if(CONFIG_IDF_TARGET_ESP32C2) include(relinker) endif() -idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H" APPEND) +idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H;-Wno-overloaded-virtual" APPEND) idf_build_set_property(C_COMPILE_OPTIONS "-Os" APPEND) # For RISCV chips, project_include.cmake sets -Wno-format, but does not clear various # flags that depend on -Wformat diff --git a/examples/mfg_test_app/CMakeLists.txt b/examples/mfg_test_app/CMakeLists.txt index 43762e561..1062e671a 100644 --- a/examples/mfg_test_app/CMakeLists.txt +++ b/examples/mfg_test_app/CMakeLists.txt @@ -21,7 +21,7 @@ set(EXTRA_COMPONENT_DIRS project(mfg_test_app) -idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H" APPEND) +idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H;-Wno-overloaded-virtual" APPEND) idf_build_set_property(C_COMPILE_OPTIONS "-Os" APPEND) # For RISCV chips, project_include.cmake sets -Wno-format, but does not clear various # flags that depend on -Wformat diff --git a/examples/refrigerator/CMakeLists.txt b/examples/refrigerator/CMakeLists.txt index a83eed68e..d9d17b1b1 100644 --- a/examples/refrigerator/CMakeLists.txt +++ b/examples/refrigerator/CMakeLists.txt @@ -47,7 +47,7 @@ if(CONFIG_IDF_TARGET_ESP32C2) include(relinker) endif() -idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H" APPEND) +idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H;-Wno-overloaded-virtual" APPEND) idf_build_set_property(C_COMPILE_OPTIONS "-Os" APPEND) # For RISCV chips, project_include.cmake sets -Wno-format, but does not clear various # flags that depend on -Wformat diff --git a/examples/room_air_conditioner/CMakeLists.txt b/examples/room_air_conditioner/CMakeLists.txt index af31b9bed..065263544 100644 --- a/examples/room_air_conditioner/CMakeLists.txt +++ b/examples/room_air_conditioner/CMakeLists.txt @@ -53,7 +53,7 @@ if(CONFIG_IDF_TARGET_ESP32C2) include(relinker) endif() -idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H" APPEND) +idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H;-Wno-overloaded-virtual" APPEND) idf_build_set_property(C_COMPILE_OPTIONS "-Os" APPEND) # For RISCV chips, project_include.cmake sets -Wno-format, but does not clear various # flags that depend on -Wformat diff --git a/examples/zap_light/CMakeLists.txt b/examples/zap_light/CMakeLists.txt index 9157024cc..291758199 100644 --- a/examples/zap_light/CMakeLists.txt +++ b/examples/zap_light/CMakeLists.txt @@ -46,7 +46,7 @@ if(CONFIG_IDF_TARGET_ESP32C2) include(relinker) endif() -idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H" APPEND) +idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H;-Wno-overloaded-virtual" APPEND) idf_build_set_property(C_COMPILE_OPTIONS "-Os" APPEND) # For RISCV chips, project_include.cmake sets -Wno-format, but does not clear various # flags that depend on -Wformat diff --git a/examples/zigbee_bridge/CMakeLists.txt b/examples/zigbee_bridge/CMakeLists.txt index 312c79dbb..7c885e597 100644 --- a/examples/zigbee_bridge/CMakeLists.txt +++ b/examples/zigbee_bridge/CMakeLists.txt @@ -36,7 +36,7 @@ set(EXTRA_COMPONENT_DIRS project(zigbee_bridge) -idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H;-fpermissive" APPEND) +idf_build_set_property(CXX_COMPILE_OPTIONS "-std=gnu++17;-Os;-DCHIP_HAVE_CONFIG_H;-fpermissive;-Wno-overloaded-virtual" APPEND) idf_build_set_property(C_COMPILE_OPTIONS "-Os" APPEND) # For RISCV chips, project_include.cmake sets -Wno-format, but does not clear various # flags that depend on -Wformat