sp1: Invalid summary version when compiling zkvm guest

Component

sp1-zkvm

Have you ensured that all of these are up to date?

  • SP1 SDK
  • cargo prove CLI/sp1up

What version of SP1 SDK are you on?

4.1.3

What version of the cargo prove CLI are you on?

cargo-prove sp1 (9312c7c 2025-04-17T18:45:11.033695524Z)

Operating System

Linux (Other)

Describe the bug

I get a rust-lld: error: Invalid summary version 12. Version should be in the range [1-10] running on Bazzite (fedora) 42. Rust installed via rustup. Clang installed via rpm-ostree, sp1 installed from sp1up.

warning: strata-bridge-guest-builder@0.1.0: rustc +succinct --version: "rustc 1.85.0-dev\n"

error: failed to run custom build command for `strata-bridge-guest-builder v0.1.0 (/var/home/bazzite/Developer/alpen/strata-bridge/bridge-guest-builder)`

Caused by:
  process didn't exit successfully: `/var/home/bazzite/Developer/alpen/strata-bridge/target/debug/build/strata-bridge-guest-builder-56d05ebba2e33421/build-script-build` (exit status: 101)
  --- stdout
  cargo:rerun-if-env-changed=SKIP_GUEST_BUILD
  cargo:rustc-check-cfg=cfg(skip_guest_build)
  cargo::rerun-if-changed=/var/home/bazzite/Developer/alpen/strata-bridge/bridge-guest-builder/bridge-guest/src
  cargo::rerun-if-changed=/var/home/bazzite/Developer/alpen/strata-bridge/bridge-guest-builder/bridge-guest/Cargo.toml
  cargo:rerun-if-changed=/var/home/bazzite/Developer/alpen/strata-bridge/bridge-guest-builder/bridge-guest/Cargo.lock
  cargo:rerun-if-changed=/var/home/bazzite/Developer/alpen/strata-bridge/crates/bridge-proof/protocol
  cargo:rerun-if-changed=/var/home/bazzite/Developer/alpen/strata-bridge/crates/test-utils
  cargo:rerun-if-changed=/var/home/bazzite/Developer/alpen/strata-bridge/crates/params
  cargo:rerun-if-changed=/var/home/bazzite/Developer/alpen/strata-bridge/crates/bridge-proof/primitives
  cargo:rerun-if-changed=/var/home/bazzite/Developer/alpen/strata-bridge/crates/bridge-proof/test-utils
  cargo:rerun-if-changed=/var/home/bazzite/Developer/alpen/strata-bridge/crates/common
  cargo:warning=rustc +succinct --version: "rustc 1.85.0-dev\n"

  --- stderr
  [sp1]  warning: unexpected `cfg` condition name: `test`
  [sp1]    --> /var/home/bazzite/Developer/alpen/strata-bridge/crates/params/src/stake_chain.rs:40:7
  [sp1]     |
  [sp1]  40 | #[cfg(test)]
  [sp1]     |       ^^^^
  [sp1]     |
  [sp1]     = help: expected names are: `clippy`, `debug_assertions`, `doc`, `docsrs`, `doctest`, `feature`, `fmt_debug`, `miri`, `overflow_checks`, `panic`, `proc_macro`, `relocation_model`, `rustfmt`, `sanitize`, `sanitizer_cfi_generalize_pointers`, `sanitizer_cfi_normalize_integers`, `target_abi`, `target_arch`, `target_endian`, `target_env`, `target_family`, `target_feature`, `target_has_atomic`, `target_has_atomic_equal_alignment`, `target_has_atomic_load_store`, `target_os`, `target_pointer_width`, `target_thread_local`, `target_vendor`, `ub_checks`, `unix`, and `windows`
  [sp1]     = help: consider using a Cargo feature instead
  [sp1]     = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint:
  [sp1]              [lints.rust]
  [sp1]              unexpected_cfgs = { level = "warn", check-cfg = ['cfg(test)'] }
  [sp1]     = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(test)");` to the top of the `build.rs`
  [sp1]     = note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html> for more information about checking conditional configuration
  [sp1]     = note: `#[warn(unexpected_cfgs)]` on by default
  [sp1]  
  [sp1]  warning: `alpen-bridge-params` (lib) generated 1 warning
  [sp1]  warning: unexpected `cfg` condition name: `test`
  [sp1]     --> /var/home/bazzite/Developer/alpen/strata-bridge/crates/bridge-proof/primitives/src/tx.rs:126:7
  [sp1]      |
  [sp1]  126 | #[cfg(test)]
  [sp1]      |       ^^^^
  [sp1]      |
  [sp1]      = help: expected names are: `clippy`, `debug_assertions`, `doc`, `docsrs`, `doctest`, `feature`, `fmt_debug`, `miri`, `overflow_checks`, `panic`, `proc_macro`, `relocation_model`, `rustfmt`, `sanitize`, `sanitizer_cfi_generalize_pointers`, `sanitizer_cfi_normalize_integers`, `target_abi`, `target_arch`, `target_endian`, `target_env`, `target_family`, `target_feature`, `target_has_atomic`, `target_has_atomic_equal_alignment`, `target_has_atomic_load_store`, `target_os`, `target_pointer_width`, `target_thread_local`, `target_vendor`, `ub_checks`, `unix`, and `windows`
  [sp1]      = help: consider using a Cargo feature instead
  [sp1]      = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint:
  [sp1]               [lints.rust]
  [sp1]               unexpected_cfgs = { level = "warn", check-cfg = ['cfg(test)'] }
  [sp1]      = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(test)");` to the top of the `build.rs`
  [sp1]      = note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html> for more information about checking conditional configuration
  [sp1]      = note: `#[warn(unexpected_cfgs)]` on by default
  [sp1]  
  [sp1]  warning: unexpected `cfg` condition name: `test`
  [sp1]     --> /var/home/bazzite/Developer/alpen/strata-bridge/crates/bridge-proof/primitives/src/tx_inclusion_proof.rs:174:7
  [sp1]      |
  [sp1]  174 | #[cfg(test)]
  [sp1]      |       ^^^^
  [sp1]      |
  [sp1]      = help: consider using a Cargo feature instead
  [sp1]      = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint:
  [sp1]               [lints.rust]
  [sp1]               unexpected_cfgs = { level = "warn", check-cfg = ['cfg(test)'] }
  [sp1]      = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(test)");` to the top of the `build.rs`
  [sp1]      = note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html> for more information about checking conditional configuration
  [sp1]  
  [sp1]  warning: `strata-bridge-proof-primitives` (lib) generated 2 warnings
  [sp1]  warning: unexpected `cfg` condition name: `test`
  [sp1]    --> /var/home/bazzite/Developer/alpen/strata-bridge/crates/bridge-proof/protocol/src/program.rs:96:7
  [sp1]     |
  [sp1]  96 | #[cfg(test)]
  [sp1]     |       ^^^^
  [sp1]     |
  [sp1]     = help: expected names are: `clippy`, `debug_assertions`, `doc`, `docsrs`, `doctest`, `feature`, `fmt_debug`, `miri`, `overflow_checks`, `panic`, `proc_macro`, `relocation_model`, `rustfmt`, `sanitize`, `sanitizer_cfi_generalize_pointers`, `sanitizer_cfi_normalize_integers`, `target_abi`, `target_arch`, `target_endian`, `target_env`, `target_family`, `target_feature`, `target_has_atomic`, `target_has_atomic_equal_alignment`, `target_has_atomic_load_store`, `target_os`, `target_pointer_width`, `target_thread_local`, `target_vendor`, `ub_checks`, `unix`, and `windows`
  [sp1]     = help: consider using a Cargo feature instead
  [sp1]     = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint:
  [sp1]              [lints.rust]
  [sp1]              unexpected_cfgs = { level = "warn", check-cfg = ['cfg(test)'] }
  [sp1]     = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(test)");` to the top of the `build.rs`
  [sp1]     = note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html> for more information about checking conditional configuration
  [sp1]     = note: `#[warn(unexpected_cfgs)]` on by default
  [sp1]  
  [sp1]  warning: unexpected `cfg` condition name: `test`
  [sp1]     --> /var/home/bazzite/Developer/alpen/strata-bridge/crates/bridge-proof/protocol/src/tx_info.rs:121:7
  [sp1]      |
  [sp1]  121 | #[cfg(test)]
  [sp1]      |       ^^^^
  [sp1]      |
  [sp1]      = help: consider using a Cargo feature instead
  [sp1]      = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint:
  [sp1]               [lints.rust]
  [sp1]               unexpected_cfgs = { level = "warn", check-cfg = ['cfg(test)'] }
  [sp1]      = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(test)");` to the top of the `build.rs`
  [sp1]      = note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html> for more information about checking conditional configuration
  [sp1]  
  [sp1]  warning: `strata-bridge-proof-protocol` (lib) generated 2 warnings
  [sp1]     Compiling strata-bridge-guest v0.1.0 (/var/home/bazzite/Developer/alpen/strata-bridge/bridge-guest-builder/bridge-guest)
  [sp1]  error: linking with `rust-lld` failed: exit status: 1
  [sp1]    |
  [sp1]    = note: LC_ALL="C" PATH="/var/home/bazzite/.sp1/toolchains/OfoKEsMYxz/lib/rustlib/x86_64-unknown-linux-gnu/bin:/home/linuxbrew/.linuxbrew/opt/llvm@19/bin:/home/linuxbrew/.linuxbrew/opt/llvm@19/bin:/home/linuxbrew/.linuxbrew/bin:/home/linuxbrew/.linuxbrew/sbin:/home/bazzite/.cargo/bin:/home/bazzite/.local/bin:/home/bazzite/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/sbin:/usr/sbin:/sbin:/home/bazzite/.sp1/bin" VSLANG="1033" "rust-lld" "-flavor" "gnu" "/tmp/rustcecYnkx/symbols.o" "<10 object files omitted>" "--as-needed" "-Bstatic" "/var/home/bazzite/Developer/alpen/strata-bridge/bridge-guest-builder/bridge-guest/target/elf-compilation/riscv32im-succinct-zkvm-elf/release/deps/{libzkaleido_sp1_guest_env-6cab649b56503877.rlib,libsp1_zkvm-54f392e8b92e50a9.rlib,liblibm-1724d9eb8667152a.rlib,libstrata_bridge_proof_protocol-b8dbb0507deb3519.rlib,libstrata_bridge_proof_primitives-451b05c8880f9add.rlib,libstrata_proofimpl_btc_blockspace-665c438a1991f5a6.rlib,libstrata_l1tx-36caee64ced13600.rlib,libstrata_state-fd844de4f1ccdf49.rlib,libstrata_crypto-432e704e15ca5891.rlib,libzkaleido_sp1_groth16_verifier-9e1b0bc31128956f.rlib,libsp1_verifier-b7ca704b45de5fe2.rlib,libsubstrate_bn_succinct-02dcc44c829f6664.rlib,libsp1_lib-3ddbd15a3bf7bd87.rlib,libsp1_primitives-ef35db9184c0298e.rlib,libp3_baby_bear-8d1ec1af0c8ea110.rlib,libp3_poseidon2-64305e93708127ba.rlib,libgcd-a3ddde53186bdd3d.rlib,libp3_mds-40b11f76f416b32c.rlib,libp3_dft-c328d93a7de2238e.rlib,libp3_matrix-91439a54deb18314.rlib,libp3_maybe_rayon-9cf141c12e7d4073.rlib,libp3_symmetric-c463615e3e865bec.rlib,libp3_field-ad6d1676cd84cc73.rlib,libp3_util-b6ed8de8a3f9cf4d.rlib,libitertools-ba000b95fea6c55e.rlib,libcrunchy-313aa0126509678a.rlib,liblazy_static-0302cdb804eaede5.rlib,libspin-d70c730683f543c5.rlib,libzkaleido_risc0_groth16_verifier-1e788dcff1a86ee8.rlib,librisc0_groth16-44a89bca0933029d.rlib,libark_groth16-23f557f1f9bdd412.rlib,libark_crypto_primitives-3aac478a3562d1c7.rlib,libark_snark-711ab86db177e2a3.rlib,libark_relations-0f6dcd2071e4481c.rlib,libtracing_subscriber-56e8222c4e850c23.rlib,libark_bn254-86ac3940f3022e7d.rlib,libark_ec-17b73644c3ff784e.rlib,libark_poly-6b9bc01544383c95.rlib,libhashbrown-f763644d5ee38158.rlib,libahash-a996db7fb9d9f5aa.rlib,libitertools-0fc63021a4e9cc6e.rlib,libeither-cd71bcbfce48cc08.rlib,libark_ff-6dabdce6b826a0d5.rlib,libark_serialize-da28fba60d1a3a61.rlib,libnum_bigint-c25b4206ff185972.rlib,libnum_integer-1aa9d73d90787fe6.rlib,libark_std-3c2eaed3e47d163b.rlib,libnum_traits-4ad1597a4b15ae01.rlib,librisc0_binfmt-347697c6154651ff.rlib,librisc0_zkp-b5b8c2e3fb83b082.rlib,libblake2-e0e2271caba3e25b.rlib,librisc0_core-117645a2046e1990.rlib,libbytemuck-208e5fa2df6f9261.rlib,librisc0_zkvm_platform-aa467070adebdf46.rlib,libelf-31293605ca1a164f.rlib,libanyhow-c68a97efd0720c57.rlib,libtracing-01b5d0abdbdf84ac.rlib,liblog-09e9b5a01c482eca.rlib,libpin_project_lite-a1c20e4bc1f686cb.rlib,libtracing_core-3db91a002a79b85c.rlib,libstrata_bridge_tx_builder-36dbd77e59ab0b46.rlib,libalpen_bridge_params-bc42a4141c13ce7b.rlib,libzkaleido_native_adapter-68ad670b85db669c.rlib,libstrata_primitives-006c93ed9ee8357a.rlib,libhex-d840f68b758a6b28.rlib,libnum_enum-4838a54a28f707ec.rlib,libbitcoin_bosd-7627ead1f7e2568b.rlib,libthiserror-7826dd610ee36268.rlib,libconst_hex-f31c62a4020107a7.rlib,libmusig2-4f7ddd16d1483e9e.rlib,libsecp-f2e7110e7b23c529.rlib,libserdect-c1ca1e05ed80542b.rlib,libbitcoin-2efff201b535faef.rlib,libbitcoin_units-ae7b0df1529efbb1.rlib,libsecp256k1-412797f6f347e949.rlib,librand-9ec96cbf16f9cfb5.rlib,librand_chacha-c7e7f0864a707186.rlib,libppv_lite86-d9d95853f3e7b53a.rlib,libzerocopy-e57d48ef863febe2.rlib,libbyteorder-be7e40f08b262ec3.rlib,libecdsa-f694824988bcd456.rlib,libhex_literal-5b7c3058a4b83e85.rlib,libsp1_lib-f22b16eb6230dd3e.rlib,libk256-66bc5ba03d359441.rlib,libsha2-6c4d1b99f6d391a1.rlib,libecdsa-328cbcdc083a982a.rlib,librfc6979-017e5e0b18d7b178.rlib,libsignature-2b8de73421ce0689.rlib,libonce_cell-1d9f0cacd8079bed.rlib,libelliptic_curve-e32c8b119f502053.rlib,libpkcs8-5fd9405e1696f920.rlib,libspki-6acb15cb015d91f2.rlib,libsec1-9fc61d4ed3dce36b.rlib,libder-69c49c3be7ec6f01.rlib,libhkdf-c7ae355f380e33a0.rlib,libhmac-e9a1d77d8bb3a68a.rlib,libdigest-4736f1f2af12f2cd.rlib,libconst_oid-e1b279ccc31f8d6f.rlib,libblock_buffer-8bd2b01e14bbf555.rlib,libcrypto_common-29b7d8e98381b288.rlib,libcrypto_bigint-49254402cf604e3d.rlib,libgeneric_array-f8c3c07bbc399c46.rlib,libtypenum-fca245cd4343b620.rlib,libbase16ct-d2a232c73fba282d.rlib,libzeroize-2cdb95412711811e.rlib,libgroup-cd54523eaf4f6a9c.rlib,libff-0882a10b62fc9732.rlib,librand_core-5e72c4ad48655b3b.rlib,libgetrandom-1f49d2006062e1d9.rlib,libcfg_if-9120ff14c89028c6.rlib,libsubtle-77babf6d63dc0f8c.rlib,libsecp256k1_sys-7dafd9eeb282e42a.rlib,libbech32-d27012ab02074a9d.rlib,libbase58ck-bb855c982088c934.rlib,libbitcoin_hashes-34dda0c38c2e7357.rlib,libbitcoin_io-82823798406ca2ed.rlib,libhex_conservative-9e5f405c29504d85.rlib,libarrayvec-93e19eb83a860ec0.rlib,libbitcoin_internals-55cbb8bb2ffb1a42.rlib,libzkaleido-395279b35abb9d30.rlib,libbincode-a596be26fded286a.rlib,libthiserror-05912708641936b5.rlib,libserde-93f5a27684d7399b.rlib,libborsh-c88fb9b8f514126e.rlib,libarbitrary-21a1b267c5e82291.rlib}" "/var/home/bazzite/.sp1/toolchains/OfoKEsMYxz/lib/rustlib/riscv32im-succinct-zkvm-elf/lib/{libstd-e1c4276657a6d3e9.rlib,libpanic_abort-e9bbdd6fc2bd921e.rlib,librustc_demangle-e19b88be09f436e2.rlib,libstd_detect-ce5ab4add45fbf0d.rlib,libhashbrown-aa259cd9e97f7925.rlib,librustc_std_workspace_alloc-06c30b5d2879dc76.rlib,libminiz_oxide-cab65e151bcbe6b0.rlib,libadler-791f6bea7fec443e.rlib,libunwind-963ed3d3fb576b2b.rlib,libcfg_if-5584e27ec6d419ce.rlib,liblibc-aa0a8587c7e791f2.rlib,liballoc-669f36e2b4d435c8.rlib,librustc_std_workspace_core-5033f30186acf452.rlib,libcore-a13c84deafa4d52e.rlib,libcompiler_builtins-08fea47397c2a972.rlib}" "-Bdynamic" "-z" "noexecstack" "-L" "/var/home/bazzite/Developer/alpen/strata-bridge/bridge-guest-builder/bridge-guest/target/elf-compilation/riscv32im-succinct-zkvm-elf/release/build/secp256k1-sys-48de99ed86928f9f/out" "-o" "/var/home/bazzite/Developer/alpen/strata-bridge/bridge-guest-builder/bridge-guest/target/elf-compilation/riscv32im-succinct-zkvm-elf/release/deps/strata_bridge_guest-c30fb55bd21ab230" "--gc-sections" "-O1" "--strip-debug" "-Ttext=0x00200800"
  [sp1]    = note: some arguments are omitted. use `--verbose` to show all linker arguments
  [sp1]    = note: rust-lld: error: Invalid summary version 12. Version should be in the range [1-10].
  [sp1]            rust-lld: error: Invalid summary version 12. Version should be in the range [1-10].
  [sp1]            rust-lld: error: Invalid summary version 12. Version should be in the range [1-10].
  [sp1]            rust-lld: error: Invalid summary version 12. Version should be in the range [1-10].

About this issue

  • Original URL
  • State: closed
  • Created 2 years ago
  • Comments: 21 (8 by maintainers)

Most upvoted comments

I’m able to reproduce, but I haven’t found a way to solve it yet…

Can confirm that this also works on MacOS with LLVM 20:

% rustc +succinct --version
rustc 1.87.0-dev

% ld.lld --version
Homebrew LLD 20.1.7 (compatible with GNU linkers)

AGH YOU LEGEND!! it works. thanks so much, i can now work with my lsp again XD. great job

We are planning to release a new succinct Rust toolchain that is build with LLVM 20, that should theorically solve this issue.

Yeah, https://github.com/alpenlabs/strata-bridge/

And fwiw, on my Ubuntu machine rustc --version --verbose | grep LLVM returns LLVM version: 20.1.0 and I have no issues

Agh, great.

dnf install gcc git openssl-devel protobuf-compiler 
curl -L https://sp1up.succinct.xyz | bash
git clone --depth 1 https://github.com/alpenlabs/strata-bridge
cargo c

You might need clang or sqlx-cli but i think that’s later on in the build and i hit the issues before i installed it. This is just a fresh setup so this is what i ran before trying