esp-hal/esp-backtrace/Cargo.toml
Björn Quentin 9e190f112d
Use riscv-rt's startup and trap-handling code (#3857)
* Use riscv-rt's startup code

* CHANGELOG.md

* Enable v-trap - get rid of one unused function

* Re-use riscv-rt's TrapFrame instead of keeping a copy of it

* fmt

* Update riscv-rt rev

* Enable defmt

* use riscv-rt's trap handling

* Compile on stable

* (Re)add the SP fixing code

* Move comment

* Update `riscv*` deps

* esp-riscv-rt: Remove the (unused) CI feature
2025-09-11 07:48:44 +00:00

76 lines
2.9 KiB
TOML

[package]
name = "esp-backtrace"
version = "0.17.0"
edition = "2024"
rust-version = "1.86.0"
description = "Bare-metal backtrace support for Espressif devices"
documentation = "https://docs.espressif.com/projects/rust/esp-backtrace/latest/"
keywords = ["backtrace", "embedded", "esp32", "espressif"]
categories = ["embedded", "hardware-support", "no-std"]
repository = "https://github.com/esp-rs/esp-hal"
license = "MIT OR Apache-2.0"
[package.metadata.docs.rs]
default-target = "riscv32imc-unknown-none-elf"
features = ["esp32c3", "panic-handler", "exception-handler", "println", "esp-println/uart"]
[lib]
bench = false
test = false
[dependencies]
cfg-if = "1.0.0"
defmt = { version = "1", optional = true }
esp-config = { version = "0.5.0", path = "../esp-config" }
esp-metadata-generated = { version = "0.1.0", path = "../esp-metadata-generated" }
esp-println = { version = "0.15.0", optional = true, default-features = false, path = "../esp-println" }
heapless = "0.8"
semihosting = { version = "0.1.20", optional = true }
document-features = "0.2.11"
[target.'cfg(target_arch = "riscv32")'.dependencies]
riscv = { version = "0.15.0" }
[target.'cfg(target_arch = "xtensa")'.dependencies]
xtensa-lx = { version = "0.12.0", path = "../xtensa-lx" }
[build-dependencies]
esp-config = { version = "0.5.0", path = "../esp-config", features = ["build"] }
[features]
default = ["colors"]
esp32 = ["esp-println?/esp32", "esp-metadata-generated/esp32", "semihosting?/openocd-semihosting", "print-float-registers"]
esp32c2 = ["esp-println?/esp32c2", "esp-metadata-generated/esp32c2"]
esp32c3 = ["esp-println?/esp32c3", "esp-metadata-generated/esp32c3"]
esp32c6 = ["esp-println?/esp32c6", "esp-metadata-generated/esp32c6"]
esp32h2 = ["esp-println?/esp32h2", "esp-metadata-generated/esp32h2"]
esp32s2 = ["esp-println?/esp32s2", "esp-metadata-generated/esp32s2", "semihosting?/openocd-semihosting"]
esp32s3 = ["esp-println?/esp32s3", "esp-metadata-generated/esp32s3", "semihosting?/openocd-semihosting", "print-float-registers"]
## Use `esp-println`
println = ["dep:esp-println"]
## Use `defmt`
defmt = ["dep:defmt"]
print-float-registers = [] # TODO support esp32p4
# You may optionally enable one or more of the below features to provide
# additional functionality:
## Print messages in red
colors = []
## Invoke the extern function `custom_halt()` instead of doing a loop {} in case of a panic. This feature does not imply the `halt-cores` feature.
custom-halt = []
## Invoke the extern function `custom_pre_backtrace()` before handling a panic
custom-pre-backtrace = []
## Halt both CPUs on ESP32 / ESP32-S3 instead of doing a `loop {}` in case of a panic
halt-cores = []
## Exit with a semihosting call in case of a panic
semihosting = ["dep:semihosting"]
## Include a panic handler
panic-handler = []
[lints.rust]
unexpected_cfgs = "allow"