Page MenuHomeFreeBSD

Mk/Uses/cargo.mk: Fix cargo-extract target
ClosedPublic

Authored by jbo on Dec 31 2023, 6:06 PM.
Tags
None
Referenced Files
Unknown Object (File)
Thu, Apr 18, 11:36 AM
Unknown Object (File)
Wed, Apr 17, 6:36 PM
Unknown Object (File)
Wed, Apr 17, 5:07 PM
Unknown Object (File)
Mon, Apr 15, 3:54 AM
Unknown Object (File)
Feb 17 2024, 10:01 PM
Unknown Object (File)
Feb 11 2024, 8:48 PM
Unknown Object (File)
Jan 31 2024, 4:18 PM
Unknown Object (File)
Jan 18 2024, 3:18 PM
Subscribers

Details

Summary

Fix an issue where the cargo-extract target fails when a port sets DIST_SUBDIR.

PR: 275634


Note: This is my first commit touching Mk/. I'd suggest reviewing this extra carefully :)
My shell scripting skills are also below-average.

Test Plan

I have tested this with the following script:

#!/bin/sh

PORTS_DIR=/usr/ports
for d in $(portgrep -u cargo -o); do
	echo "Testing port: " $d
	dir=$PORTS_DIR/$d
	make -C $dir extract || echo $d >> failures.lst
done	

Diff Detail

Repository
R11 FreeBSD ports repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

jbo requested review of this revision.Dec 31 2023, 6:06 PM
jbo created this revision.
jbo edited the test plan for this revision. (Show Details)
jbo edited the summary of this revision. (Show Details)

lgtm as mentor, but I defer to rust for the context knowledge :D

tobik added a subscriber: tobik.

Same general problem as D39205. In https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=275922 you can see it in distinfo too where crates that should go into DISTDIR/rust/crates now go into DISTDIR/jetbrains/rust/crates:

TIMESTAMP = 1702039441
SHA256 (jetbrains/rust/crates/autocfg-1.1.0.crate) = d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa
SIZE (jetbrains/rust/crates/autocfg-1.1.0.crate) = 13272
[...]

But that shouldn't block committing this patch as is.

This revision is now accepted and ready to land.Jan 5 2024, 12:19 PM
This revision was automatically updated to reflect the committed changes.