Skip to content
Unverified Commit baa3d6f4 authored by Peter Kolloch's avatar Peter Kolloch Committed by GitHub
Browse files

buildRustCrate: Make CARGO_MANIFEST_DIR absolute

While it is not obvious from the source, cargo sets CARGO_MANIFEST_DIR to an absolute directory. This let to a build problem with the popular "tera" crate using the "pest" crate.

## Cargo details

The variable is set here:

https://github.com/rust-lang/cargo/blob/f7c91ba6220e1b96aa14e5964e7074452f9551fb/src/cargo/core/compiler/compilation.rs#L229

and computed from the `manifest_path`:

https://github.com/rust-lang/cargo/blob/f7c91ba6220e1b96aa14e5964e7074452f9551fb/src/cargo/core/package.rs#L163

The manifest path is also exported via `cargo metadata` where you can see that it is absolute.
parent 93ce3df6
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment