Summary: | Mk/Uses/cargo.mk: "make cargo-crates" fails to generate CARGO_CRATES with new Cargo.lock format | ||||||
---|---|---|---|---|---|---|---|
Product: | Ports & Packages | Reporter: | Jan Beich <jbeich> | ||||
Component: | Ports Framework | Assignee: | FreeBSD Rust Team <rust> | ||||
Status: | Closed FIXED | ||||||
Severity: | Affects Only Me | CC: | ports-bugs | ||||
Priority: | --- | ||||||
Version: | Latest | ||||||
Hardware: | Any | ||||||
OS: | Any | ||||||
Attachments: |
|
Description
Jan Beich
2019-12-04 10:56:30 UTC
Created attachment 209681 [details] cargo-crates.diff That should be trivial to fix. Can you try with this patch? I checked against the collection of Cargo.lock at [1] and there were no significant differences (some crates were ordered differently), so hopefully there are no real regressions. [1] https://github.com/t6/cargo-lock-examples Comment on attachment 209681 [details]
cargo-crates.diff
Appears to help: with the patch CARGO_CRATES is populated and do-build doesn't use network. The actual build hit the same error as in a snapshot before the new Cargo.lock format.
A commit references this bug: Author: tobik Date: Thu Dec 5 06:42:23 UTC 2019 New revision: 519063 URL: https://svnweb.freebsd.org/changeset/ports/519063 Log: Mk/Uses/cargo.mk: Support new Cargo.lock format The new format [1,2] dropped the [metadata] table. As a consequence our cargo-crates.awk script no longer outputs CARGO_CRATES. We can get the crate list from the various [[package]] tables instead. This should work with the new as well as the old format. [1] https://github.com/rust-lang/cargo/pull/7070 [2] https://github.com/rust-lang/cargo/pull/7579 PR: 242416 Reported by: jbeich Changes: head/Mk/Scripts/cargo-crates.awk |