Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Development / Binary File Size

Release Profiles

# Build binary with dev profile
cargo build
# Build binary with release profile
cargo build --release

Tip

Release Profiles For more information about release profiles, please refer to:

Tip

Optimization Levels For more information about rust compiler optimization levels, please have a look at https://doc.rust-lang.org/cargo/reference/profiles.html#opt-level

Tip

Strip Symbols For more information about strip symbols, please see https://doc.rust-lang.org/cargo/reference/unstable.html#profile-strip-option

Application (exe)

[profile.dev]
opt-level = 0

[profile.release]
opt-level = 3
# 12MB -> 7.8MB
lto = true
# 7.8MB -> 4.5MB
strip = "symbols"

Plugin (.so/.dll)

[profile.dev]
opt-level = 0

[profile.release]
opt-level = 3
# 12MB -> 7.8MB
lto = true
# 7.8MB -> 4.5MB
strip = "symbols"