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

Do not unconditionally set the target. #323

Merged
merged 1 commit into from
Mar 23, 2024

Conversation

ehuss
Copy link
Collaborator

@ehuss ehuss commented Mar 2, 2024

This removes the CARGO_BUILD_TARGET environment variable which causes cargo to unconditionally work in "cross compile mode". This is different from a normal cargo invocation without the --target flag, in which case it runs in "host mode", where cargo and other tools have distinctly different behavior. This can be surprising when you get one behavior with cargo build and a different one with cargo bisect-rustc.

This was added in #159 to address some issue with using cross-rs with cargo bisect-rustc. I'm not sure why, as I would think the recommended behavior when using cross is to set the --target flag. The given PR didn't really explain the situation.

Closes #284

@ehuss
Copy link
Collaborator Author

ehuss commented Mar 7, 2024

I realize I made a mistake, it should set the target if the user sets --target on the command-line.

@ehuss ehuss merged commit 0dd894b into rust-lang:master Mar 23, 2024
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

can cargo-bisect-rustc respect the .cargo/config.toml?
2 participants