I’ve made some progress against that, first I’ve managed to compile a project with framework=arduino,espidf on Windows. Then I activated WSL and compiled the same project successfully.
Tried with including esp-matter as a managed-component by adding idf_component.yml
file with following content:
dependencies:
espressif/esp_matter:
version: "^0.0.2"
Had this error:
root@HamzaHajeir:~/h4plugins_espidf# pio run -e esp32s3-devkitc
Processing esp32s3-devkitc (board: esp32-s3-devkitc-1; platform: https://github.com/pioarduino/platform-espressif32/releases/download/51.03.04/platform-espressif32.zip; framework: arduino, espidf)
-----------------------------------------------------------------------------------------------------------------------------------------------
Verbose mode can be enabled via `-v, --verbose` option
CONFIGURATION: https://docs.platformio.org/page/boards/espressif32/esp32-s3-devkitc-1.html
PLATFORM: Espressif 32 (51.3.4) > Espressif ESP32-S3-DevKitC-1-N8 (8 MB QD, No PSRAM)
HARDWARE: ESP32S3 240MHz, 320KB RAM, 8MB Flash
DEBUG: Current (esp-builtin) On-board (esp-builtin) External (cmsis-dap, esp-bridge, esp-prog, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa)
PACKAGES:
- framework-arduinoespressif32 @ 3.0.3+sha.b6b4727
- framework-arduinoespressif32-libs @ 5.1.0+sha.b6b4727
- framework-espidf @ 3.50104.0 (5.1.4)
- tool-cmake @ 3.21.3
- tool-esptoolpy @ 4.7.5
- tool-mklittlefs @ 3.2.0
- tool-ninja @ 1.7.1
- tool-riscv32-esp-elf-gdb @ 12.1.0+20221002
- tool-xtensa-esp-elf-gdb @ 12.1.0+20221002
- toolchain-esp32ulp @ 1.23500.220830 (2.35.0)
- toolchain-riscv32-esp @ 12.2.0+20230208
- toolchain-xtensa-esp32s3 @ 12.2.0+20230208
Warning! Arduino framework as an ESP-IDF component doesn't handle the `variant` field! The default `esp32` variant will be used.
Reading CMake configuration...
-- Found Git: /usr/bin/git (found version "2.43.0")
-- git rev-parse returned 'fatal: not a git repository (or any of the parent directories): .git'
-- The C compiler identification is GNU 12.2.0
-- The CXX compiler identification is GNU 12.2.0
-- The ASM compiler identification is GNU
-- Found assembler: /root/.platformio/packages/toolchain-xtensa-esp32s3/bin/xtensa-esp32s3-elf-gcc
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /root/.platformio/packages/toolchain-xtensa-esp32s3/bin/xtensa-esp32s3-elf-gcc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /root/.platformio/packages/toolchain-xtensa-esp32s3/bin/xtensa-esp32s3-elf-g++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Building ESP-IDF components for target esp32s3
Manifest files have changed, solving dependencies.
...........................................Updating lock file at /root/h4plugins_espidf/dependencies.lock
Processing 26 dependencies:
[1/26] chmorgan/esp-libhelix-mp3 (1.0.3)
[2/26] espressif/cbor (0.6.0~1)
[3/26] espressif/esp-dsp (1.5.2)
[4/26] espressif/esp-modbus (1.0.15)
[5/26] espressif/esp-sr (1.9.0)
[6/26] espressif/esp-zboss-lib (1.5.0)
[7/26] espressif/esp-zigbee-lib (1.5.0)
[8/26] espressif/esp_diag_data_store (1.0.1)
[9/26] espressif/esp_diagnostics (1.0.2)
[10/26] espressif/esp_encrypted_img (2.1.0)
[11/26] espressif/esp_insights (1.0.1)
[12/26] espressif/esp_matter (0.0.2)
[13/26] espressif/esp_modem (1.1.0)
[14/26] espressif/esp_rainmaker (1.4.0)
[15/26] espressif/esp_schedule (1.2.0)
[16/26] espressif/esp_secure_cert_mgr (2.4.1)
[17/26] espressif/jsmn (1.1.0)
[18/26] espressif/json_generator (1.1.2)
[19/26] espressif/json_parser (1.0.3)
[20/26] espressif/libsodium (1.0.20~1)
[21/26] espressif/mdns (1.4.0)
[22/26] espressif/network_provisioning (1.0.1)
[23/26] espressif/qrcode (0.1.0~2)
[24/26] espressif/rmaker_common (1.4.6)
[25/26] idf (5.1.4)
[26/26] joltwallet/littlefs (1.14.8)
-- Configuring incomplete, errors occurred!
See also "/root/h4plugins_espidf/.pio/build/esp32s3-devkitc/CMakeFiles/CMakeOutput.log".
fatal: not a git repository (or any of the parent directories): .git
CMake Error at /root/.platformio/packages/framework-espidf/tools/cmake/build.cmake:540 (message):
ERROR: Some components (espressif/esp_matter) in the "managed_components"
directory were modified on the disk since the last run of the CMake.
Content of this directory is managed automatically.
If you want to keep the changes, you can move the directory with the
component to the "components"directory of your project.
I.E. for "espressif__esp_matter" run:
mv /root/h4plugins_espidf/managed_components/espressif__esp_matter
/root/h4plugins_espidf/components/espressif__esp_matter
Or, if you want to discard the changes remove the ".component_hash" file
from the component's directory.
I.E. for "espressif__esp_matter" run:
rm
/root/h4plugins_espidf/managed_coZmponents/espressif__esp_matter/.component_hash
Call Stack (most recent call first):
/root/.platformio/packages/framework-espidf/tools/cmake/project.cmake:604 (idf_build_process)
CMakeLists.txt:7 (project)
Then I removed the component_hash file, then got another error:
root@HamzaHajeir:~/h4plugins_espidf# pio run -e esp32s3-devkitc
Processing esp32s3-devkitc (board: esp32-s3-devkitc-1; platform: https://github.com/pioarduino/platform-espressif32/releases/download/51.03.04/platform-espressif32.zip; framework: arduino, espidf)
----------------------------------------------------------------------------------------------------------------------------------
Verbose mode can be enabled via `-v, --verbose` option
CONFIGURATION: https://docs.platformio.org/page/boards/espressif32/esp32-s3-devkitc-1.html
PLATFORM: Espressif 32 (51.3.4) > Espressif ESP32-S3-DevKitC-1-N8 (8 MB QD, No PSRAM)
HARDWARE: ESP32S3 240MHz, 320KB RAM, 8MB Flash
DEBUG: Current (esp-builtin) On-board (esp-builtin) External (cmsis-dap, esp-bridge, esp-prog, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa)
PACKAGES:
- framework-arduinoespressif32 @ 3.0.3+sha.b6b4727
- framework-arduinoespressif32-libs @ 5.1.0+sha.b6b4727
- framework-espidf @ 3.50104.0 (5.1.4)
- tool-cmake @ 3.21.3
- tool-esptoolpy @ 4.7.5
- tool-mklittlefs @ 3.2.0
- tool-ninja @ 1.7.1
- tool-riscv32-esp-elf-gdb @ 12.1.0+20221002
- tool-xtensa-esp-elf-gdb @ 12.1.0+20221002
- toolchain-esp32ulp @ 1.23500.220830 (2.35.0)
- toolchain-riscv32-esp @ 12.2.0+20230208
- toolchain-xtensa-esp32s3 @ 12.2.0+20230208
Warning! Arduino framework as an ESP-IDF component doesn't handle the `variant` field! The default `esp32` variant will be used.
Reading CMake configuration...
-- git rev-parse returned 'fatal: not a git repository (or any of the parent directories): .git'
-- Building ESP-IDF components for target esp32s3
Processing 26 dependencies:
[1/26] chmorgan/esp-libhelix-mp3 (1.0.3)
[2/26] espressif/cbor (0.6.0~1)
[3/26] espressif/esp-dsp (1.5.2)
[4/26] espressif/esp-modbus (1.0.15)
[5/26] espressif/esp-sr (1.9.0)
[6/26] espressif/esp-zboss-lib (1.5.0)
[7/26] espressif/esp-zigbee-lib (1.5.0)
[8/26] espressif/esp_diag_data_store (1.0.1)
[9/26] espressif/esp_diagnostics (1.0.2)
[10/26] espressif/esp_encrypted_img (2.1.0)
[11/26] espressif/esp_insights (1.0.1)
[12/26] espressif/esp_matter (0.0.2)
[13/26] espressif/esp_modem (1.1.0)
[14/26] espressif/esp_rainmaker (1.4.0)
[15/26] espressif/esp_schedule (1.2.0)
[16/26] espressif/esp_secure_cert_mgr (2.4.1)
[17/26] espressif/jsmn (1.1.0)
[18/26] espressif/json_generator (1.1.2)
[19/26] espressif/json_parser (1.0.3)
[20/26] espressif/libsodium (1.0.20~1)
[21/26] espressif/mdns (1.4.0)
[22/26] espressif/network_provisioning (1.0.1)
[23/26] espressif/qrcode (0.1.0~2)
[24/26] espressif/rmaker_common (1.4.6)
[25/26] idf (5.1.4)
[26/26] joltwallet/littlefs (1.14.8)
-- DEBUG: Use esp-modbus component folder: /root/h4plugins_espidf/managed_components/espressif__esp-modbus.
-- Found Python3: /root/.platformio/penv/.espidf-5.1.4/bin/python3 (found version "3.12.3") found components: Interpreter
-- Project sdkconfig file /root/h4plugins_espidf/sdkconfig.esp32s3-devkitc
Loading defaults file /root/h4plugins_espidf/sdkconfig.defaults...
-- Looking for sys/types.h
-- Looking for sys/types.h - found
-- Looking for stdint.h
-- Looking for stdint.h - found
-- Looking for stddef.h
-- Looking for stddef.h - found
-- Check size of time_t
-- Check size of time_t - done
-- Found Python3: /root/.platformio/penv/.espidf-5.1.4/bin/python (found version "3.12.3") found components: Interpreter
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Failed
-- Check if compiler accepts -pthread
-- Check if compiler accepts -pthread - no
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - not found
-- Could NOT find Threads (missing: Threads_FOUND)
-- Performing Test C_COMPILER_SUPPORTS_WFORMAT_SIGNEDNESS
-- Performing Test C_COMPILER_SUPPORTS_WFORMAT_SIGNEDNESS - Success
-- App "ArduinoESPIDF_Test" version: 1.0
-- Adding linker script /root/h4plugins_espidf/.pio/build/esp32s3-devkitc/esp-idf/esp_system/ld/memory.ld
-- Adding linker script /root/.platformio/packages/framework-espidf/components/esp_system/ld/esp32s3/sections.ld.in
-- Adding linker script /root/.platformio/packages/framework-espidf/components/esp_rom/esp32s3/ld/esp32s3.rom.ld
-- Adding linker script /root/.platformio/packages/framework-espidf/components/esp_rom/esp32s3/ld/esp32s3.rom.api.ld
-- Adding linker script /root/.platformio/packages/framework-espidf/components/esp_rom/esp32s3/ld/esp32s3.rom.libgcc.ld
-- Adding linker script /root/.platformio/packages/framework-espidf/components/esp_rom/esp32s3/ld/esp32s3.rom.newlib.ld
-- Adding linker script /root/.platformio/packages/framework-espidf/components/esp_rom/esp32s3/ld/esp32s3.rom.version.ld
-- Adding linker script /root/.platformio/packages/framework-espidf/components/soc/esp32s3/ld/esp32s3.peripherals.ld
-- DEBUG: Use esp-modbus component folder: /root/h4plugins_espidf/managed_components/espressif__esp-modbus.
-- Components: __pio_env app_trace app_update bootloader bootloader_support bt chmorgan__esp-libhelix-mp3 cmock console cxx driver efuse esp-tls esp_adc esp_app_format esp_coex esp_common esp_eth esp_event esp_gdbstub esp_hid esp_http_client esp_http_server esp_https_ota esp_https_server esp_hw_support esp_lcd esp_local_ctrl esp_mm esp_netif esp_netif_stack esp_partition esp_phy esp_pm esp_psram esp_ringbuf esp_rom esp_system esp_timer esp_wifi espcoredump espressif__cbor espressif__esp-dsp espressif__esp-modbus espressif__esp-sr espressif__esp-zboss-lib espressif__esp-zigbee-lib espressif__esp_diag_data_store espressif__esp_diagnostics espressif__esp_encrypted_img espressif__esp_insights espressif__esp_matter espressif__esp_modem espressif__esp_rainmaker espressif__esp_schedule espressif__esp_secure_cert_mgr espressif__jsmn espressif__json_generator espressif__json_parser espressif__libsodium espressif__mdns espressif__network_provisioning espressif__qrcode espressif__rmaker_common esptool_py fatfs framework-arduinoespressif32 freertos hal heap http_parser idf_test ieee802154 joltwallet__littlefs json log lwip mbedtls mqtt newlib nvs_flash openthread partition_table perfmon protobuf-c protocomm pthread sdmmc soc spi_flash spiffs src tcp_transport touch_element ulp unity usb vfs wear_levelling wifi_provisioning wpa_supplicant xtensa
-- Component paths: /root/.platformio/packages/framework-espidf/components/__pio_env /root/.platformio/packages/framework-espidf/components/app_trace /root/.platformio/packages/framework-espidf/components/app_update /root/.platformio/packages/framework-espidf/components/bootloader /root/.platformio/packages/framework-espidf/components/bootloader_support /root/.platformio/packages/framework-espidf/components/bt /root/h4plugins_espidf/managed_components/chmorgan__esp-libhelix-mp3 /root/.platformio/packages/framework-espidf/components/cmock /root/.platformio/packages/framework-espidf/components/console /root/.platformio/packages/framework-espidf/components/cxx /root/.platformio/packages/framework-espidf/components/driver /root/.platformio/packages/framework-espidf/components/efuse /root/.platformio/packages/framework-espidf/components/esp-tls /root/.platformio/packages/framework-espidf/components/esp_adc /root/.platformio/packages/framework-espidf/components/esp_app_format /root/.platformio/packages/framework-espidf/components/esp_coex /root/.platformio/packages/framework-espidf/components/esp_common /root/.platformio/packages/framework-espidf/components/esp_eth /root/.platformio/packages/framework-espidf/components/esp_event /root/.platformio/packages/framework-espidf/components/esp_gdbstub /root/.platformio/packages/framework-espidf/components/esp_hid /root/.platformio/packages/framework-espidf/components/esp_http_client /root/.platformio/packages/framework-espidf/components/esp_http_server /root/.platformio/packages/framework-espidf/components/esp_https_ota /root/.platformio/packages/framework-espidf/components/esp_https_server /root/.platformio/packages/framework-espidf/components/esp_hw_support /root/.platformio/packages/framework-espidf/components/esp_lcd /root/.platformio/packages/framework-espidf/components/esp_local_ctrl /root/.platformio/packages/framework-espidf/components/esp_mm /root/.platformio/packages/framework-espidf/components/esp_netif /root/.platformio/packages/framework-espidf/components/esp_netif_stack /root/.platformio/packages/framework-espidf/components/esp_partition /root/.platformio/packages/framework-espidf/components/esp_phy /root/.platformio/packages/framework-espidf/components/esp_pm /root/.platformio/packages/framework-espidf/components/esp_psram /root/.platformio/packages/framework-espidf/components/esp_ringbuf /root/.platformio/packages/framework-espidf/components/esp_rom /root/.platformio/packages/framework-espidf/components/esp_system /root/.platformio/packages/framework-espidf/components/esp_timer /root/.platformio/packages/framework-espidf/components/esp_wifi /root/.platformio/packages/framework-espidf/components/espcoredump /root/h4plugins_espidf/managed_components/espressif__cbor /root/h4plugins_espidf/managed_components/espressif__esp-dsp /root/h4plugins_espidf/managed_components/espressif__esp-modbus /root/h4plugins_espidf/managed_components/espressif__esp-sr /root/h4plugins_espidf/managed_components/espressif__esp-zboss-lib /root/h4plugins_espidf/managed_components/espressif__esp-zigbee-lib /root/h4plugins_espidf/managed_components/espressif__esp_diag_data_store /root/h4plugins_espidf/managed_components/espressif__esp_diagnostics /root/h4plugins_espidf/managed_components/espressif__esp_encrypted_img /root/h4plugins_espidf/managed_components/espressif__esp_insights /root/h4plugins_espidf/managed_components/espressif__esp_matter /root/h4plugins_espidf/managed_components/espressif__esp_modem /root/h4plugins_espidf/managed_components/espressif__esp_rainmaker /root/h4plugins_espidf/managed_components/espressif__esp_schedule /root/h4plugins_espidf/managed_components/espressif__esp_secure_cert_mgr /root/h4plugins_espidf/managed_components/espressif__jsmn /root/h4plugins_espidf/managed_components/espressif__json_generator /root/h4plugins_espidf/managed_components/espressif__json_parser /root/h4plugins_espidf/managed_components/espressif__libsodium /root/h4plugins_espidf/managed_components/espressif__mdns /root/h4plugins_espidf/managed_components/espressif__network_provisioning /root/h4plugins_espidf/managed_components/espressif__qrcode /root/h4plugins_espidf/managed_components/espressif__rmaker_common /root/.platformio/packages/framework-espidf/components/esptool_py /root/.platformio/packages/framework-espidf/components/fatfs /root/.platformio/packages/framework-arduinoespressif32 /root/.platformio/packages/framework-espidf/components/freertos /root/.platformio/packages/framework-espidf/components/hal /root/.platformio/packages/framework-espidf/components/heap /root/.platformio/packages/framework-espidf/components/http_parser /root/.platformio/packages/framework-espidf/components/idf_test /root/.platformio/packages/framework-espidf/components/ieee802154 /root/h4plugins_espidf/managed_components/joltwallet__littlefs /root/.platformio/packages/framework-espidf/components/json /root/.platformio/packages/framework-espidf/components/log /root/h4plugins_espidf/components/lwip /root/.platformio/packages/framework-espidf/components/mbedtls /root/.platformio/packages/framework-espidf/components/mqtt /root/.platformio/packages/framework-espidf/components/newlib /root/.platformio/packages/framework-espidf/components/nvs_flash /root/.platformio/packages/framework-espidf/components/openthread /root/.platformio/packages/framework-espidf/components/partition_table /root/.platformio/packages/framework-espidf/components/perfmon /root/.platformio/packages/framework-espidf/components/protobuf-c /root/.platformio/packages/framework-espidf/components/protocomm /root/.platformio/packages/framework-espidf/components/pthread /root/.platformio/packages/framework-espidf/components/sdmmc /root/.platformio/packages/framework-espidf/components/soc /root/.platformio/packages/framework-espidf/components/spi_flash /root/.platformio/packages/framework-espidf/components/spiffs /root/h4plugins_espidf/src /root/.platformio/packages/framework-espidf/components/tcp_transport /root/.platformio/packages/framework-espidf/components/touch_element /root/.platformio/packages/framework-espidf/components/ulp /root/.platformio/packages/framework-espidf/components/unity /root/.platformio/packages/framework-espidf/components/usb /root/.platformio/packages/framework-espidf/components/vfs /root/.platformio/packages/framework-espidf/components/wear_levelling /root/.platformio/packages/framework-espidf/components/wifi_provisioning /root/.platformio/packages/framework-espidf/components/wpa_supplicant /root/.platformio/packages/framework-espidf/components/xtensa
-- Configuring incomplete, errors occurred!
See also "/root/h4plugins_espidf/.pio/build/esp32s3-devkitc/CMakeFiles/CMakeOutput.log".
See also "/root/h4plugins_espidf/.pio/build/esp32s3-devkitc/CMakeFiles/CMakeError.log".
fatal: not a git repository (or any of the parent directories): .git
warning: default on the choice symbol SEC_CERT_DAC_PROVIDER (defined at managed_components/espressif__esp_matter/connectedhomeip/connectedhomeip/config/esp32/components/chip/Kconfig:874, managed_components/espressif__esp_matter/components/esp_matter/Kconfig:48) will have no effect, as defaults do not affect choice symbols
warning: the choice symbol SEC_CERT_DAC_PROVIDER (defined at managed_components/espressif__esp_matter/connectedhomeip/connectedhomeip/config/esp32/components/chip/Kconfig:874, managed_components/espressif__esp_matter/components/esp_matter/Kconfig:48) is defined with a prompt outside the choice
Compiler supported targets: xtensa-esp32s3-elf
fatal: not a git repository (or any of the parent directories): .git
fatal: not a git repository (or any of the parent directories): .git
ESP Insights Project commit: 5fae46f-dirty
CMake Error at /root/.platformio/packages/framework-espidf/tools/cmake/component.cmake:381 (__component_get_property):
__component_get_property Function invoked with incorrect arguments for
function named: __component_get_property
Call Stack (most recent call first):
managed_components/espressif__esp_matter/CMakeLists.txt:435 (idf_component_get_property)
ESP RainMaker Project commit: 5fae46f-dirty
Is is completely esp-idf issue? or I missed up some config by a previous setup?