File tree Expand file tree Collapse file tree 3 files changed +58
-2
lines changed
Expand file tree Collapse file tree 3 files changed +58
-2
lines changed Original file line number Diff line number Diff line change @@ -293,6 +293,15 @@ RUN mkdir -p wamrc && \
293293 curl -s -L "https://github.com/bytecodealliance/wasm-micro-runtime/releases/download/WAMR-1.1.2/wamrc-1.1.2-x86_64-ubuntu-20.04.tar.gz" \
294294 | tar -C wamrc -xz
295295
296+ # ##############################################################################
297+ # Build image for tool required by Raspberry Pi pico-sdk builds
298+ # ##############################################################################
299+ FROM nuttx-toolchain-base AS nuttx-toolchain-raspberrypi-pico-sdk
300+ # Download the latest pico-sdk source archive
301+ RUN mkdir -p pico-sdk && \
302+ curl -s -L "https://github.com/raspberrypi/pico-sdk/releases/download/2.2.0/pico-sdk-2.2.0.tar.gz" \
303+ | tar -C pico-sdk --strip-components 1 -xz
304+
296305# ##############################################################################
297306# Final Docker image used for running CI system. This includes all toolchains
298307# supported by the CI system.
@@ -478,6 +487,11 @@ COPY --from=nuttx-toolchain-esp32 /tools/blobs/* /tools/blobs/esp-bins/
478487COPY --from=nuttx-toolchain-wasm /tools/wasi-sdk/ wasi-sdk/
479488ENV WASI_SDK_PATH="/tools/wasi-sdk"
480489ENV PATH="/tools/wamr:$PATH"
490+ COPY --from=nuttx-toolchain-esp32 /tools/blobs/* /tools/blobs/esp-bins/
491+
492+ # Raspberry Pi pico-sdk source
493+ COPY --from=nuttx-toolchain-raspberrypi-pico-sdk /tools/pico-sdk/ pico-sdk/
494+ ENV PICO_SDK_PATH="/tools/pico-sdk"
481495
482496# gn tool
483497RUN mkdir -p /tools/gn
Original file line number Diff line number Diff line change @@ -299,6 +299,27 @@ wasi_sdk() {
299299 command wamrc --version
300300}
301301
302+ raspberrypi_pico_sdk () {
303+ if [ ! -f " ${NUTTXTOOLS} /pico-sdk" ]; then
304+ local release
305+ local basefile
306+ release=" 2.2.0"
307+ basefile=" pico-sdk-${release} "
308+ cd " ${NUTTXTOOLS} "
309+ mkdir -p pico-sdk
310+
311+ # Download the latest pico-sdk source archive
312+ curl -O -L -s https://github.com/raspberrypi/pico-sdk/releases/download/${release} /${basefile} .tar.gz
313+ tar xzf " ${basefile} .tar.gz"
314+ mv " ${basefile} " pico-sdk
315+ rm " ${basefile} .tar.gz"
316+
317+ fi
318+
319+ export PICO_SDK_PATH=" ${NUTTXTOOLS} /pico-sdk"
320+ echo " export PICO_SDK_PATH=${NUTTXTOOLS} /pico-sdk" >> " ${NUTTXTOOLS} " /env.sh
321+ }
322+
302323setup_links () {
303324 # Configure ccache
304325 mkdir -p " ${NUTTXTOOLS} " /ccache/bin/
@@ -334,7 +355,7 @@ install_build_tools() {
334355 mkdir -p " ${NUTTXTOOLS} "
335356 echo " #!/usr/bin/env sh" > " ${NUTTXTOOLS} " /env.sh
336357
337- install=" arm_clang_toolchain arm_gcc_toolchain arm64_gcc_toolchain bloaty kconfig_frontends mips_gcc_toolchain python_tools riscv_gcc_toolchain rx_gcc_toolchain sparc_gcc_toolchain xtensa_esp_gcc_toolchain util_linux wasi_sdk"
358+ install=" arm_clang_toolchain arm_gcc_toolchain arm64_gcc_toolchain bloaty kconfig_frontends mips_gcc_toolchain python_tools riscv_gcc_toolchain rx_gcc_toolchain sparc_gcc_toolchain xtensa_esp_gcc_toolchain util_linux wasi_sdk raspberrypi_pico_sdk "
338359
339360 oldpath=$( cd . && pwd -P)
340361 for func in ${install} ; do
Original file line number Diff line number Diff line change @@ -379,6 +379,27 @@ wasi_sdk() {
379379 command wamrc --version
380380}
381381
382+ raspberrypi_pico_sdk () {
383+ if [ ! -f " ${NUTTXTOOLS} /pico-sdk" ]; then
384+ local release
385+ local basefile
386+ release=" 2.2.0"
387+ basefile=" pico-sdk-${release} "
388+ cd " ${NUTTXTOOLS} "
389+ mkdir -p pico-sdk
390+
391+ # Download the latest pico-sdk source archive
392+ curl -O -L -s https://github.com/raspberrypi/pico-sdk/releases/download/${release} /${basefile} .tar.gz
393+ tar xzf " ${basefile} .tar.gz"
394+ mv " ${basefile} " pico-sdk
395+ rm " ${basefile} .tar.gz"
396+
397+ fi
398+
399+ export PICO_SDK_PATH=" ${NUTTXTOOLS} /pico-sdk"
400+ echo " export PICO_SDK_PATH=${NUTTXTOOLS} /pico-sdk" >> " ${NUTTXTOOLS} " /env.sh
401+ }
402+
382403setup_links () {
383404 # Configure ccache
384405 mkdir -p " ${NUTTXTOOLS} " /ccache/bin/
@@ -414,7 +435,7 @@ install_build_tools() {
414435 mkdir -p " ${NUTTXTOOLS} "
415436 echo " #!/usr/bin/env sh" > " ${NUTTXTOOLS} " /env.sh
416437
417- install=" arm_clang_toolchain arm_gcc_toolchain arm64_gcc_toolchain avr_gcc_toolchain binutils bloaty clang_tidy gen_romfs gperf kconfig_frontends mips_gcc_toolchain python_tools riscv_gcc_toolchain rust dlang rx_gcc_toolchain sparc_gcc_toolchain xtensa_esp_gcc_toolchain u_boot_tools util_linux wasi_sdk c_cache"
438+ install=" arm_clang_toolchain arm_gcc_toolchain arm64_gcc_toolchain avr_gcc_toolchain binutils bloaty clang_tidy gen_romfs gperf kconfig_frontends mips_gcc_toolchain python_tools riscv_gcc_toolchain rust dlang rx_gcc_toolchain sparc_gcc_toolchain xtensa_esp_gcc_toolchain u_boot_tools util_linux wasi_sdk c_cache raspberrypi_pico_sdk "
418439
419440 oldpath=$( cd . && pwd -P)
420441 for func in ${install} ; do
You can’t perform that action at this time.
0 commit comments