-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
Cannot set TARGET_*_RUNNER to a binary whose filename contains a whitespace #10892
Comments
I would recommend using the newly stabilized |
|
To make sure I understand correctly: would something like this
make cargo call How do quotes have to be escaped in the binary name? If I understand https://toml.io/en/v0.3.0 correctly, I should do the following:
|
Depends on how you are launching cargo (whether it is from a shell script or from Rust). Escaping https://doc.rust-lang.org/nightly/cargo/reference/config.html#command-line-overrides gives some examples of different ways to escape things via shell. |
We are launching it from Rust. |
The I tried this on the terminal (in a random project, I used xargo):
and expected an error, but it actually works fine. If instead I do
then I get the expected error. |
Also it looks like #8629 hasn't entirely fixed the issue in the PR description... when I pass |
|
Ah, that's a bummer, but you are right -- it doesn't work in rustc either. But |
Okay, this seems to be working. Thanks a lot. :D I will close this issue, since the issue with setting a runner with spaces is resolved. I will open a new issue for what double- |
Is it possible that when I set
TARGET_*_RUNNER
to a value likeC:\Users\Good Game\.rustup\toolchains\nightly-x86_64-pc-windows-msvc\bin\cargo-miri.exe
, that cargo will split this at the whitespace and try to run the binaryC:\Users\Good
? That is my conclusion of what happens in rust-lang/miri#2417, which took me by surprise. After all, RUSTC_WRAPPER, RUSTC and RUSTDOC work fine when they contain whitespace. Only the runner variables seem to have this strange behavior.Reading the docs more carefully now, this says "Type: string or array of strings". I guess that helps for when the variable is set via toml, but when I set this via the environment (which I think is our only choice here), then how do I configure a runner that is stored in a directory that contains a whitespace in its name? It looks like StringList (which I think is where this ends up?) interprets a single string as being separated at whitespaces, rather than interpreting it as a one-element list of strings.
The text was updated successfully, but these errors were encountered: