From dec1b008e45fe665bcdc03000282ae55181fe673 Mon Sep 17 00:00:00 2001 From: Jorge Aparicio Date: Sun, 16 Oct 2016 21:39:27 -0500 Subject: [PATCH] use rustup and install the rust-src component --- .travis.yml | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/.travis.yml b/.travis.yml index f64558f..0147e02 100644 --- a/.travis.yml +++ b/.travis.yml @@ -58,12 +58,18 @@ matrix: rust: stable install: - # curl: `std for cross-compilation + # curl: `rustc` + Cargo + # rustup: `rust-src` or `rust-std` # docker: For transparent QEMU user emulation - if [ -z $TRAVIS_TAG ] || [ $TRAVIS_RUST_VERSION = $DEPLOY_VERSION ]; then - case $TARGET in thumbv*-none-eabi*) ;; *) - curl https://static.rust-lang.org/rustup.sh | - sh -s -- --add-target=$TARGET --disable-sudo -y --prefix=`rustc --print sysroot`;; + curl https://sh.rustup.rs -sSf | sh -s -- -y --default-toolchain $TRAVIS_RUST_VERSION; + + source ~/.cargo/env; + + case $TARGET in + x86_64-apple-darwin | x86_64-unknown-linux-gnu) ;; + thumbv*-none-eabi*) rustup component add rust-src ;; + *) rustup target add $TARGET;; esac; test $TRAVIS_OS_NAME = osx ||