mirror of
https://github.com/apache/nuttx.git
synced 2026-05-21 13:13:08 +08:00
ci/docker: add Raspberry Pi picotool and fix GN build
- Add prebuilt Raspberry Pi picotool
- fix GN build with:
git checkout 5d0a4153b0bcc86c5a23310d5b648a587be3c56d
Signed-off-by: simbit18 <simbit18@gmail.com>
This commit is contained in:
@@ -43,7 +43,8 @@ RUN apt-get update -qq && DEBIAN_FRONTEND="noninteractive" apt-get install -y -q
|
||||
nodejs \
|
||||
npm \
|
||||
unzip \
|
||||
zip
|
||||
zip \
|
||||
python3
|
||||
|
||||
RUN mkdir -p /tools
|
||||
WORKDIR /tools
|
||||
@@ -67,8 +68,10 @@ RUN cd nuttx-tools/kconfig-frontends \
|
||||
RUN mkdir -p /tools/gn \
|
||||
&& cd /tools/gn \
|
||||
&& git clone https://gn.googlesource.com/gn gn \
|
||||
&& cd gn && ./build/gen.py \
|
||||
&& cd out && ninja
|
||||
&& cd gn \
|
||||
&& git checkout 5d0a4153b0bcc86c5a23310d5b648a587be3c56d \
|
||||
&& python3 build/gen.py \
|
||||
&& ninja -C out
|
||||
|
||||
# Upgrade nodejs to the stable version we need before install zap
|
||||
RUN npm install -g n && n 20.10.0 node && hash -r
|
||||
@@ -302,6 +305,15 @@ RUN mkdir -p pico-sdk && \
|
||||
curl -s -L "https://github.com/raspberrypi/pico-sdk/releases/download/2.2.0/pico-sdk-2.2.0.tar.gz" \
|
||||
| tar -C pico-sdk --strip-components 1 -xz
|
||||
|
||||
###############################################################################
|
||||
# Build image for tool required by Raspberry Pi picotool builds
|
||||
###############################################################################
|
||||
FROM nuttx-toolchain-base AS nuttx-toolchain-raspberrypi-picotool
|
||||
# Download the prebuilt Raspberry Pi picotool
|
||||
RUN mkdir -p picotool && \
|
||||
curl -s -L "https://github.com/raspberrypi/pico-sdk-tools/releases/download/v2.2.0-0/picotool-2.2.0-x86_64-lin.tar.gz" \
|
||||
| tar -C picotool --strip-components 1 -xz
|
||||
|
||||
###############################################################################
|
||||
# Final Docker image used for running CI system. This includes all toolchains
|
||||
# supported by the CI system.
|
||||
@@ -493,6 +505,10 @@ COPY --from=nuttx-toolchain-esp32 /tools/blobs/* /tools/blobs/esp-bins/
|
||||
COPY --from=nuttx-toolchain-raspberrypi-pico-sdk /tools/pico-sdk/ pico-sdk/
|
||||
ENV PICO_SDK_PATH="/tools/pico-sdk"
|
||||
|
||||
# Raspberry Pi picotool
|
||||
COPY --from=nuttx-toolchain-raspberrypi-picotool /tools/picotool/ picotool/
|
||||
ENV PATH="/tools/picotool:$PATH"
|
||||
|
||||
# gn tool
|
||||
RUN mkdir -p /tools/gn
|
||||
COPY --from=nuttx-tools /tools/gn/gn/out/gn /tools/gn
|
||||
|
||||
Reference in New Issue
Block a user