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

Search codegen backends based on target libdir instead of sysroot #57101

Merged
merged 1 commit into from
Jan 5, 2019
Merged

Search codegen backends based on target libdir instead of sysroot #57101

merged 1 commit into from
Jan 5, 2019

Conversation

o01eg
Copy link
Contributor

@o01eg o01eg commented Dec 24, 2018

Fixes #57014

Fixes cases with custom libdir when it consists of two or more parts.

Fixes cases with custom libdir when it consists of two or more parts.
@rust-highfive
Copy link
Collaborator

r? @davidtwco

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

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Dec 24, 2018
@davidtwco
Copy link
Member

r? @alexcrichton

@alexcrichton
Copy link
Member

@bors: r+

@bors
Copy link
Contributor

bors commented Jan 2, 2019

📌 Commit 4e7d53d has been approved by alexcrichton

@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 Jan 2, 2019
Mark-Simulacrum added a commit to Mark-Simulacrum/rust that referenced this pull request Jan 3, 2019
Search codegen backends based on target libdir instead of sysroot

Fixes rust-lang#57014

Fixes cases with custom libdir when it consists of two or more parts.
@bors
Copy link
Contributor

bors commented Jan 5, 2019

⌛ Testing commit 4e7d53d with merge 6861426...

bors added a commit that referenced this pull request Jan 5, 2019
Search codegen backends based on target libdir instead of sysroot

Fixes #57014

Fixes cases with custom libdir when it consists of two or more parts.
@bors
Copy link
Contributor

bors commented Jan 5, 2019

☀️ Test successful - status-appveyor, status-travis
Approved by: alexcrichton
Pushing 6861426 to master...

@bors bors merged commit 4e7d53d into rust-lang:master Jan 5, 2019
@rust-highfive
Copy link
Collaborator

📣 Toolstate changed by #57101!

Tested on commit 6861426.
Direct link to PR: #57101

💔 miri on windows: test-pass → test-fail (cc @oli-obk @RalfJung @eddyb, @rust-lang/infra).

rust-highfive added a commit to rust-lang-nursery/rust-toolstate that referenced this pull request Jan 5, 2019
Tested on commit rust-lang/rust@6861426.
Direct link to PR: <rust-lang/rust#57101>

💔 miri on windows: test-pass → test-fail (cc @oli-obk @RalfJung @eddyb, @rust-lang/infra).
@RalfJung
Copy link
Member

RalfJung commented Jan 5, 2019

Uh... any idea why this would affect Miri only on Windows, and what we could do about that?

The error is

error: failed to find a `codegen-backends` folder in the libdir candidates:
* C:\projects\rust\build\x86_64-pc-windows-msvc\lib\rustlib\x86_64-pc-windows-msvc\lib
* \\?\C:\projects\rust\build\x86_64-pc-windows-msvc\stage2\bin
* \\?\C:\projects\rust\build\x86_64-pc-windows-msvc\stage2\bin\rustlib\x86_64-pc-windows-msvc\lib

@o01eg
Copy link
Contributor Author

o01eg commented Jan 5, 2019

It's strange. What is correct place of codegen library?

@RalfJung
Copy link
Member

RalfJung commented Jan 5, 2019

I have no idea, I hoped you'd tell me.^^

@o01eg
Copy link
Contributor Author

o01eg commented Jan 5, 2019

I suppose it could be broken because windows places dynamic libraries in the "bin" folder.

@o01eg
Copy link
Contributor Author

o01eg commented Jan 5, 2019

I'm afraid other tools will fail as well but they were already broken.

@mati865
Copy link
Contributor

mati865 commented Jan 5, 2019

Unfortunately it broke all the tools for MSVC target: #57303

I suppose it could be broken because windows places dynamic libraries in the "bin" folder.

That's correct, for both Windows target bin must be in PATH.

@o01eg
Copy link
Contributor Author

o01eg commented Jan 6, 2019

How are executable binaries and codegen and rustc_driver libraries placed on windows? It looks like it requires other way to calculate target libdir and codegen folder.

@matthiaskrgr
Copy link
Member

matthiaskrgr commented Jan 6, 2019

I'm afraid other tools will fail as well but they were already broken.

They would have been fixed by #57303 but the pr broke them in a way I cannot fix as I don't have windows.

Could you please provide a fix for this?

@mati865
Copy link
Contributor

mati865 commented Jan 6, 2019

Generally the only difference in files placement between UNIX and Windows (MinGW at least) should be runtime lib placement. On UNIX they are inside /usr/lib and on Windows they are usually located alongside executables because they have to be in PATH.

Here is the tree of MinGW toolchain installed with rustup: tree.txt

@o01eg
Copy link
Contributor Author

o01eg commented Jan 6, 2019

I could try to fix it after tomorrow. I think it better to revert PR now and then I try to fix it.
But it better to make a test to prevent this breakage.

matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Jan 7, 2019
This reverts commit 6861426, reversing
changes made to cae623c.

Should fix tools on windows.

Reopens rust-lang#57014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants