Because the Rust toolchain isn't downloaded during the toolchain phase, the buildroot phase fails with the following message:
# Ensure the toolchain, components, and targets we've specified in
# rust-toolchain.toml are ready to go. Since that file sets rustup's
# default toolchain for the entire directory, all we need to do is run
# any rustup-wrapped command to trigger installation. We've arbitrarily
# chosen "cargo --version" since it has no other effect.
Configuring OP-TEE rust examples
/bin/bash: line 1: /.cargo/env: No such file or directory
make[2]: *** [package/pkg-generic.mk:273: /optee/out-br/build/optee_rust_examples_ext-1.0/.stamp_configured] Error 1
make[1]: *** [Makefile:23: _all] Error 2
make[1]: Leaving directory '/optee/out-br'
make: *** [common.mk:341: buildroot] Error 2
The command '/bin/sh -c make -j1 V=1' returned a non-zero code: 2
This problem will occur using the reference
Dockerfile
at https://optee.readthedocs.io/en/latest/building/prerequisites.html in an arm64 container on Docker.Because the Rust toolchain isn't downloaded during the toolchain phase, the buildroot phase fails with the following message:
This is a follow-up to Issue #747 with a more specific description of a specific problem I am seeing -- first mentioned in this comment: https://github.com/OP-TEE/build/issues/747#issuecomment-2108629173
I should also mention that using
RUST_ENABLE=n
will avoid the failure, but then the Rust examples are not built.