Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] cargo risczero build failure #1674

Open
shriphani opened this issue Apr 15, 2024 · 5 comments
Open

[BUG] cargo risczero build failure #1674

shriphani opened this issue Apr 15, 2024 · 5 comments
Labels
bug Something isn't working

Comments

@shriphani
Copy link

Bug Report

Hi, I have a fairly simple project I'd like to build and I used cargo risczero build --manifest-path /path/to/guest/Cargo.toml.

I get this error:

49.58
49.58   --- stderr
49.58   config.status: error: in `/src/target/release/build/protobuf-src-ce85a8c6aafaee11/out/install/build':
49.58   config.status: error: Something went wrong bootstrapping makefile fragments
49.58       for automatic dependency tracking.  If GNU make was not used, consider
49.58       re-running the configure script with MAKE="gmake" (or whatever is
49.58       necessary).  You can also try re-running configure with the
49.58       '--disable-dependency-tracking' option to at least be able to build
49.58       the package (albeit without support for automatic dependency tracking).
49.58   See `config.log' for more details
49.58   thread 'main' panicked at '
49.58   command did not execute successfully, got: exit status: 1
49.58
49.58   build script failed, must exit now', /root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/autotools-0.2.6/src/lib.rs:781:5
49.58   note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
------
Dockerfile:8
--------------------
ENV CARGO_TARGET_DIR="target"
RUN cargo +risc0 fetch --locked --target riscv32im-risc0-zkvm-elf --manifest-path $CARGO_MANIFEST_PATH
RUN cargo +risc0 build --release --locked --target riscv32im-risc0-zkvm-elf --manifest-path $CARGO_MANIFEST_PATH
   9 |
# export stage
--------------------

Steps to Reproduce

Expected behavior

Your Environment

  • risc0-zkvm version: 0.21.0
  • Rust version: 1.77.2
  • Platform/OS: Apple silicon

Additional context

@shriphani shriphani added the bug Something isn't working label Apr 15, 2024
Copy link

linear bot commented Apr 15, 2024

@SchmErik
Copy link
Contributor

@shriphani does this happen on the starter template that you get from running cargo risczero new?

@shriphani
Copy link
Author

Hi @SchmErik ,

I started with the template but moved some stuff around so my top_level_member crate and the risc0 guest programs can share my core_data_structures - everything works during development, I see the _ELF and _ID variables for my guest programs. It is only cargo risczero build that fails. Here is my workspace:

members = [
  "top_level_member",
  .
  .
  .
  "core_data_structures",
  "merkle",
  "core-methods",    <--- This is the risc0 methods crate (i.e. contains the `guest` dir).
  "word",
  "methods-tests",
]

core-methods itself looks like:

[package]
name = "core-methods"
version = "0.1.0"
edition = "2021"

[build-dependencies]
risc0-build = { version = "0.21.0" }

[package.metadata.risc0]
methods = ["guest"]

and core-methods/guest/Cargo.toml looks like:

[package]
name = "programs"
version = "0.1.0"
edition = "2021"

[workspace]

[dependencies]
# If you want to try (experimental) std support, add `features = [ "std" ]` to risc0-zkvm
risc0-zkvm = { version = "0.21.0", default-features = false }
word = { path = "../../word" }
merkle = { path = "../../merkle" }
core_data_structures = { path = "../../core_data_structures" }

[[bin]]
.
.

word itself has 1 dependency :

serde = { workspace = true }

merkle's dependencies:

sha2 = { workspace = true }
rs_merkle = { workspace = true }
risc0-zkvm = { workspace = true }
serde = { workspace = true }

word = { path = "../word" }

Let me know if you need more information.

@shriphani
Copy link
Author

Hi, @SchmErik - any update on this? Can I be of any use?

Thanks

@shriphani
Copy link
Author

Hi, bumping this again for visibility - did you get a chance to look at this? Would be happy to help with additional info.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants