2
2
FROM ubuntu:22.04 as chip-build-cert
3
3
ARG TARGETPLATFORM
4
4
# COMMITHASH defines the target commit to build from. May be passed in using --build-arg.
5
- ARG COMMITHASH=21245f42393e63dbb16fb4d99d8bf96aef7ae0fc
5
+ ARG COMMITHASH=1e06479f412b78eea0dfbeacf7cad51d005b649b
6
6
7
7
# Ensure TARGETPLATFORM is set
8
8
RUN case ${TARGETPLATFORM} in \
@@ -200,15 +200,13 @@ SHELL ["/bin/bash", "-c"]
200
200
# Records Matter SDK commit hash to include in the image.
201
201
RUN git rev-parse HEAD > /root/.sdk-sha-version
202
202
203
- # TODO: below the build of linux-arm64-all-clusters-minimal-ipv6only/linux-x64-all-clusters-minimal-ipv6only
204
- # is NOT performed because the given SHA does not build minimal and
205
- # builds the regular all-clusters app instead.
206
203
RUN case ${TARGETPLATFORM} in \
207
204
"linux/amd64" ) \
208
205
set -x \
209
206
&& source scripts/activate.sh \
210
207
&& scripts/build/build_examples.py \
211
208
--target linux-x64-all-clusters-ipv6only \
209
+ --target linux-x64-all-clusters-minimal-ipv6only \
212
210
--target linux-x64-bridge-ipv6only \
213
211
--target linux-x64-tv-app-ipv6only \
214
212
--target linux-x64-tv-casting-app-ipv6only \
@@ -219,6 +217,7 @@ RUN case ${TARGETPLATFORM} in \
219
217
--target linux-x64-lock-ipv6only \
220
218
build \
221
219
&& mv out/linux-x64-all-clusters-ipv6only/chip-all-clusters-app out/chip-all-clusters-app \
220
+ && mv out/linux-x64-all-clusters-minimal-ipv6only/chip-all-clusters-minimal-app out/chip-all-clusters-minimal-app \
222
221
&& mv out/linux-x64-bridge-ipv6only/chip-bridge-app out/chip-bridge-app \
223
222
&& mv out/linux-x64-tv-app-ipv6only/chip-tv-app out/chip-tv-app \
224
223
&& mv out/linux-x64-tv-casting-app-ipv6only/chip-tv-casting-app out/chip-tv-casting-app \
@@ -233,6 +232,7 @@ RUN case ${TARGETPLATFORM} in \
233
232
&& source scripts/activate.sh \
234
233
&& scripts/build/build_examples.py \
235
234
--target linux-arm64-all-clusters-ipv6only \
235
+ --target linux-arm64-all-clusters-minimal-ipv6only \
236
236
--target linux-arm64-bridge-ipv6only \
237
237
--target linux-arm64-tv-app-ipv6only \
238
238
--target linux-arm64-tv-casting-app-ipv6only \
@@ -243,6 +243,7 @@ RUN case ${TARGETPLATFORM} in \
243
243
--target linux-arm64-lock-ipv6only \
244
244
build \
245
245
&& mv out/linux-arm64-all-clusters-ipv6only/chip-all-clusters-app out/chip-all-clusters-app \
246
+ && mv out/linux-arm64-all-clusters-minimal-ipv6only/chip-all-clusters-minimal-app out/chip-all-clusters-minimal-app \
246
247
&& mv out/linux-arm64-bridge-ipv6only/chip-bridge-app out/chip-bridge-app \
247
248
&& mv out/linux-arm64-tv-app-ipv6only/chip-tv-app out/chip-tv-app \
248
249
&& mv out/linux-arm64-tv-casting-app-ipv6only/chip-tv-casting-app out/chip-tv-casting-app \
@@ -255,18 +256,16 @@ RUN case ${TARGETPLATFORM} in \
255
256
*) ;; \
256
257
esac
257
258
258
- # Install a known ZAP release
259
- # Only keep the cli version, since `zap` is 143MB and not usable (UI)
259
+ # ZAP Development install, so that it runs on both x64 and arm64
260
260
ENV ZAP_VERSION=v2022.11.29-nightly
261
261
RUN set -x \
262
262
&& mkdir -p /opt/zap-${ZAP_VERSION} \
263
+ && git clone https://github.com/project-chip/zap.git /opt/zap-${ZAP_VERSION} \
263
264
&& cd /opt/zap-${ZAP_VERSION} \
264
- && wget https://github.com/project-chip/zap/releases/download/${ZAP_VERSION}/zap-linux.zip \
265
- && unzip zap-linux.zip \
266
- && rm zap-linux.zip \
267
- && rm zap \
268
- && ln -s /opt/zap-${ZAP_VERSION}/zap-cli /usr/bin/ \
269
- && : # last line
265
+ && git checkout ${ZAP_VERSION} \
266
+ && npm config set user 0 \
267
+ && npm ci
268
+ ENV ZAP_DEVELOPMENT_PATH=/opt/zap-${ZAP_VERSION}
270
269
RUN scripts/examples/gn_build_test_example.sh app1
271
270
272
271
RUN source scripts/activate.sh && scripts/build_python.sh -m platform -d true -i no
@@ -283,6 +282,7 @@ COPY --from=chip-build-cert-bins /root/connectedhomeip/out/debug/chip-tool chip-
283
282
COPY --from=chip-build-cert-bins /root/connectedhomeip/out/debug/chip-shell chip-shell
284
283
COPY --from=chip-build-cert-bins /root/connectedhomeip/out/debug/chip-cert chip-cert
285
284
COPY --from=chip-build-cert-bins /root/connectedhomeip/out/chip-all-clusters-app chip-all-clusters-app
285
+ COPY --from=chip-build-cert-bins /root/connectedhomeip/out/chip-all-clusters-minimal-app chip-all-clusters-minimal-app
286
286
COPY --from=chip-build-cert-bins /root/connectedhomeip/out/chip-lighting-app chip-lighting-app
287
287
COPY --from=chip-build-cert-bins /root/connectedhomeip/out/chip-tv-casting-app chip-tv-casting-app
288
288
COPY --from=chip-build-cert-bins /root/connectedhomeip/out/chip-tv-app chip-tv-app
0 commit comments