-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Build proc-macro-test-impl out-of-tree #12831
Build proc-macro-test-impl out-of-tree #12831
Conversation
Building it in-place fails in rust CI because the source directory is read-only. This changes `proc-macro-test`'s build script to first copy `imp` under `OUT_DIR` (which is read-write). It also prints stdout/stderr for the nested cargo invocation, should it fail. (I've seen failures in rust CI that I couldn't explain, and when they take 25 minutes to reproduce, you want to have that info)
Tested locally with: $ cd crates/proc-macro-test
$ sudo chown root:root -R ./imp
$ (cd imp && cargo build)
error: Permission denied (os error 13) at path "/home/amos/bearcove/rust-analyzer/crates/proc-macro-test/imp/targetC0YSqJ"
$ cargo clean -q && cargo test -v
(tests pass) |
@bors r+ |
…eykril Build proc-macro-test-impl out-of-tree Building it in-place fails in rust CI because the source directory is read-only. This changes `proc-macro-test`'s build script to first copy `imp` under `OUT_DIR` (which is read-write). It also prints stdout/stderr for the nested cargo invocation, should it fail. (I've seen failures in rust CI that I couldn't explain, and when they take 25 minutes to reproduce, you want to have that info) This change is tracked in: * #12818 Maintainer impact: none.
Co-authored-by: Laurențiu Nicola <[email protected]>
Co-authored-by: Laurențiu Nicola <[email protected]>
@bors delegate+ In case you remove the temporary directory at the end (you might also need to |
✌️ @fasterthanlime can now approve this pull request |
It's under I'm gonna invoke "we might want to investigate that dir after a build" to not have to add additional cleanups 😄 (If it was under |
@bors r+ |
☀️ Test successful - checks-actions |
Building it in-place fails in rust CI because the source directory is read-only. This changes
proc-macro-test
's build script to firstcopy
imp
underOUT_DIR
(which is read-write).It also prints stdout/stderr for the nested cargo invocation, should it fail. (I've seen failures in rust CI that I couldn't explain, and
when they take 25 minutes to reproduce, you want to have that info)
This change is tracked in:
Maintainer impact: none.