eclass/cargo: Sync with Gentoo

It's from Gentoo commit c7f6ebbe26db3f2c9dd656438664109ec1329ab1.
This commit is contained in:
Flatcar Buildbot 2024-01-15 07:12:26 +00:00 committed by Krzesimir Nowak
parent bf6935377b
commit 8c02df13bb

View File

@ -1,4 +1,4 @@
# Copyright 1999-2023 Gentoo Authors
# Copyright 1999-2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
# @ECLASS: cargo.eclass
@ -331,6 +331,9 @@ cargo_src_unpack() {
for archive in ${A}; do
case "${archive}" in
*.crate)
# when called by pkgdiff-mg, do not unpack crates
[[ ${PKGBUMPING} == ${PVR} ]] && continue
ebegin "Loading ${archive} into Cargo registry"
tar -xf "${DISTDIR}"/${archive} -C "${ECARGO_VENDOR}/" || die
# generate sha256sum of the crate itself as cargo needs this