-
Notifications
You must be signed in to change notification settings - Fork 8
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 test bug fixes of dependencies of libcore
/libstd
on targets where -Zbuild-std
is required.
#77
Comments
|
Yea, it is not currently possible to customize the source. In addition to what @12101111 mentioned, I would personally just build rustc locally with a patch in Closing as this is tracked in other issues. |
@ehuss In the "
|
You should be able to edit the root [patch.crates-io]
compiler_builtins = { path = "../compiler-builtins" } Then run |
This works for testing Now, how do I tell cargo and/or the injection logic (local patch is fine) to use my local copy of AT2XT Still FailsHonestly, I'm not sure why the above patch works; diff --git a/Cargo.toml b/Cargo.toml
index bcb79e1..67fa3b1 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -52,3 +52,6 @@ lto = "fat"
codegen-units = 1
opt-level = "s"
lto = "fat"
+
+[patch.crates-io]
+compiler_builtins = { version="0.1.53", path = "/home/william/Projects/toolchains/compiler-builtins" } william@xubuntu-dtrain:~/Projects/embedded/msp430/AT2XT$ cargo update
Updating crates.io index
warning: Patch `compiler_builtins v0.1.53 (/home/william/Projects/toolchains/compiler-builtins)` was not used in the crate graph.
Check that the patched package version and available features are compatible
with the dependency requirements. If the patch has a different version from
what is locked in the Cargo.lock file, run `cargo update` to use the new
version. This may also occur with an optional dependency that is not enabled. And ultimately, when I try compiling
Why is my patch being honored when Addendum
|
Oh, I think I misled you a little, as I was thinking of just building your target with |
This works. Because this threw me off, I'll add this as a note to future-me (it's prob written down somewhere already): If you want to test changes to
You must pass a comma-separated list of targets to get all the
the
|
Problem
As of last week, CI for an msp430 firmware I test against nightly began failing.
compiler-builtins
, which is a dependency oflibcore
/libstd
was updated in rust-lang/rust@88f1bf7, and broke a few platforms, including msp430. I figured out the problem, opened an issue, and have attempted to create a local fix that I wish to test.Unfortunately, I am not able to test locally, because it appears that there's no way to override Rust's internal
Cargo.lock
for testing bug fixes tocompiler-builtins
. Targets which providelibstd
/libcore
don't have this problem because providinglibstd
/libcore
means Rust thinks those dependencies are always up to date. My fix probably works, but I'm not comfortable submitting a PR until I have tested locally. Is it possible to provide provisions for overriding Rust'sCargo.lock
and internal cargo manifests for the purpose of testing bug fixes?I've elaborated on the problem in another issue. I'm reproducing it here for convenience:
Issue #441
I have a fix locally for #441. Unfortunately I can't get
-Zbuild-std=core
to choose the correct version ofcompiler_builtins
with my changes, so that I can test... compilation ofcompiler_builtins
with my changes.patch
ingcompiler-builtins
This patch appears to do nothing (although I may have specified it incorrectly, tbf):
patch
ingrust
I genuinely don't understand the resulting error. You say
0.1.53
meets the requirements to be chosen and simultaneously isn't acceptable. So which is it?:Other Remarks
In addition,
libcore
doesn't listcompiler_builtins
as a dependency, so why is-Zbuild-std=core
trying to build it anyway?The text was updated successfully, but these errors were encountered: