rust-libc/ci/run.sh
2015-09-14 00:56:58 -07:00

18 lines
504 B
Bash

#!/bin/sh
set -ex
TARGET=$1
cargo test --manifest-path libc-test/Cargo.toml --no-run --target $TARGET
if [ "$TARGET" = "arm-linux-androideabi" ]; then
emulator @test -no-window &
adb wait-for-device
adb push /root/target/$TARGET/debug/all-* /data/test
adb shell /data/test
elif [ "$TARGET" = "arm-unknown-linux-gnueabihf" ]; then
qemu-arm -L /usr/arm-linux-gnueabihf libc-test/target/$TARGET/debug/all-*
else
cargo test --manifest-path libc-test/Cargo.toml --target $TARGET
fi