Skip to content

Commit 777d0d7

Browse files
authored
fix(idf): Require openthread on H2 and C6 (#9934)
Fixes IDF builds for H2 and C6 when OpenThread is enabled
1 parent 65204d9 commit 777d0d7

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

Diff for: CMakeLists.txt

+8
Original file line numberDiff line numberDiff line change
@@ -296,6 +296,14 @@ set(priv_includes cores/esp32/libb64)
296296
set(requires spi_flash esp_partition mbedtls wifi_provisioning wpa_supplicant esp_adc esp_eth http_parser)
297297
set(priv_requires fatfs nvs_flash app_update spiffs bootloader_support bt esp_hid usb esp_psram ${ARDUINO_LIBRARIES_REQUIRES})
298298

299+
if(NOT CONFIG_ARDUINO_SELECTIVE_COMPILATION OR CONFIG_ARDUINO_SELECTIVE_OpenThread)
300+
#if(CONFIG_SOC_IEEE802154_SUPPORTED) # Does not work!
301+
#if(CONFIG_OPENTHREAD_ENABLED) # Does not work!
302+
if(IDF_TARGET STREQUAL "esp32c6" OR IDF_TARGET STREQUAL "esp32h2") # Sadly only this works
303+
list(APPEND requires openthread)
304+
endif()
305+
endif()
306+
299307
idf_component_register(INCLUDE_DIRS ${includedirs} PRIV_INCLUDE_DIRS ${priv_includes} SRCS ${srcs} REQUIRES ${requires} PRIV_REQUIRES ${priv_requires})
300308

301309
if(NOT CONFIG_FREERTOS_HZ EQUAL 1000 AND NOT "$ENV{ARDUINO_SKIP_TICK_CHECK}")

0 commit comments

Comments
 (0)