Opened 5 years ago

Last modified 3 years ago

#56492 new enhancement

cargo_fetch: Add size to checksums

Reported by: ryandesign (Ryan Schmidt) Owned by:
Priority: Normal Milestone:
Component: ports Version:
Keywords: Cc: raimue (Rainer Müller), MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)


The cargo_fetch portgroup only supports sha256 checksums. Since we want to add size to all ports' checksums, please add the capability to specify the size as the 4th argument of each tuple of cargo.crates.

Since this portgroup is still new and only used in 5 ports so far, it might be fine to require the 4th argument, and to update the 5 ports, and the cargo2port script in contrib.

Change History (2)

comment:1 Changed 3 years ago by raimue (Rainer Müller)

I understand the idea of this request, but the cargo.crates option is supposed to be generated based on Cargo.lock. This file does only provide a sha256 as checksum.

We could modify cargo2port to output a size field, but it would need the full logic that is now in the port group to determine the download URL, fetch the files, verify the sha256 checksum and eventually get the file size from disk. These steps will be much more complicated than the simple text processing cargo2port does at the moment.

comment:2 Changed 3 years ago by ryandesign (Ryan Schmidt)

Ah. That's unfortunate.

Note: See TracTickets for help on using tickets.