Files
corne-rs/Makefile.toml
2025-10-12 21:43:50 +05:30

84 lines
1.7 KiB
TOML

[tasks.install-llvm-tools]
install_crate = { rustup_component_name = "llvm-tools" }
[tasks.flip-link]
install_crate = { crate_name = "flip-link", binary = "flip-link", test_arg = ["-h"] }
[tasks.build]
command = "cargo"
args = ["build", "--release"]
dependencies = ["install-llvm-tools", "flip-link"]
[tasks.objcopy-central]
install_crate = { crate_name = "cargo-binutils", binary = "cargo", test_arg = [
"objcopy",
"--help",
] }
command = "cargo"
args = [
"objcopy",
"--release",
"--bin",
"central",
"--",
"-O",
"ihex",
"corne-rs-central.hex",
]
dependencies = ["build"]
[tasks.objcopy-peripheral]
install_crate = { crate_name = "cargo-binutils", binary = "cargo", test_arg = [
"objcopy",
"--help",
] }
command = "cargo"
args = [
"objcopy",
"--release",
"--bin",
"peripheral",
"--",
"-O",
"ihex",
"corne-rs-peripheral.hex",
]
dependencies = ["build"]
[tasks.uf2-central]
install_crate = { crate_name = "cargo-hex-to-uf2", binary = "cargo", test_arg = [
"hex-to-uf2",
"--help",
] }
command = "cargo"
args = [
"hex-to-uf2",
"--input-path",
"corne-rs-central.hex",
"--output-path",
"corne-rs-central.uf2",
"--family",
"nrf52840",
]
dependencies = ["objcopy-central"]
[tasks.uf2-peripheral]
install_crate = { crate_name = "cargo-hex-to-uf2", binary = "cargo", test_arg = [
"hex-to-uf2",
"--help",
] }
command = "cargo"
args = [
"hex-to-uf2",
"--input-path",
"corne-rs-peripheral.hex",
"--output-path",
"corne-rs-peripheral.uf2",
"--family",
"nrf52840",
]
dependencies = ["objcopy-peripheral"]
[tasks.uf2]
dependencies = ["uf2-central", "uf2-peripheral"]