Page MenuHomeFreeBSD

lang/rust: Update to 1.56.0
ClosedPublic

Authored by tobik on Oct 18 2021, 6:01 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Mar 18, 6:23 PM
Unknown Object (File)
Wed, Mar 13, 8:39 PM
Unknown Object (File)
Sun, Mar 10, 4:07 PM
Unknown Object (File)
Sun, Mar 10, 4:06 PM
Unknown Object (File)
Sun, Mar 10, 4:06 PM
Unknown Object (File)
Sun, Mar 10, 4:06 PM
Unknown Object (File)
Sun, Mar 10, 4:06 PM
Unknown Object (File)
Sun, Mar 10, 4:06 PM
Subscribers

Details

Summary

Scheduled to be released on 2021-10-21.

https://internals.rust-lang.org/t/rust-1-56-0-pre-release-testing/15459
https://github.com/rust-lang/rust/blob/stable/RELEASES.md#version-1560-2021-10-21

Including changes to USES=cargo for https://bugs.freebsd.org/256581:

Uses/cargo: Rework git source support based on patch-in-config sections

Git sources from Cargo.lock are added to CARGO_CRATES through
the normal mechanism of make cargo-crates by the porter. They
are used to populate MASTER_SITES, DISTFILES with static
git-archive(1) tarballs a la USE_GITHUB, USE_GITLAB. In the
configure phase we generate [patch] sections in the config file
which will cause cargo update to auto-update Cargo.lock to point
to the appropriate extraction directories.

Normally cargo update would connect to the network to update all
Git sources but since rust-1.55.0 our cargo has been patched to
skip this when CARGO_FREEBSD_PORTS_SKIP_GIT_UPDATE is set in the
environment.

This replaces the old CARGO_USE_GITHUB, CARGO_USE_GITLAB hacks
where this was done by editing all Cargo.toml with sed(1) calls.

Additionally, we try to automatically infer the individiual crate
sub-directories inside the Git sources based on package.name in
Cargo.toml to remove the need for CARGO_GIT_SUBDIR.

USES=cargo also now sets WRKSRC_crate_$name for each crate to
point to the crate extraction directories.

Test Plan

poudriere 13.0 amd64 ok
ref13-aarch64 ok
ref13-i386 ok
ref13-ppc64 ok
ref12-amd64 ok
13.0 powerpc ok
13.0 powerpc64le ok
12.2 aarch64 ok
12.2 armv7 ok
12.2 armv6 fails to build, the problem with DOCS is back (armv7 is not affected)
Exp-run: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=259251

Diff Detail

Repository
rP FreeBSD ports repository
Lint
No Lint Coverage
Unit
No Test Coverage
Build Status
Buildable 42301
Build 39189: arc lint + arc unit

Event Timeline

tobik held this revision as a draft.
tobik edited the test plan for this revision. (Show Details)
  • Make sure to always set CARGO_FREEBSD_PORTS_SKIP_GIT_UPDATE
tobik published this revision for review.Oct 18 2021, 7:34 PM
tobik edited the test plan for this revision. (Show Details)

@jbeich Can you help unbreak games/veloren?

It fails with

error[E0557]: feature has been removed
   --> /wrkdirs/usr/ports/games/veloren/work/veloren-e4716147a7356eb13088e7d74ace3ccdcb5cd900/cargo-crates/packed_simd_2-0.3.5/src/lib.rs:215:5
    |
215 |     const_generics,
    |     ^^^^^^^^^^^^^^ feature has been removed
    |
    = note: removed in favor of `#![feature(adt_const_params]` and `#![feature(generic_const_exprs)]`

Also see https://github.com/rust-lang/packed_simd/commit/45d5347a0d2187c046a546a477d2a53111cd7713

Mk/bsd.gecko.mk
104

Sure.

tobik marked an inline comment as done.
  • Mk/bsd.gecko.mk: Bump to LLVM13 for LTO
  • multimedia/gstreamer1-plugins-rust: Drop ?tag= from tokio crate url to avoid changing distinfo
  • devel/cargo-c: Backport patch-in-config stabilization to unbreak gstreamer1-plugins-rust
  • textproc/ripgrep: Unbreak with Rust 1.56.0

@jbeich Can you help unbreak games/veloren?

Attached the complete fix (put under files/ without splitting). Builds fine at least on 12.2/14.0 amd64. Also works fine.

devel/cargo-c/files/patch-cargo-crates_cargo-0.56.0_src_cargo_core_features.rs
1 ↗(On Diff #97084)

Please, combine all related patches into one based on topic (e.g., files/patch-rust-1.56) and reference what it's based on aka the origin (e.g., https://github.com/rust-lang/cargo/commit/1e0d564ff01f ). Makes it easier to prune in future simply by looking whether the upstream change is part of the tag the port is being updated to.

tobik marked an inline comment as done.
  • games/veloren: Unbreak with Rust 1.56.0
  • www/firefox: Unbreak build with Rust 1.56.0
  • lang/rust: Exclude DOCS on armv6
  • www/firefox-esr: Unbreak build with Rust 1.56.0

Changes to my ports look OK. Mostly reviewed a month ago (via WIP on GitHub).

www/firefox/files/patch-rust-1.56.0
10
  • Rebase for databases/redisjson
  • Rebase for net-im/libsignal-client again...
pkubaj edited the test plan for this revision. (Show Details)
This revision was not accepted when it landed; it landed in state Needs Review.Oct 25 2021, 8:57 AM
This revision was automatically updated to reflect the committed changes.