-
Notifications
You must be signed in to change notification settings - Fork 9
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
cargo-pgo ignores all rustflags defined in config.toml file, how to pass custom rustflags to pgo build? #49
Comments
Hi, this has been already reported here. Could you just pass these flags manually in RUSTFLAGS? It's not trivial to append rustflags in |
But my |
I see. I did consult this with the Cargo developers and we didn't find a much better way. So perhaps this will require cargo-pgo to parse config.toml to make this work. Out of curiosity, how do you use per-profile rustflags? Didn't you mean per-target? |
Cargo has already supported |
Oh, it's unstable! Cool. I think that I have an idea how this could be done. I also battled with overriding rustflags in https://github.com/Kobzol/cargo-remark, and there the solution was to use |
Okay, it seems to work! $ cargo install --git https://github.com/kobzol/cargo-pgo --branch append-to-rustflags If it works for you. |
Oh, my bad, it's not actually unstable (it was stabilized in |
And also
is applied. |
Maybe the entire chain of rustflags should be |
I don't think that it's in scope of Does it work for you? |
Well, So the better option is, [host] first if not fall back to [build] to read rustflags. |
Where is |
Looks like
cargo pgo [optimize] build
ignores rustflags in config.toml file, is there a way to pass it to PGO subcommand?The text was updated successfully, but these errors were encountered: