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

rust: 1.46.0 -> 1.47.0 #100038

Merged
merged 1 commit into from Oct 12, 2020
Merged

rust: 1.46.0 -> 1.47.0 #100038

merged 1 commit into from Oct 12, 2020

Conversation

@Kloenk
Copy link
Member

@Kloenk Kloenk commented Oct 8, 2020

Motivation for this change

update rust to 1.47.0
https://blog.rust-lang.org/2020/10/08/Rust-1.47.html

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.
@Kloenk
Copy link
Member Author

@Kloenk Kloenk commented Oct 8, 2020

I don't have a MacOS to build rustc, so I can only test it under NixOS

@Kloenk Kloenk marked this pull request as ready for review Oct 8, 2020
@@ -46,6 +46,9 @@ rec {
patchelf \
--set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) \
"$out/bin/rustc"
# rustc bootstrap needs libz
Copy link
Member

@petabyteboy petabyteboy Oct 8, 2020

Not sure if it's really necessary, since this will go to staging anyways, but it wouldn't hurt to make sure this is only added for the new versions that need zlib, so that the old versions stay the same and can be cached.

Copy link
Member Author

@Kloenk Kloenk Oct 8, 2020

added a stdenv.lib.versionAtLeast for that

Copy link
Member

@Ericson2314 Ericson2314 Oct 11, 2020

@Kloenk I think @petabyteboy means making that itself comment be outside all string literals so that it doesn't force rebuilds.

That sounds to me like general good practice that I would agree with.

@Kloenk Kloenk force-pushed the rust_1_47 branch 3 times, most recently from 8200d88 to db452e5 Oct 12, 2020
patchelf \
--set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) \
"$out/bin/rustc"
${optionalString (stdenv.lib.versionAtLeast version "1.46")
# rustc bootstrap needs libz starting from 1.46
''
ln -s ${zlib}/lib/libz.so.1 $out/lib/libz.so.1
ln -s ${zlib}/lib/libz.so $out/lib/libz.so
''}
patchelf \
--set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) \
"$out/bin/rustdoc"
Copy link
Member

@Ericson2314 Ericson2314 Oct 12, 2020

What you have now still introduces a blank line, however, I would do

Suggested change
patchelf \
--set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) \
"$out/bin/rustc"
${optionalString (stdenv.lib.versionAtLeast version "1.46")
# rustc bootstrap needs libz starting from 1.46
''
ln -s ${zlib}/lib/libz.so.1 $out/lib/libz.so.1
ln -s ${zlib}/lib/libz.so $out/lib/libz.so
''}
patchelf \
--set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) \
"$out/bin/rustdoc"
patchelf \
--set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) \
"$out/bin/rustc"
'' + optionalString (stdenv.lib.versionAtLeast version "1.46")
# rustc bootstrap needs libz starting from 1.46
''
ln -s ${zlib}/lib/libz.so.1 $out/lib/libz.so.1
ln -s ${zlib}/lib/libz.so $out/lib/libz.so
''
+ ''
patchelf \
--set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) \
"$out/bin/rustdoc"

and then parens around the all concatenated thing (which I cannot include in the suggestion, sadly).

@Ericson2314 Ericson2314 merged commit 7568c3f into NixOS:staging Oct 12, 2020
17 checks passed
17 checks passed
@github-actions[bot]
tests tests
Details
@github-actions[bot]
action
Details
@ofborg[bot]
Evaluation Performance Report Evaluator Performance Report
Details
@github-actions[bot]
Wait for ofborg
Details
@ofborg[bot]
grahamcofborg-eval ^.^!
Details
@ofborg[bot]
grahamcofborg-eval-check-maintainers matching changed paths to changed attrs...
Details
@ofborg[bot]
grahamcofborg-eval-check-meta config.nix: checkMeta = true
Details
@ofborg[bot]
grahamcofborg-eval-darwin nix-instantiate --arg nixpkgs { outPath=./.; revCount=999999; shortRev="75ead1b"; rev="75ead1b43a0d41199d0a14e44da4bf8a11dbeedc"; } ./pkgs/t
Details
@ofborg[bot]
grahamcofborg-eval-lib-tests nix-build --arg pkgs import ./. {} ./lib/tests/release.nix
Details
@ofborg[bot]
grahamcofborg-eval-nixos nix-instantiate --arg nixpkgs { outPath=./.; revCount=999999; shortRev="75ead1b"; rev="75ead1b43a0d41199d0a14e44da4bf8a11dbeedc"; } ./nixos/
Details
@ofborg[bot]
grahamcofborg-eval-nixos-manual nix-instantiate --arg nixpkgs { outPath=./.; revCount=999999; shortRev="75ead1b"; rev="75ead1b43a0d41199d0a14e44da4bf8a11dbeedc"; } ./nixos/
Details
@ofborg[bot]
grahamcofborg-eval-nixos-options nix-instantiate --arg nixpkgs { outPath=./.; revCount=999999; shortRev="75ead1b"; rev="75ead1b43a0d41199d0a14e44da4bf8a11dbeedc"; } ./nixos/
Details
@ofborg[bot]
grahamcofborg-eval-nixpkgs-manual nix-instantiate --arg nixpkgs { outPath=./.; revCount=999999; shortRev="75ead1b"; rev="75ead1b43a0d41199d0a14e44da4bf8a11dbeedc"; } ./pkgs/t
Details
@ofborg[bot]
grahamcofborg-eval-nixpkgs-tarball nix-instantiate --arg nixpkgs { outPath=./.; revCount=999999; shortRev="75ead1b"; rev="75ead1b43a0d41199d0a14e44da4bf8a11dbeedc"; } ./pkgs/t
Details
@ofborg[bot]
grahamcofborg-eval-nixpkgs-unstable-jobset nix-instantiate --arg nixpkgs { outPath=./.; revCount=999999; shortRev="75ead1b"; rev="75ead1b43a0d41199d0a14e44da4bf8a11dbeedc"; } ./pkgs/t
Details
@ofborg[bot]
grahamcofborg-eval-package-list nix-env -qa --json --file .
Details
@ofborg[bot]
grahamcofborg-eval-package-list-no-aliases nix-env -qa --json --file . --arg config { allowAliases = false; }
Details
@Kloenk Kloenk deleted the rust_1_47 branch Oct 12, 2020
@vcunat
Copy link
Member

@vcunat vcunat commented Oct 21, 2020

I don't have a MacOS to build rustc, so I can only test it under NixOS

Note that rustc.x86_64-darwin is a blocker for the nixpkgs-unstable channel (though I do consider it less important than most of other channels).

@vcunat
Copy link
Member

@vcunat vcunat commented Oct 21, 2020

Oh, hopefully resolved by #101136.

@zowoq
Copy link
Contributor

@zowoq zowoq commented Oct 21, 2020

I've built 1.47 with llvmPackages_5 on darwin.

Thanks for pushing 90094b0 @vcunat.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

5 participants