Skip to content
Free public beta until December 4, 2026: every course is open, no card needed. After that, the first chapter of each course stays free and full access is a one-time $39 ($19 for up to 100 founding members chosen for helpful feedback). Your progress is kept. How the beta works

cross-compilation

Building a program on one kind of computer to run on another, such as on a laptop for an ESP32.

Cross-compilation compiles and links code for a target architecture different from the build host, using a target-specific standard library and linker configuration.

Examples

  • Running cargo build on a laptop with [build] target = "riscv32imac-unknown-none-elf" in .cargo/config.toml produces firmware for the ESP32-C6, not the laptop.

  • The laptop is the host and the ESP32-C6 is the target; the binary can't run on the machine that built it.

Read the full section →