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

Replace any existing build/host symlink #109811

Merged
merged 1 commit into from
Apr 2, 2023
Merged

Conversation

jyn514
Copy link
Member

@jyn514 jyn514 commented Mar 31, 2023

This has two advantages:

  1. If build.build changes between runs, the symlink is no longer silently wrong.
  2. If the entire build directory is moved, the symlink is no longer broken because it points to the wrong absolute path.

@rustbot
Copy link
Collaborator

rustbot commented Mar 31, 2023

r? @albertlarsan68

(rustbot has picked a reviewer for you, use r? to override)

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) labels Mar 31, 2023
@Mark-Simulacrum
Copy link
Member

If the entire build directory is moved, the symlink is no longer broken because it points to the wrong absolute path.

Is there a reason we need an absolute path, not a relative one? At least on Linux I know that relative symlink seem to work fine...

@jyn514
Copy link
Member Author

jyn514 commented Mar 31, 2023

No strong reason, but I didn't want to spend time on it when this also fixes the problem just as well.

@Mark-Simulacrum
Copy link
Member

Well, this PR would only fix it after actually running x.py, right? Whereas a relative path avoids breakage in that case entirely.

In any case, I agree this seems fine in general and just wanted to raise the question, no need to do it in this PR.

@jyn514
Copy link
Member Author

jyn514 commented Mar 31, 2023

I guess it could cause issues if you have some tool running in the background that depends on the path? Not sure what would be looking in the sysroot like that and renaming the build directory and not running x.py. I'd rather not change things until someone complains, I worry that relative paths won't work on Windows.

@Mark-Simulacrum
Copy link
Member

@bors r+

@bors
Copy link
Contributor

bors commented Apr 2, 2023

📌 Commit 045825e9ec073f0500d3c5cefbf62975fac7aaa5 has been approved by Mark-Simulacrum

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Apr 2, 2023
@bors
Copy link
Contributor

bors commented Apr 2, 2023

⌛ Testing commit 045825e9ec073f0500d3c5cefbf62975fac7aaa5 with merge 8c22b9ff4691e4b52649c235caa6dd9079332df3...

@bors
Copy link
Contributor

bors commented Apr 2, 2023

💔 Test failed - checks-actions

@bors bors added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Apr 2, 2023
@rust-log-analyzer

This comment has been minimized.

@jyn514
Copy link
Member Author

jyn514 commented Apr 2, 2023

looks spurious?

/Users/runner/work/rust/rust/src/llvm-project/llvm/lib/Target/RISCV/RISCVInstrInfoV.td:1710:11: error: Record `VLOXSEG7EI8_V' does not have a field named `isConvergent'!

@bors retry

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Apr 2, 2023
@bors
Copy link
Contributor

bors commented Apr 2, 2023

⌛ Testing commit 045825e9ec073f0500d3c5cefbf62975fac7aaa5 with merge 0c86a8373b08aa5da8c24a93263e6d1f626e73fd...

@bors
Copy link
Contributor

bors commented Apr 2, 2023

💔 Test failed - checks-actions

@bors bors added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Apr 2, 2023
@rust-log-analyzer

This comment has been minimized.

@jyn514 jyn514 added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Apr 2, 2023
This has two advantages:
1. If `build.build` changes between runs, the symlink is no longer
   silently wrong.
2. If the entire build directory is moved, the symlink is no longer
   broken because it points to the wrong absolute path.
@jyn514
Copy link
Member Author

jyn514 commented Apr 2, 2023

@bors r=Mark-Simulacrum rollup=iffy

@bors
Copy link
Contributor

bors commented Apr 2, 2023

📌 Commit 28b7e6a has been approved by Mark-Simulacrum

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Apr 2, 2023
@bors
Copy link
Contributor

bors commented Apr 2, 2023

⌛ Testing commit 28b7e6a with merge 3a8a131...

@bors
Copy link
Contributor

bors commented Apr 2, 2023

☀️ Test successful - checks-actions
Approved by: Mark-Simulacrum
Pushing 3a8a131 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Apr 2, 2023
@bors bors merged commit 3a8a131 into rust-lang:master Apr 2, 2023
@rustbot rustbot added this to the 1.70.0 milestone Apr 2, 2023
@rust-timer
Copy link
Collaborator

Finished benchmarking commit (3a8a131): comparison URL.

Overall result: no relevant changes - no action needed

@rustbot label: -perf-regression

Instruction count

This benchmark run did not return any relevant results for this metric.

Max RSS (memory usage)

Results

This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
-2.6% [-2.6%, -2.6%] 1
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) -2.6% [-2.6%, -2.6%] 1

Cycles

This benchmark run did not return any relevant results for this metric.

@jyn514 jyn514 deleted the symlink-fixes branch April 2, 2023 19:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merged-by-bors This PR was explicitly merged by bors. S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants