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

Fix CI LLVM to work on NixOS out of the box #76667

Merged
merged 1 commit into from
Sep 14, 2020
Merged

Conversation

matklad
Copy link
Member

@matklad matklad commented Sep 13, 2020

r? @Mark-Simulacrum

Tested locally, seems to work!

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Sep 13, 2020
@Mark-Simulacrum
Copy link
Member

Hm, I worry that this is probably not enough. In particular, we also download FileCheck, and if we don't fix that it'll probably break during codegen tests (x.py test --stage 1 src/test/codegen).

For now I'm fine with just explicitly fixing both, though ideally we'd not hard code that..

@Mark-Simulacrum
Copy link
Member

r=me with FileCheck fixed as well

@matklad
Copy link
Member Author

matklad commented Sep 13, 2020

@bors r=Mark-Simulacrum rollup

@bors
Copy link
Contributor

bors commented Sep 13, 2020

📌 Commit cf07201 has been approved by Mark-Simulacrum

@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 Sep 13, 2020
RalfJung added a commit to RalfJung/rust that referenced this pull request Sep 13, 2020
Fix CI LLVM to work on NixOS out of the box

r? @Mark-Simulacrum

Tested locally, seems to work!
@jyn514 jyn514 added T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) A-contributor-roadblock Area: Makes things more difficult for new contributors to rust itself labels Sep 13, 2020
bors added a commit to rust-lang-ci/rust that referenced this pull request Sep 13, 2020
…as-schievink

Rollup of 12 pull requests

Successful merges:

 - rust-lang#75559 (unions: test move behavior of non-Copy fields)
 - rust-lang#76441 (Note that parallel-compiler = true causes tests to fail)
 - rust-lang#76527 (Remove internal and unstable MaybeUninit::UNINIT.)
 - rust-lang#76629 (Simplify iter zip struct doc)
 - rust-lang#76640 (Simplify SyncOnceCell's `take` and `drop`.)
 - rust-lang#76646 (Add mailmap entry)
 - rust-lang#76651 (Remove Windows details from Unix and VmWorks symlink() docstrings)
 - rust-lang#76663 (Simplify iter chain struct doc)
 - rust-lang#76665 (slice::from_raw_parts: explicitly mention that data must be initialized)
 - rust-lang#76667 (Fix CI LLVM to work on NixOS out of the box)
 - rust-lang#76668 (Add visualization of rustc span in doc)
 - rust-lang#76677 (note that test_stable_pointers does not reflect a stable guarantee)

Failed merges:

r? `@ghost`
@bors bors merged commit 51cf121 into rust-lang:master Sep 14, 2020
@rustbot rustbot added this to the 1.48.0 milestone Sep 14, 2020
@Nadrieril
Copy link
Member

When building the compiler on NixOS with CI LLVM I get:

/.../rust/build/x86_64-unknown-linux-gnu/ci-llvm/bin/llvm-config: error while loading shared libraries: libz.so.1: cannot open
 shared object file: No such file or directory

This can be fixed by adding zlib to LD_LIBRARY_PATH. Is this expected, given that this PR says "out of the box"? Am I missing something?

@matklad matklad deleted the patch-llvm branch October 17, 2020 18:41
@matklad
Copy link
Member Author

matklad commented Oct 17, 2020

Ah, I am just building with this "kitchen sink" shell.nix: https://github.com/matklad/config/blob/ed3acd6a99eebe5e91df4cf90fa07f35dcaa88dd/shell.nix

I think there's a bunch of libs rust needs to build on nixos (I rememeber some ncurses related failures, for example). Not sure if we can fix that in the build. Unlike elfpatching, those things require dependnecies to be installed somewhere.

@Nadrieril
Copy link
Member

Nadrieril commented Oct 17, 2020

Oh I see, that makes sense. It's the first time I've had issues I think, but I've not done anything fancy. Would it make sense to include a shell.nix in the rustc codebase? 👼

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-contributor-roadblock Area: Makes things more difficult for new contributors to rust itself 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