Add scripts/install-toolchains.sh

This commit is contained in:
Alexander Krotov 2020-10-20 23:57:04 +03:00 committed by link2xt
parent 60d915fa13
commit 3b4ed28269
4 changed files with 13 additions and 8 deletions

9
scripts/install-toolchains.sh Executable file
View file

@ -0,0 +1,9 @@
#!/bin/sh
#
# Installs Rust cross-compilation toolchains for all supported architectures.
#
set -e
TARGETS="armv7-linux-androideabi aarch64-linux-android i686-linux-android x86_64-linux-android"
TOOLCHAIN="$(cat jni/deltachat-core-rust/rust-toolchain)"
rustup install "$TOOLCHAIN"
rustup target add $TARGETS --toolchain "$TOOLCHAIN"