Skip to content

Xtensa esp(up) toolchain not pulled in? #2

@brainstorm

Description

@brainstorm

Hello,

I'm trying to setup my own local environment to compile/test embassy to followup on embassy-rs/embassy#4957 locally (without spending your GitHub CI worker minutes).

The tool pulls in a variety of rust toolchains by default, but seems to fail on ESP32S2?:

$ cargo embassy-devtool prepare-release embassy-sync
2025-12-08T05:23:22.508Z INFO  [cargo_embassy_devtool::cmd::semver_check] Building doc json for embassy-sync with features: ["defmt"]
2025-12-08T05:23:22.508Z DEBUG [cargo_embassy_devtool::cmd::semver_check] [
    "+nightly-2025-06-29",
    "rustdoc",
    "--lib",
    "--output-format=json",
    "-Zunstable-options",
    "-Zhost-config",
    "-Ztarget-applies-to-host",
    "-Zbuild-std=alloc,core",
    "--target=xtensa-esp32s2-none-elf",
    "--features=defmt",
    "--config=host.rustflags=[\"--cfg=instability_disable_unstable_docs\"]",
]
Running `cargo +nightly-2025-06-29 rustdoc --lib --output-format=json -Zunstable-options -Zhost-config -Ztarget-... (253 chars)` in "/home/rvalls/dev/personal/embassy/releaser/target/embassy-sync-0.7.2" - Environment [("RUSTDOCFLAGS", "--cfg docsrs --cfg not_really_docsrs --cfg semver_checks")]
   Compiling compiler_builtins v0.1.160 (/home/rvalls/.rustup/toolchains/nightly-2025-06-29-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/compiler-builtins/compiler-builtins)
   Compiling core v0.0.0 (/home/rvalls/.rustup/toolchains/nightly-2025-06-29-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core)
   Compiling defmt v1.0.1
   Compiling embedded-io-async v0.6.1
   Compiling heapless v0.8.0
   Compiling embassy-sync v0.7.2 (/home/rvalls/dev/personal/embassy/releaser/target/embassy-sync-0.7.2)
'esp32s2' is not a recognized processor for this target (ignoring processor)
'+forced-atomics' is not a recognized feature for this target (ignoring feature)
'esp32s2' is not a recognized processor for this target (ignoring processor)
'esp32s2' is not a recognized processor for this target (ignoring processor)
'+forced-atomics' is not a recognized feature for this target (ignoring feature)
'esp32s2' is not a recognized processor for this target (ignoring processor)
error: data-layout for target `xtensa-esp32s2-none-elf`, `e-m:e-p:32:32-v1:8:8-i64:64-i128:128-n32`, differs from LLVM target's `xtensa-none-elf` default layout, `e-m:e-p:32:32-i8:8:32-i16:16:32-i64:64-n32`

'esp32s2' is not a recognized processor for this target (ignoring processor)
'+forced-atomics' is not a recognized feature for this target (ignoring feature)
'esp32s2' is not a recognized processor for this target (ignoring processor)
'esp32s2' is not a recognized processor for this target (ignoring processor)
'+forced-atomics' is not a recognized feature for this target (ignoring feature)
'esp32s2' is not a recognized processor for this target (ignoring processor)
error: could not compile `core` (lib) due to 1 previous error
warning: build failed, waiting for other jobs to finish...
'esp32s2' is not a recognized processor for this target (ignoring processor)
'+forced-atomics' is not a recognized feature for this target (ignoring feature)
'esp32s2' is not a recognized processor for this target (ignoring processor)
'esp32s2' is not a recognized processor for this target (ignoring processor)
'+forced-atomics' is not a recognized feature for this target (ignoring feature)
'esp32s2' is not a recognized processor for this target (ignoring processor)
error: could not compile `compiler_builtins` (lib) due to 1 previous error
Error: Failed to execute cargo subcommand `cargo +nightly-2025-06-29 rustdoc --lib --output-format=json -Zunstable-options -Zhost-config -Ztarget-... (253 chars)`

$ clang --version
Ubuntu clang version 18.1.3 (1ubuntu1)
Target: x86_64-pc-linux-gnu
Thread model: posix
InstalledDir: /usr/bin

$ /home/rvalls/.rustup/toolchains/esp/xtensa-esp-elf/esp-14.2.0_20240906/xtensa-esp-elf/bin/xtensa-esp32s2-elf-cc --version
xtensa-esp-elf-cc (crosstool-NG esp-14.2.0_20240906) 14.2.0
Copyright (C) 2024 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

$ espup --version
espup 0.16.0

I guess I should pin/lock to revisions like you do in this Xtensa CI script?:

https://github.com/embassy-rs/embassy/blob/main/.github/ci/build-xtensa.sh

In other words, do you regularly use cargo-embassy-devtool locally to build embassy (and prepare releases) or do you mainly rely on the CI setup nowadays?

EDIT: Should I install cargo-embassy-devtool pinned to the commit revision pointed by this?: embassy-rs/embassy@27df928

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions