blob: 83f9f7561321b4cc38d2114e57c10ce5ea1e7536 [file] [log] [blame]
ARG VERSION=1
FROM ghcr.io/project-chip/chip-build:${VERSION} as build
LABEL org.opencontainers.image.source https://github.com/project-chip/connectedhomeip
RUN set -x \
&& apt-get update \
&& DEBIAN_FRONTEND=noninteractive apt-get install -fy --no-install-recommends \
unzip \
wget \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/ \
&& : # last line
WORKDIR /opt/sdk
RUN set -x \
&& python3 -m pip install --break-system-packages -U --no-cache-dir west==1.0.0 \
&& west init -m https://github.com/nxp-mcuxpresso/mcux-sdk --mr "MCUX_2.6.14_K32W0" \
&& west update \
&& chmod +x core/tools/imagetool/sign_images.sh \
&& ln -sf ../rtos core \
&& ln -sf ../middleware core \
&& cp -R examples/* core/boards && rm -rf examples \
&& : # last line
RUN set -x \
&& mkdir -p k32w1 \
&& wget https://cache.nxp.com/lgfiles/bsps/SDK_2_12_7_K32W148-EVK.zip \
&& unzip SDK_2_12_7_K32W148-EVK.zip -d k32w1 \
&& rm -rf SDK_2_12_7_K32W148-EVK.zip
FROM ghcr.io/project-chip/chip-build:${VERSION}
COPY --from=build /opt/sdk/ /opt/sdk/
ENV NXP_K32W0_SDK_ROOT=/opt/sdk/core
ENV NXP_K32W1_SDK_ROOT=/opt/sdk/k32w1