$ cd /usr/ports/devel/cargo-c
$ fetch -qo- https://github.com/freebsd/freebsd-ports/commit/6519fce9b9a1.patch | patch -Efsp3
$ export NO_IGNORE=1 # disables unrelated safety belt
$ make clean patch
$ make cargo-crates | portedit merge -i .
$ make makesum
===> cargo-c-0.6.1 depends on file: /usr/local/sbin/pkg - found
=> rust/crates/curl-sys-0.4.30+curl-7.69.1.tar.gz doesn't seem to exist in /usr/ports/distfiles/.
=> Attempting to fetch https://crates.io/api/v1/crates/curl-sys-0.4.30+curl/7.69.1/download?dummy=/rust/crates/curl-sys-0.4.30+curl-7.69.1.tar.gz
fetch: https://crates.io/api/v1/crates/curl-sys-0.4.30+curl/7.69.1/download?dummy=/rust/crates/curl-sys-0.4.30+curl-7.69.1.tar.gz: Not Found
=> Attempting to fetch http://distcache.FreeBSD.org/ports-distfiles/rust/crates/curl-sys-0.4.30+curl-7.69.1.tar.gz
fetch: http://distcache.FreeBSD.org/ports-distfiles/rust/crates/curl-sys-0.4.30+curl-7.69.1.tar.gz: Not Found
=> Couldn't fetch it - please try to retrieve this
=> port manually into /usr/ports/distfiles/ and try again.
*** Error code 1
Created attachment 212613 [details]
Crate names have a restricted format , so let's restrict the regular
expressions too and make them less greedy.
Comment on attachment 212613 [details]
Works for me: builds fine and other crates fetch fine. Tested only devel/cargo-c after removing %2D (percent quoting) workaround.
*** Bug 244989 has been marked as a duplicate of this bug. ***
A commit references this bug:
Date: Mon Mar 23 03:57:26 UTC 2020
New revision: 528945
Mk/Uses/cargo.mk: Better deal with versions with build identifier suffixes
A crate spec like curl-sys-0.4.30+curl-7.69.1 was incorrectly
interpreted as having a name of 'curl-sys-0.4.30+curl' instead of
'curl-sys' and failed to fetch as a consequence.
Crate names can only be composed of a limited character set .
Limit the regular expressions to that set and make them less greedy.
Reported by: jbeich