cargo: update to 0.31.0.
This commit is contained in:
parent
ebb2e7e34d
commit
ae12bb9978
1 changed files with 7 additions and 23 deletions
|
@ -1,6 +1,6 @@
|
|||
# Template file for 'cargo'
|
||||
pkgname=cargo
|
||||
version=0.30.0
|
||||
version=0.31.0
|
||||
revision=1
|
||||
hostmakedepends="rust python curl cmake pkg-config"
|
||||
makedepends="libcurl-devel libgit2-devel"
|
||||
|
@ -10,7 +10,7 @@ maintainer="Enno Boland <gottox@voidlinux.eu>"
|
|||
license="MIT, Apache-2.0"
|
||||
homepage="https://crates.io/"
|
||||
distfiles="https://github.com/rust-lang/cargo/archive/${version}.tar.gz"
|
||||
checksum=82f3ba49192b74b115b8aeca9db24deca022ee5e6351292611ab5b50e4455251
|
||||
checksum=96c4ce9a3db4748680e613e4f3bce7de84329e50b6074a1fa7adb43359ff270e
|
||||
_cargo_dist_version=0.30.0
|
||||
|
||||
if [ "$CROSS_BUILD" ]; then
|
||||
|
@ -34,44 +34,28 @@ else
|
|||
distfiles+="
|
||||
https://static.rust-lang.org/dist/cargo-${_cargo_dist_version}-i686-unknown-linux-gnu.tar.gz"
|
||||
checksum+="
|
||||
2fc5f7f5b128de456a9e1e3f5f4ef2c6d3169dbfe078931d9fcf38c9aa9b45ba"
|
||||
bc0f79a757601e0386e98bbbf870bf2a9f999d0085a9a2982d954833f8c519d5"
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
|
||||
case $XBPS_TARGET_MACHINE in
|
||||
i686) _host_triplet=i686-unknown-linux-gnu;;
|
||||
x86_64) _host_triplet=x86_64-unknown-linux-gnu;;
|
||||
x86_64-musl) _host_triplet=x86_64-unknown-linux-musl;;
|
||||
armv6l) _host_triplet=arm-unknown-linux-gnueabihf;;
|
||||
armv6l-musl) _host_triplet=arm-unknown-linux-musleabihf;;
|
||||
armv7l) _host_triplet=armv7-unknown-linux-gnueabihf;;
|
||||
armv7l-musl) _host_triplet=armv7-unknown-linux-musleabihf;;
|
||||
aarch64) _host_triplet=aarch64-unknown-linux-gnu;;
|
||||
aarch64-musl) _host_triplet=aarch64-unknown-linux-musl;;
|
||||
*) broken="Please add your triplet to the cargo template!";;
|
||||
esac
|
||||
|
||||
post_extract() {
|
||||
if [ -z "$CROSS_BUILD" ]; then
|
||||
mkdir -p target/snapshot
|
||||
case "$XBPS_MACHINE" in
|
||||
x86_64-musl) cp ../cargo cargo;;
|
||||
*) cp ../cargo-${_cargo_dist_version}-${_host_triplet}/cargo/bin/cargo cargo;;
|
||||
*) cp ../cargo-${_cargo_dist_version}-${RUST_TARGET}/cargo/bin/cargo cargo;;
|
||||
esac
|
||||
fi
|
||||
}
|
||||
do_configure() {
|
||||
# Actually use the config we set below
|
||||
export CARGO_HOME="$wrksrc/.cargo"
|
||||
|
||||
mkdir -p .cargo
|
||||
|
||||
cat >> .cargo/config <<EOF
|
||||
[build]
|
||||
jobs = ${makejobs#*j}
|
||||
target = "${_host_triplet}"
|
||||
[target.${_host_triplet}]
|
||||
target = "${RUST_TARGET}"
|
||||
[target.${RUST_TARGET}]
|
||||
linker = "${CC}"
|
||||
EOF
|
||||
}
|
||||
|
@ -89,7 +73,7 @@ do_build() {
|
|||
}
|
||||
|
||||
do_install() {
|
||||
vbin target/${_host_triplet}/release/cargo
|
||||
vbin target/${RUST_TARGET}/release/cargo
|
||||
for f in src/etc/man/*.?; do
|
||||
vman $f
|
||||
done
|
||||
|
|
Loading…
Reference in a new issue