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

Improve error message with llvm-config cannot be found. #1139

Open
MurraySobol opened this issue Sep 28, 2024 · 1 comment
Open

Improve error message with llvm-config cannot be found. #1139

MurraySobol opened this issue Sep 28, 2024 · 1 comment
Labels

Comments

@MurraySobol
Copy link

When I ran this command: cargo install --git https://github.com/immunant/c2rust.git c2rust
I got this error:
Compiling pest_meta v2.7.13
error: failed to run custom build command for c2rust-ast-exporter v0.19.0 (C:\Users\murra\.cargo\git\checkouts\c2rust-2a3ef4c32beab81a\516b30e\c2rust-ast-exporter)

Caused by:
process didn't exit successfully: C:\Users\murra\AppData\Local\Temp\cargo-installBzMHID\release\build\c2rust-ast-exporter-984e14db3215a3eb\build-script-build (exit code: 101)
--- stderr
thread 'main' panicked at c2rust-build-paths\src\lib.rs:88:44:
called Result::unwrap() on an Err value: Os { code: 2, kind: NotFound, message: "The system cannot find the file specified." }
note: run with RUST_BACKTRACE=1 environment variable to display a backtrace
warning: build failed, waiting for other jobs to finish...
error: failed to compile c2rust v0.19.0 (https://github.com/immunant/c2rust.git#516b30e3), intermediate artifacts can be found at C:\Users\murra\AppData\Local\Temp\cargo-installBzMHID.
To reuse those artifacts with a future compilation, set the environment variable CARGO_TARGET_DIR to that path.

It appears, to me, that a file is missing??
Please advise.
Thanks
Murray

@thedataking
Copy link
Contributor

The error message could be better but the error is likely a failure to pick up llvm-config. You can set LLVM_CONFIG_PATH or LLVM_LIB_DIR to avoid this problem assuming your system has the prerequisites installed.

@thedataking thedataking changed the title Installation failure Improve error message with llvm-config cannot be found. Oct 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants