Refactor with fewer intermediate artifacts

This commit is contained in:
Alex Crichton 2015-09-14 13:52:51 -07:00
parent 4a62f6111f
commit a4d78c4d0a

View file

@ -8,9 +8,7 @@ fi
export HOST=$ARCH-$OS
# clang has better error messages and implements alignof more broadly
export CC=clang
MAIN_TARGETS=https://static.rust-lang.org/dist/
EXTRA_TARGETS=https://people.mozilla.org/~acrichton/libc-test/2015-09-08
if [ "$TARGET" = "arm-linux-androideabi" ]; then
@ -26,7 +24,11 @@ elif [ "$TARGET" = "arm-unknown-linux-gnueabihf" ]; then
sudo apt-get install gcc-4.7-arm-linux-gnueabihf qemu-user
export CC=arm-linux-gnueabihf-gcc-4.7
elif [ "$TARGET" = "mips-unknown-linux-gnu" ]; then
# Download pre-built and custom MIPS libs and then also instsall the MIPS
# compiler according to this post:
# http://sathisharada.blogspot.com/2014_10_01_archive.html
curl -s $EXTRA_TARGETS/$TARGET.tar.gz | tar xzf - -C $HOME/rust/lib/rustlib
echo 'deb http://ftp.de.debian.org/debian squeeze main' | \
sudo tee -a /etc/apt/sources.list
echo 'deb http://www.emdebian.org/debian/ squeeze main' | \
@ -36,13 +38,15 @@ elif [ "$TARGET" = "mips-unknown-linux-gnu" ]; then
sudo apt-get install qemu-user gcc-4.4-mips-linux-gnu -y --force-yes
export CC=mips-linux-gnu-gcc
else
# Download and install the relevant target locally, then run tests
curl -sO https://static.rust-lang.org/dist/rust-$TRAVIS_RUST_VERSION-$HOST.tar.gz
tar xf rust-$TRAVIS_RUST_VERSION-$HOST.tar.gz
rm -rf $HOME/rust/lib/rustlib/$HOST
mv rust-$TRAVIS_RUST_VERSION-$HOST/rustc/lib/rustlib/$HOST \
$HOME/rust/lib/rustlib
# Download the rustlib folder from the relevant portion of main distribution's
# tarballs.
curl -s $MAIN_TARGETS/rust-$TRAVIS_RUST_VERSION-$HOST.tar.gz | \
tar xzf - -C $HOME/rust/lib/rustlib --strip-components=4 \
rust-$TRAVIS_RUST_VERSION-$HOST/rustc/lib/rustlib/$HOST
TARGET=$HOST
# clang has better error messages and implements alignof more broadly
export CC=clang
fi
mkdir .cargo