build(guest): strip release symbols

Configure guest release profiles with debug = 0 and strip = "symbols" so deployed RISC Zero artifacts use stripped binaries.

Document that release-profile ImageIDs are canonical for testnet and mainnet deployments and dependent values must be refreshed.
This commit is contained in:
Ricardo Guilherme Schmidt 2026-06-28 18:41:49 -03:00
parent 255f87f38f
commit 497e13db85
6 changed files with 30 additions and 0 deletions

View File

@ -66,6 +66,16 @@ Generated IDL files live in `artifacts/`. CI checks that every program under `*/
**Note:** `spel` and `wallet` may use different versions of the wallet package. If `spel --idl <IDL> <PROGRAM_FUNCTION> ...` fails, ensure `seq_poll_timeout_millis` is set in the wallet config at `~/.nssa/wallet`.
For testnet and mainnet deployments, build guest binaries with the release profile in each guest manifest:
```toml
[profile.release]
debug = 0
strip = "symbols"
```
That profile is part of program identity. After every release build, inspect the binary and update every value that depends on the ImageID before submitting transactions: deployed program IDs, client/config files, PDA-derived account addresses, AMM `token_program_id` and `twap_oracle_program_id`, and ATA `token_program_id` inputs. Do not mix raw or old ImageIDs with release-profile binaries.
```bash
# Deploy a program binary to the sequencer
wallet deploy-program <path-to-binary>

View File

@ -5,6 +5,10 @@ edition = "2021"
[workspace]
[profile.release]
debug = 0
strip = "symbols"
[lints.rust]
rust_2018_idioms = { level = "deny", priority = -1 }
# deny (not forbid) so a targeted per-item #[allow] remains possible if ever needed

View File

@ -5,6 +5,10 @@ edition = "2021"
[workspace]
[profile.release]
debug = 0
strip = "symbols"
[lints.rust]
rust_2018_idioms = { level = "deny", priority = -1 }
# deny (not forbid) so a targeted per-item #[allow] remains possible if ever needed

View File

@ -5,6 +5,10 @@ edition = "2021"
[workspace]
[profile.release]
debug = 0
strip = "symbols"
[[bin]]
name = "stablecoin"
path = "src/bin/stablecoin.rs"

View File

@ -5,6 +5,10 @@ edition = "2021"
[workspace]
[profile.release]
debug = 0
strip = "symbols"
[lints.rust]
rust_2018_idioms = { level = "deny", priority = -1 }
# deny (not forbid) so a targeted per-item #[allow] remains possible if ever needed

View File

@ -5,6 +5,10 @@ edition = "2021"
[workspace]
[profile.release]
debug = 0
strip = "symbols"
[[bin]]
name = "twap_oracle"
path = "src/bin/twap_oracle.rs"