diff --git a/examples/rust-gcoap/Cargo.toml b/examples/rust-gcoap/Cargo.toml index e6cf6e2f89..0567dde89c 100644 --- a/examples/rust-gcoap/Cargo.toml +++ b/examples/rust-gcoap/Cargo.toml @@ -13,6 +13,10 @@ crate-type = ["staticlib"] # supports no unwinding), but setting it allows builds on native without using # the nightly-only lang_items feature. panic = "abort" +# This is a typical set of options that helps Rust binaries stay small +lto = true +codegen-units = 1 +opt-level = "s" [dependencies] riot-wrappers = { version = "^0.7.18", features = [ "set_panic_handler", "panic_handler_format", "with_coap_message", "with_coap_handler" ] }