Skip to content

Commit 7199b22

Browse files
Jason2866me-no-dev
andauthored
Fix standalone component build and enable CI check for it (espressif#8743) (#282)
Fixes: espressif#8740 Co-authored-by: Me No Dev <[email protected]>
1 parent d647dec commit 7199b22

File tree

3 files changed

+32
-28
lines changed

3 files changed

+32
-28
lines changed

Diff for: .github/workflows/push.yml

+27-27
Original file line numberDiff line numberDiff line change
@@ -82,30 +82,30 @@ jobs:
8282
- name: Build Sketches
8383
run: bash ./.github/scripts/on-push.sh 1 1 #equal and non-zero to trigger PIO
8484

85-
# build-esp-idf-component:
86-
# name: Build with ESP-IDF ${{ matrix.idf_ver }} for ${{ matrix.idf_target }}
87-
# runs-on: ubuntu-20.04
88-
# strategy:
89-
# matrix:
90-
# # The version names here correspond to the versions of espressif/idf Docker image.
91-
# # See https://hub.docker.com/r/espressif/idf/tags and
92-
# # https://docs.espressif.com/projects/esp-idf/en/latest/esp32/api-guides/tools/idf-docker-image.html
93-
# # for details.
94-
# idf_ver: ["release-v4.4"]
95-
# idf_target: ["esp32", "esp32s2", "esp32s3", "esp32c3"]
96-
# container: espressif/idf:${{ matrix.idf_ver }}
97-
# steps:
98-
# - name: Check out arduino-esp32 as a component
99-
# uses: actions/checkout@v3
100-
# with:
101-
# submodules: recursive
102-
# path: components/arduino-esp32
103-
# - name: Build
104-
# env:
105-
# IDF_TARGET: ${{ matrix.idf_target }}
106-
# shell: bash
107-
# run: |
108-
# . ${IDF_PATH}/export.sh
109-
# idf.py create-project test
110-
# echo CONFIG_FREERTOS_HZ=1000 > test/sdkconfig.defaults
111-
# idf.py -C test -DEXTRA_COMPONENT_DIRS=$PWD/components build
85+
build-esp-idf-component:
86+
name: Build with ESP-IDF ${{ matrix.idf_ver }} for ${{ matrix.idf_target }}
87+
runs-on: ubuntu-20.04
88+
strategy:
89+
matrix:
90+
# The version names here correspond to the versions of espressif/idf Docker image.
91+
# See https://hub.docker.com/r/espressif/idf/tags and
92+
# https://docs.espressif.com/projects/esp-idf/en/latest/esp32/api-guides/tools/idf-docker-image.html
93+
# for details.
94+
idf_ver: ["release-v5.1"]
95+
idf_target: ["esp32", "esp32s2", "esp32s3", "esp32c3", "esp32c6", "esp32h2"]
96+
container: espressif/idf:${{ matrix.idf_ver }}
97+
steps:
98+
- name: Check out arduino-esp32 as a component
99+
uses: actions/checkout@v3
100+
with:
101+
submodules: recursive
102+
path: components/arduino-esp32
103+
- name: Build
104+
env:
105+
IDF_TARGET: ${{ matrix.idf_target }}
106+
shell: bash
107+
run: |
108+
. ${IDF_PATH}/export.sh
109+
idf.py create-project test
110+
echo CONFIG_FREERTOS_HZ=1000 > test/sdkconfig.defaults
111+
idf.py -C test -DEXTRA_COMPONENT_DIRS=$PWD/components build

Diff for: CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ set(includedirs
158158

159159
set(srcs ${CORE_SRCS} ${LIBRARY_SRCS})
160160
set(priv_includes cores/esp32/libb64)
161-
set(requires spi_flash mbedtls mdns wifi_provisioning wpa_supplicant esp_adc esp_eth http_parser)
161+
set(requires spi_flash mbedtls wifi_provisioning wpa_supplicant esp_adc esp_eth http_parser)
162162
set(priv_requires fatfs nvs_flash app_update bootloader_support bt esp_hid)
163163

164164
idf_component_register(INCLUDE_DIRS ${includedirs} PRIV_INCLUDE_DIRS ${priv_includes} SRCS ${srcs} REQUIRES ${requires} PRIV_REQUIRES ${priv_requires})

Diff for: idf_component.yml

+4
Original file line numberDiff line numberDiff line change
@@ -25,3 +25,7 @@ files:
2525
- "Kconfig.projbuild"
2626
exclude:
2727
- "**/*"
28+
dependencies:
29+
idf: ">=5.1"
30+
mdns: "^1.1.0"
31+
chmorgan/esp-libhelix-mp3: "1.0.3"

0 commit comments

Comments
 (0)