parent
4d34baa1c5
commit
700c18495a
@ -1 +1,2 @@
|
||||
/resctl-bench-2.1.2.crate
|
||||
/resctl-bench-2.1.2-vendor.tar.gz
|
||||
|
@ -1 +1,2 @@
|
||||
SHA512 (resctl-bench-2.1.2.crate) = 55e56c9bf5d6c2d1c944291ad8908cff5a5e37e51bb8b4baa98dca5515773d22f509a14e9e85cd11066d5011a6390fbaec5d65c029b9ab253493004c937840eb
|
||||
SHA512 (resctl-bench-2.1.2-vendor.tar.gz) = 5797a8d3c1524df6c78463d067bbb97e22a68c65f1a50b039636280c07f1a9f878d3f0483dede30070f5909294afa5473c6f5776bccff39bf4fb872b4bee2115
|
||||
|
@ -0,0 +1,25 @@
|
||||
#!/bin/sh
|
||||
|
||||
name='resctl-bench'
|
||||
specfile="rust-${name}.spec"
|
||||
version=$(rpm -q --qf '%{VERSION}\n' --specfile "$specfile" | head -1)
|
||||
nv="${name}-${version}"
|
||||
crate="${nv}.crate"
|
||||
vendor_tarball="${nv}-vendor.tar.gz"
|
||||
|
||||
if [ -f "$vendor_tarball" ]; then
|
||||
echo "${vendor_tarball} already exists, aborting"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
[ -f "$crate" ] || spectool -g "$specfile"
|
||||
tardir="$PWD"
|
||||
workdir=$(mktemp -d)
|
||||
trap 'rm -rf "$workdir"' EXIT
|
||||
|
||||
tar xvzf "$tardir/$crate" -C "$workdir"
|
||||
(cd "${workdir}/${nv}" && \
|
||||
cargo vendor && \
|
||||
tar cvzf "${tardir}/${vendor_tarball}" vendor/)
|
||||
|
||||
exit 0
|
Loading…
Reference in new issue